Back


Lennie's Weekly Tip: Enable & Disabling Full Windows Dragging.

9th April, 2000 - Ref. 19



 

The last tip (01 April 2000 Ref. 18) discribed how to determine whether full Windows dragging is enabled or not, but how do you enable or disable full windows dragging from your application?

What's Full Windows Dragging?

Full Windows dragging means that the contents of a Window is visible, while the user is dragging it.
If full Windows dragging isn't enabled only the outline of the Window is visible.

You can now use the following two functions to enable/disable full Windows dragging:

function EnableFullWinDragging : boolean;

begin
  if (WindowsExtensionInstalled) then
    Result := SystemParametersInfo(SPI_SETDRAGFULLWINDOWS, 1, nil, 0)
  else
    Result := FALSE;
end;

function DisableFullWinDragging : boolean;

begin
  if (WindowsExtensionInstalled) then
    Result := SystemParametersInfo(SPI_SETDRAGFULLWINDOWS, 0, nil, 0)
  else
    Result := FALSE;
end;

They'll return TRUE if successful or FALSE if not successful.

NOTE:

For these functions to work the user must have Windows Plus installed on his/her's Windows'95 machine.
Windows'98 users do not need to worry, because Windows Plus is available with the Windows'98 package.

The functions uses the WindowsExtensionInstalled-function to determine whether Windows Plus is installed.

For more information on the WindowsExtensionInstalled-function read my tip "Is Windows Extension (Windows Plus) Installed? " at WinExt.htm


Back