summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorElijah Newren <newren gmail com>2006-01-24 01:07:41 +0000
committerElijah Newren <newren@src.gnome.org>2006-01-24 01:07:41 +0000
commit405e21a82a696330195e844ae4a921953a5930bc (patch)
tree738dcda4765776216b7c1800171fc2759f669094 /src
parent9abec54da6f0e58f0d2f120dd90c1d4f5413b177 (diff)
downloadmetacity-405e21a82a696330195e844ae4a921953a5930bc.tar.gz
change the order of the ||'ed items in the if to avoid using an
2006-01-23 Elijah Newren <newren gmail com> * src/display.c (meta_display_check_threshold_reached): change the order of the ||'ed items in the if to avoid using an uninitialized value * src/prefs.c (meta_prefs_init): fix a couple uninitialized value problems
Diffstat (limited to 'src')
-rw-r--r--src/display.c4
-rw-r--r--src/prefs.c11
2 files changed, 9 insertions, 6 deletions
diff --git a/src/display.c b/src/display.c
index 0c1a6e36..e9282fd9 100644
--- a/src/display.c
+++ b/src/display.c
@@ -3616,8 +3616,8 @@ meta_display_check_threshold_reached (MetaDisplay *display,
int y)
{
/* Don't bother doing the check again if we've already reached the threshold */
- if (display->grab_threshold_movement_reached ||
- meta_prefs_get_raise_on_click ())
+ if (meta_prefs_get_raise_on_click () ||
+ display->grab_threshold_movement_reached)
return;
if (ABS (display->grab_initial_x - x) >= 8 ||
diff --git a/src/prefs.c b/src/prefs.c
index 44751a73..ab132f20 100644
--- a/src/prefs.c
+++ b/src/prefs.c
@@ -434,11 +434,14 @@ meta_prefs_init (void)
cleanup_error (&err);
update_button_layout (str_val);
g_free (str_val);
-
- if (get_bool (KEY_VISUAL_BELL, &bool_val) ||
- get_bool (KEY_AUDIBLE_BELL, &bool_val_2))
- update_visual_bell (bool_val, bool_val_2);
+ bool_val = provide_visual_bell;
+ bool_val_2 = bell_is_audible;
+ gboolean update_visual = get_bool (KEY_VISUAL_BELL, &bool_val);
+ gboolean update_audible = get_bool (KEY_AUDIBLE_BELL, &bool_val_2);
+ if (update_visual || update_audible)
+ update_visual_bell (bool_val, bool_val_2);
+
str_val = gconf_client_get_string (default_client, KEY_VISUAL_BELL_TYPE,
&err);
cleanup_error (&err);