mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-30 23:30:30 +02:00
lcl: gtk2: tcustomcontrol: clear background pixmap of parent window too
git-svn-id: trunk@41670 -
This commit is contained in:
parent
f97c282b0d
commit
63b2a29382
@ -382,8 +382,14 @@ begin
|
||||
//@ AWidget^.Style := gtk_style_attach(AWidget^.Style, AWidget^.Window);
|
||||
//@ gtk_style_set_background(AWidget^.Style, AWidget^.Window, GTK_STATE_NORMAL);
|
||||
Info := GetWidgetInfo(AWidget);
|
||||
if (Info = nil) or ([wwiNoEraseBkgnd] * Info^.Flags = []) then
|
||||
if (Info = nil) or ([wwiNoEraseBkgnd] * Info^.Flags = []) then begin
|
||||
gdk_window_set_back_pixmap(AWidget^.Window, nil, GdkFalse);
|
||||
if AWidget^.parent<>nil then begin
|
||||
// clear parent window background pixmap too, just in case AWidget is a nowindow
|
||||
// see note of gtk docs about gtk_widget_modify_bg
|
||||
gdk_window_set_back_pixmap(AWidget^.parent^.Window, nil, GdkFalse);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure GTKAPIWidgetClient_UnRealize(AWidget: PGTKWidget); cdecl;
|
||||
|
Loading…
Reference in New Issue
Block a user