diff options
author | Wolfgang Ulbrich <[email protected]> | 2015-11-16 14:02:19 +0100 |
---|---|---|
committer | Wolfgang Ulbrich <[email protected]> | 2015-12-02 12:54:10 +0100 |
commit | 8ea8868b6e6cfa626905b52b4b94b10b60d43139 (patch) | |
tree | 8b280cf03d6569a1991f82b3449f8714bd31ebed /plugins/a11y-keyboard/msd-a11y-keyboard-manager.c | |
parent | ef58118cad934b5fa5bf5ca1abe2d7f3d6f56836 (diff) | |
download | mate-settings-daemon-8ea8868b6e6cfa626905b52b4b94b10b60d43139.tar.bz2 mate-settings-daemon-8ea8868b6e6cfa626905b52b4b94b10b60d43139.tar.xz |
GTK3: use gdk_error_trap_pop_ignored() when appropriate
taken from:
https://git.gnome.org/browse/gnome-settings-daemon/commit/?id=544526d
Diffstat (limited to 'plugins/a11y-keyboard/msd-a11y-keyboard-manager.c')
-rw-r--r-- | plugins/a11y-keyboard/msd-a11y-keyboard-manager.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/plugins/a11y-keyboard/msd-a11y-keyboard-manager.c b/plugins/a11y-keyboard/msd-a11y-keyboard-manager.c index 7696d16..0d7f926 100644 --- a/plugins/a11y-keyboard/msd-a11y-keyboard-manager.c +++ b/plugins/a11y-keyboard/msd-a11y-keyboard-manager.c @@ -185,7 +185,11 @@ get_xkb_desc_rec (MsdA11yKeyboardManager *manager) desc->ctrls = NULL; status = XkbGetControls (GDK_DISPLAY_XDISPLAY(gdk_display_get_default()), XkbAllControlsMask, desc); } +#if GTK_CHECK_VERSION (3, 0, 0) + gdk_error_trap_pop_ignored (); +#else gdk_error_trap_pop (); +#endif g_return_val_if_fail (desc != NULL, NULL); g_return_val_if_fail (desc->ctrls != NULL, NULL); @@ -392,7 +396,11 @@ set_server_from_settings (MsdA11yKeyboardManager *manager) XkbFreeKeyboard (desc, XkbAllComponentsMask, True); XSync (GDK_DISPLAY_XDISPLAY(gdk_display_get_default()), FALSE); +#if GTK_CHECK_VERSION (3, 0, 0) + gdk_error_trap_pop_ignored (); +#else gdk_error_trap_pop (); +#endif mate_settings_profile_end (NULL); } @@ -1073,7 +1081,11 @@ restore_server_xkb_config (MsdA11yKeyboardManager *manager) XkbAllComponentsMask, True); XSync (GDK_DISPLAY_XDISPLAY(gdk_display_get_default()), FALSE); +#if GTK_CHECK_VERSION (3, 0, 0) + gdk_error_trap_pop_ignored (); +#else gdk_error_trap_pop (); +#endif manager->priv->original_xkb_desc = NULL; } |