diff options
| author | monsta <[email protected]> | 2019-07-30 11:50:34 +0300 | 
|---|---|---|
| committer | Robert Antoni Buj Gelonch <[email protected]> | 2019-08-10 18:15:27 +0200 | 
| commit | 85baeea9b663d4c356313ef1164c8efbf03e2e7e (patch) | |
| tree | 1b9f8bf7162e226e3a1be1e3cec4c5f16e9fadee /src/ui/ui.c | |
| parent | e31704684773d8279adc303d183d498252e0583f (diff) | |
| download | marco-85baeea9b663d4c356313ef1164c8efbf03e2e7e.tar.bz2 marco-85baeea9b663d4c356313ef1164c8efbf03e2e7e.tar.xz | |
frames: apply modified hack from Mutter/Metacity
- this will be needed for proper window decoration color updates on theme change
  when theme variants fixes are applied
- realize/unrealize functions are dropped instead of map/unmap ones, because
  we didn't change these during GTK+3 porting
- MetaFrames now has GtkWindow as parent instead of GtkInvisible, otherwise
  the hack doesn't work (revert part of 96c7256d638b8c76c8abf786ba307e82a595dd67)
adapted from:
https://github.com/GNOME/metacity/commit/ba8500663457ad9f18ebfdf405162c2cb5caf88f
Diffstat (limited to 'src/ui/ui.c')
| -rw-r--r-- | src/ui/ui.c | 9 | 
1 files changed, 6 insertions, 3 deletions
| diff --git a/src/ui/ui.c b/src/ui/ui.c index c805869f..9c99552d 100644 --- a/src/ui/ui.c +++ b/src/ui/ui.c @@ -271,9 +271,12 @@ meta_ui_new (Display *xdisplay,    g_assert (xdisplay == GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));    ui->frames = meta_frames_new (); -  /* This does not actually show any widget. MetaFrames has been hacked so -   * that showing it doesn't actually do anything. But we need the flags -   * set for GTK to deliver events properly. */ +  /* GTK+ needs the frame-sync protocol to work in order to properly +   * handle style changes. This means that the dummy widget we create +   * to get the style for title bars actually needs to be mapped +   * and fully tracked as a MetaWindow. Horrible, but mostly harmless - +   * the window is a 1x1 overide redirect window positioned offscreen. +   */    gtk_widget_show (GTK_WIDGET (ui->frames));    g_object_set_data (G_OBJECT (gdisplay), "meta-ui", ui); | 
