mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-01 23:10:24 +02:00
* (slightly modified) patch by Laaca originally for GO32v2 - avoid disappearing mouse cursor in full screen sessions
git-svn-id: trunk@10591 -
This commit is contained in:
parent
a71092edb0
commit
ed914574e2
@ -3,7 +3,7 @@
|
||||
Copyright (c) 1999-2000 by Florian Klaempfl
|
||||
member of the Free Pascal development team
|
||||
|
||||
Mouse unit for linux
|
||||
Mouse unit for OS/2
|
||||
|
||||
See the file COPYING.FPC, included in this distribution,
|
||||
for details about the copyright.
|
||||
@ -18,6 +18,9 @@ interface
|
||||
|
||||
{$i mouseh.inc}
|
||||
|
||||
const
|
||||
MouseIsVisible: boolean = false;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
@ -68,6 +71,7 @@ begin
|
||||
*)
|
||||
|
||||
MouDrawPtr (Handle);
|
||||
MouseIsVisible := true;
|
||||
end;
|
||||
end;
|
||||
|
||||
@ -115,6 +119,7 @@ begin
|
||||
begin
|
||||
Dec (HideCounter);
|
||||
if HideCounter = 0 then MouDrawPtr (Handle);
|
||||
MouseIsVisible := true;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@ -134,6 +139,7 @@ begin
|
||||
PtrRect.cRow := Pred (ScreenHeight);
|
||||
PtrRect.cCol := Pred (ScreenWidth);
|
||||
MouRemovePtr (PtrRect, Handle);
|
||||
MouseIsVisible := false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
@ -22,7 +22,7 @@ interface
|
||||
implementation
|
||||
|
||||
uses
|
||||
DosCalls, VioCalls;
|
||||
DosCalls, VioCalls, Mouse;
|
||||
|
||||
{$i video.inc}
|
||||
|
||||
@ -352,6 +352,7 @@ end;
|
||||
procedure SysUpdateScreen (Force: boolean);
|
||||
|
||||
var SOfs, CLen: cardinal;
|
||||
Mouse_Visible: boolean;
|
||||
|
||||
begin
|
||||
if not (Force) then
|
||||
@ -407,9 +408,14 @@ begin
|
||||
Move(VideoBuf^,SysVideoBuf^,VideoBufSize);
|
||||
if Force then
|
||||
begin
|
||||
VioShowBuf (SOfs, CLen, 0);
|
||||
Move (VideoBuf^ [SOfs div SizeOf (TVideoCell)],
|
||||
Mouse_Visible := MouseIsVisible; {MouseIsVisible is from Mouse unit}
|
||||
if Mouse_Visible then
|
||||
HideMouse;
|
||||
VioShowBuf (SOfs, CLen, 0);
|
||||
Move (VideoBuf^ [SOfs div SizeOf (TVideoCell)],
|
||||
OldVideoBuf^ [SOfs div SizeOf (TVideoCell)], CLen);
|
||||
if Mouse_Visible then
|
||||
ShowMouse;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user