summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2009-09-09 22:40:44 -0400
committerMatthias Clasen <mclasen@redhat.com>2009-09-10 13:53:28 -0400
commitbe22a6216094814b00243a3da93fe177814a4e9b (patch)
tree2c967afbee00f3ae22d3ee3b4eafbaae36659761 /modules
parent7124f5927ae96d13ea74268b73c62293b0243ddd (diff)
downloadgtk+-be22a6216094814b00243a3da93fe177814a4e9b.tar.gz
Cleanups
This commit removes dead code, mostly pointed out by clang.
Diffstat (limited to 'modules')
-rw-r--r--modules/other/gail/gailbutton.c3
-rw-r--r--modules/other/gail/gailcombobox.c12
-rw-r--r--modules/other/gail/gailscalebutton.c2
-rw-r--r--modules/printbackends/file/gtkprintbackendfile.c2
4 files changed, 6 insertions, 13 deletions
diff --git a/modules/other/gail/gailbutton.c b/modules/other/gail/gailbutton.c
index 1e429041cc..998ec29a2f 100644
--- a/modules/other/gail/gailbutton.c
+++ b/modules/other/gail/gailbutton.c
@@ -874,7 +874,6 @@ gail_button_ref_state_set (AtkObject *obj)
{
AtkStateSet *state_set;
GtkWidget *widget;
- GtkButton *button;
state_set = ATK_OBJECT_CLASS (gail_button_parent_class)->ref_state_set (obj);
widget = GTK_ACCESSIBLE (obj)->widget;
@@ -882,8 +881,6 @@ gail_button_ref_state_set (AtkObject *obj)
if (widget == NULL)
return state_set;
- button = GTK_BUTTON (widget);
-
if (GTK_WIDGET_STATE (widget) == GTK_STATE_ACTIVE)
atk_state_set_add_state (state_set, ATK_STATE_ARMED);
diff --git a/modules/other/gail/gailcombobox.c b/modules/other/gail/gailcombobox.c
index b90e7cc199..e246aa32eb 100644
--- a/modules/other/gail/gailcombobox.c
+++ b/modules/other/gail/gailcombobox.c
@@ -358,15 +358,14 @@ gail_combo_box_get_keybinding (AtkAction *action,
{
GailComboBox *combo_box;
gchar *return_value = NULL;
- combo_box = GAIL_COMBO_BOX (action);
switch (i)
{
case 0:
{
- GtkWidget *widget;
+ GtkWidget *widget;
GtkWidget *label;
AtkRelationSet *set;
- AtkRelation *relation;
+ AtkRelation *relation;
GPtrArray *target;
gpointer target_object;
guint key_val;
@@ -375,7 +374,7 @@ gail_combo_box_get_keybinding (AtkAction *action,
widget = GTK_ACCESSIBLE (combo_box)->widget;
if (widget == NULL)
return NULL;
- set = atk_object_ref_relation_set (ATK_OBJECT (action));
+ set = atk_object_ref_relation_set (ATK_OBJECT (action));
if (!set)
return NULL;
label = NULL;
@@ -388,7 +387,7 @@ gail_combo_box_get_keybinding (AtkAction *action,
{
label = GTK_ACCESSIBLE (target_object)->widget;
}
- }
+ }
g_object_unref (set);
if (GTK_IS_LABEL (label))
{
@@ -398,7 +397,8 @@ gail_combo_box_get_keybinding (AtkAction *action,
}
g_free (combo_box->press_keybinding);
combo_box->press_keybinding = return_value;
- break; }
+ break;
+ }
default:
break;
}
diff --git a/modules/other/gail/gailscalebutton.c b/modules/other/gail/gailscalebutton.c
index aa0ac2fb7b..32cb12eea9 100644
--- a/modules/other/gail/gailscalebutton.c
+++ b/modules/other/gail/gailscalebutton.c
@@ -187,12 +187,10 @@ static void
gail_scale_button_get_current_value (AtkValue *obj,
GValue *value)
{
- GailScaleButton *scale_button;
GtkScaleButton *gtk_scale_button;
g_return_if_fail (GAIL_IS_SCALE_BUTTON (obj));
- scale_button = GAIL_SCALE_BUTTON (obj);
gtk_scale_button = GTK_SCALE_BUTTON (GTK_ACCESSIBLE (obj)->widget);
g_value_set_double (g_value_init (value, G_TYPE_DOUBLE),
diff --git a/modules/printbackends/file/gtkprintbackendfile.c b/modules/printbackends/file/gtkprintbackendfile.c
index aaf8ce1d90..fc2046c595 100644
--- a/modules/printbackends/file/gtkprintbackendfile.c
+++ b/modules/printbackends/file/gtkprintbackendfile.c
@@ -442,13 +442,11 @@ gtk_print_backend_file_print_stream (GtkPrintBackend *print_backend,
GDestroyNotify dnotify)
{
GError *internal_error = NULL;
- GtkPrinter *printer;
_PrintStreamData *ps;
GtkPrintSettings *settings;
gchar *uri;
GFile *file = NULL;
- printer = gtk_print_job_get_printer (job);
settings = gtk_print_job_get_settings (job);
ps = g_new0 (_PrintStreamData, 1);