mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-05 10:55:56 +02:00
gtk2: dont send size message to LCL if visibility changed
git-svn-id: trunk@12206 -
This commit is contained in:
parent
88dd7363cd
commit
70c6f0d1f9
@ -1156,8 +1156,12 @@ begin
|
|||||||
|
|
||||||
// if iconified in changed then OnIconify...
|
// if iconified in changed then OnIconify...
|
||||||
|
|
||||||
if GTK_WIDGET_REALIZED(Widget) then begin
|
if GTK_WIDGET_REALIZED(Widget) then
|
||||||
if TObject(Data) is TCustomForm then begin
|
begin
|
||||||
|
if (GDK_WINDOW_STATE_WITHDRAWN and state^.changed_mask) = 1 then // visibility changed - this is another message block
|
||||||
|
exit;
|
||||||
|
if TObject(Data) is TCustomForm then
|
||||||
|
begin
|
||||||
TheForm := TCustomForm(Data);
|
TheForm := TCustomForm(Data);
|
||||||
//DebugLn(['GTKWindowStateEventCB ',DbgSName(TheForm),' new_window_state=',state^.new_window_state,' changed_mask=',state^.changed_mask]);
|
//DebugLn(['GTKWindowStateEventCB ',DbgSName(TheForm),' new_window_state=',state^.new_window_state,' changed_mask=',state^.changed_mask]);
|
||||||
if TheForm.Parent = nil then begin
|
if TheForm.Parent = nil then begin
|
||||||
@ -1170,7 +1174,8 @@ begin
|
|||||||
GtkHeight:=Widget^.Allocation.Height;
|
GtkHeight:=Widget^.Allocation.Height;
|
||||||
if GtkHeight<0 then GtkHeight:=0;
|
if GtkHeight<0 then GtkHeight:=0;
|
||||||
//debugln('GTKWindowStateEventCB ',DbgSName(TObject(Data)),' ',dbgs(state^.new_window_state),' ',WidgetFlagsToString(Widget));
|
//debugln('GTKWindowStateEventCB ',DbgSName(TObject(Data)),' ',dbgs(state^.new_window_state),' ',WidgetFlagsToString(Widget));
|
||||||
if ((GDK_WINDOW_STATE_ICONIFIED and state^.new_window_state)>0) then begin
|
if ((GDK_WINDOW_STATE_ICONIFIED and state^.new_window_state)>0) then
|
||||||
|
begin
|
||||||
{$IFDEF HasX}
|
{$IFDEF HasX}
|
||||||
NetAtom := gdk_atom_intern('_NET_WM_DESKTOP', True);
|
NetAtom := gdk_atom_intern('_NET_WM_DESKTOP', True);
|
||||||
if NetAtom > 0 then begin
|
if NetAtom > 0 then begin
|
||||||
|
Loading…
Reference in New Issue
Block a user