From b0ba7d51e7da6a775d0d61d830b87700e17fd196 Mon Sep 17 00:00:00 2001 From: Stefano Karapetsas Date: Tue, 18 Feb 2014 13:36:41 +0100 Subject: windows: Add option to enable side by side tiling --- capplets/windows/mate-window-properties.c | 9 ++++ capplets/windows/mate-window-properties.ui | 68 ++++++++++++++++++++++++++++-- 2 files changed, 74 insertions(+), 3 deletions(-) diff --git a/capplets/windows/mate-window-properties.c b/capplets/windows/mate-window-properties.c index 6e3bb77e..b2697bd6 100644 --- a/capplets/windows/mate-window-properties.c +++ b/capplets/windows/mate-window-properties.c @@ -49,6 +49,7 @@ #define MARCO_DOUBLE_CLICK_TITLEBAR_KEY "action-double-click-titlebar" #define MARCO_COMPOSITING_MANAGER_KEY "compositing-manager" #define MARCO_COMPOSITING_FAST_ALT_TAB_KEY "compositing-fast-alt-tab" +#define MARCO_SIDE_BY_SIDE_TILING_KEY "side-by-side-tiling" /* keep following enums in sync with marco */ enum @@ -80,6 +81,7 @@ typedef struct static GtkWidget *dialog_win; static GObject *compositing_checkbutton; static GObject *compositing_fast_alt_tab_checkbutton; +static GObject *side_by_side_tiling_checkbutton; static GObject *focus_mode_checkbutton; static GObject *autoraise_checkbutton; static GObject *autoraise_delay_slider; @@ -285,6 +287,7 @@ main (int argc, char **argv) dialog_win = GTK_WIDGET (gtk_builder_get_object (builder, "main-dialog")); compositing_checkbutton = gtk_builder_get_object (builder, "compositing-manager-checkbutton"); compositing_fast_alt_tab_checkbutton = gtk_builder_get_object (builder, "compositing-fast-alt-tab-checkbutton"); + side_by_side_tiling_checkbutton = gtk_builder_get_object (builder, "side-by-side-tiling"); focus_mode_checkbutton = gtk_builder_get_object (builder, "focus-mode-checkbutton"); autoraise_checkbutton = gtk_builder_get_object (builder, "autoraise-checkbutton"); autoraise_delay_slider = gtk_builder_get_object (builder, "autoraise-delay-slider"); @@ -333,6 +336,12 @@ main (int argc, char **argv) "active", G_SETTINGS_BIND_DEFAULT); + g_settings_bind (marco_settings, + MARCO_SIDE_BY_SIDE_TILING_KEY, + side_by_side_tiling_checkbutton, + "active", + G_SETTINGS_BIND_DEFAULT); + g_signal_connect (focus_mode_checkbutton, "toggled", G_CALLBACK (mouse_focus_toggled_callback), NULL); g_signal_connect (marco_settings, "changed::" MARCO_FOCUS_KEY, diff --git a/capplets/windows/mate-window-properties.ui b/capplets/windows/mate-window-properties.ui index 1029fed9..22d658d4 100644 --- a/capplets/windows/mate-window-properties.ui +++ b/capplets/windows/mate-window-properties.ui @@ -11,6 +11,7 @@ True 2 + True @@ -106,6 +107,66 @@ 0 + + + + True + 6 + + + True + 0 + Window Snapping + + + + + + False + False + 0 + + + + + True + 12 + + + True + 6 + + + Enable side by side tiling + True + True + False + True + True + + + False + False + 0 + + + + + + + False + False + 1 + + + + + False + False + 1 + + + True @@ -247,7 +308,7 @@ False False - 1 + 2 @@ -322,7 +383,7 @@ False False - 2 + 3 @@ -398,7 +459,7 @@ False False - 3 + 4 @@ -406,6 +467,7 @@ 1 + True -- cgit v1.2.1