diff options
author | Florian Müllner <fmuellner@gnome.org> | 2011-03-20 23:10:49 +0100 |
---|---|---|
committer | Alberts Muktupāvels <alberts.muktupavels@gmail.com> | 2014-10-08 18:25:55 +0300 |
commit | 97554dc4ccfd022cd23f6b00c124543c3a4a77dc (patch) | |
tree | 7bd73f9376d7c3d0797c825f739a9ba33927643e | |
parent | 5c7403cc66003ff1949916dfdd287dbc622dfd5e (diff) | |
download | metacity-97554dc4ccfd022cd23f6b00c124543c3a4a77dc.tar.gz |
ui: Add meta_ui_update_frame_style()
This method allows forcing a style update of a particular frame
from the core, so that it can pick up style variants.
https://bugzilla.gnome.org/show_bug.cgi?id=645355
-rw-r--r-- | src/include/ui.h | 3 | ||||
-rw-r--r-- | src/ui/frames.c | 14 | ||||
-rw-r--r-- | src/ui/frames.h | 3 | ||||
-rw-r--r-- | src/ui/ui.c | 7 |
4 files changed, 27 insertions, 0 deletions
diff --git a/src/include/ui.h b/src/include/ui.h index 45e85cdd..6f9e9c08 100644 --- a/src/include/ui.h +++ b/src/include/ui.h @@ -107,6 +107,9 @@ void meta_ui_set_frame_title (MetaUI *ui, Window xwindow, const char *title); +void meta_ui_update_frame_style (MetaUI *ui, + Window window); + void meta_ui_repaint_frame (MetaUI *ui, Window xwindow); diff --git a/src/ui/frames.c b/src/ui/frames.c index b068754c..c21c5cc4 100644 --- a/src/ui/frames.c +++ b/src/ui/frames.c @@ -1046,6 +1046,20 @@ meta_frames_set_title (MetaFrames *frames, } void +meta_frames_update_frame_style (MetaFrames *frames, + Window xwindow) +{ + MetaUIFrame *frame; + + frame = meta_frames_lookup_window (frames, xwindow); + + g_assert (frame); + + meta_frames_attach_style (frames, frame); + invalidate_whole_window (frames, frame); +} + +void meta_frames_repaint_frame (MetaFrames *frames, Window xwindow) { diff --git a/src/ui/frames.h b/src/ui/frames.h index 418aadd7..25f3d750 100644 --- a/src/ui/frames.h +++ b/src/ui/frames.h @@ -123,6 +123,9 @@ void meta_frames_set_title (MetaFrames *frames, Window xwindow, const char *title); +void meta_frames_update_frame_style (MetaFrames *frames, + Window xwindow); + void meta_frames_repaint_frame (MetaFrames *frames, Window xwindow); diff --git a/src/ui/ui.c b/src/ui/ui.c index f4a12e03..26148261 100644 --- a/src/ui/ui.c +++ b/src/ui/ui.c @@ -433,6 +433,13 @@ meta_ui_unflicker_frame_bg (MetaUI *ui, } void +meta_ui_update_frame_style (MetaUI *ui, + Window xwindow) +{ + meta_frames_update_frame_style (ui->frames, xwindow); +} + +void meta_ui_repaint_frame (MetaUI *ui, Window xwindow) { |