procedure Do_BeginWaitCursor;inline;
begin
// under windows cursor state is set immediately by winapi
// under linux you must call processmessage to force the state change to happen.
Screen.BeginWaitCursor;
{$ifdef linux}
Application.ProcessMessages;
{$endif}
end;
procedure Do_EndWaitCursor;inline;
begin
// under windows cursor state is set immediately by winapi
// under linux you must call processmessage to force the state change to happen.
Screen.EndWaitCursor;
{$ifdef linux}
Application.ProcessMessages;
{$endif}
end;
......
Do_BeginWaitCursor;
sleep(2000);
Do_EndWaitCursor;