gnome-control-center r8644 - trunk/capplets/mouse



Author: gerdk
Date: Fri Apr 11 08:12:14 2008
New Revision: 8644
URL: http://svn.gnome.org/viewvc/gnome-control-center?rev=8644&view=rev

Log:
2008-04-11  Gerd Kohlberger  <gerdk svn gnome org>

	* gnome-mouse-properties.c: (create_dialog): Remove unused custom widget.
	* gnome-mouse-accessibility.h: Clean up. (Bug #527418)



Modified:
   trunk/capplets/mouse/ChangeLog
   trunk/capplets/mouse/gnome-mouse-accessibility.h
   trunk/capplets/mouse/gnome-mouse-properties.c

Modified: trunk/capplets/mouse/gnome-mouse-accessibility.h
==============================================================================
--- trunk/capplets/mouse/gnome-mouse-accessibility.h	(original)
+++ trunk/capplets/mouse/gnome-mouse-accessibility.h	Fri Apr 11 08:12:14 2008
@@ -28,63 +28,3 @@
 G_END_DECLS
 
 #endif /* __GNOME_MOUSE_A11Y_H */
-/*
- * Copyright (C) 2007 Gerd Kohlberger
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
- */
-
-#ifndef __GNOME_MOUSE_A11Y_H
-#define __GNOME_MOUSE_A11Y_H
-
-#include <glade/glade.h>
-#include <gconf/gconf-client.h>
-
-G_BEGIN_DECLS
-
-void setup_accessibility (GladeXML *dialog, GConfClient *client);
-
-G_END_DECLS
-
-#endif /* __GNOME_MOUSE_A11Y_H */
-/*
- * Copyright (C) 2007 Gerd Kohlberger
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
- */
-
-#ifndef __GNOME_MOUSE_A11Y_H
-#define __GNOME_MOUSE_A11Y_H
-
-#include <glade/glade.h>
-#include <gconf/gconf-client.h>
-
-G_BEGIN_DECLS
-
-void setup_accessibility (GladeXML *dialog, GConfClient *client);
-
-G_END_DECLS
-
-#endif /* __GNOME_MOUSE_A11Y_H */

Modified: trunk/capplets/mouse/gnome-mouse-properties.c
==============================================================================
--- trunk/capplets/mouse/gnome-mouse-properties.c	(original)
+++ trunk/capplets/mouse/gnome-mouse-properties.c	Fri Apr 11 08:12:14 2008
@@ -46,42 +46,6 @@
 #include <X11/Xcursor/Xcursor.h>
 #endif
 
-/******************************************************************************/
-/* A quick custom widget to ensure that the left handed toggle works no matter
- * which button is pressed.
- */
-typedef struct { GtkCheckButton parent; } MouseCappletCheckButton;
-typedef struct { GtkCheckButtonClass parent; } MouseCappletCheckButtonClass;
-GNOME_CLASS_BOILERPLATE (MouseCappletCheckButton, mouse_capplet_check_button,
-			 GtkCheckButton, GTK_TYPE_CHECK_BUTTON)
-static void mouse_capplet_check_button_instance_init (MouseCappletCheckButton *obj) { }
-
-static gboolean
-mouse_capplet_check_button_button_press (GtkWidget *widget, GdkEventButton *event)
-{
-	if (event->type == GDK_BUTTON_PRESS) {
-		if (!GTK_WIDGET_HAS_FOCUS (widget))
-			gtk_widget_grab_focus (widget);
-		gtk_button_pressed (GTK_BUTTON (widget));
-	}
-	return TRUE;
-}
-static gboolean
-mouse_capplet_check_button_button_release (GtkWidget *widget, GdkEventButton *event)
-{
-      gtk_button_released (GTK_BUTTON (widget));
-      return TRUE;
-}
-
-static void
-mouse_capplet_check_button_class_init (MouseCappletCheckButtonClass *klass)
-{
-	GtkWidgetClass *widget_class = (GtkWidgetClass *)klass;
-	widget_class->button_press_event   = mouse_capplet_check_button_button_press;
-	widget_class->button_release_event = mouse_capplet_check_button_button_release;
-}
-/******************************************************************************/
-
 enum
 {
 	DOUBLE_CLICK_TEST_OFF,
@@ -254,7 +218,7 @@
 	static gint                test_on_timeout_id     = 0;
 	static gint                test_maybe_timeout_id  = 0;
 	static guint32             double_click_timestamp = 0;
-	GtkWidget                  *image;
+	GtkWidget                 *image;
 	GConfClient               *client;
 
 	if (event->type != GDK_BUTTON_PRESS)
@@ -408,9 +372,6 @@
 	GladeXML     *dialog;
 	GtkSizeGroup *size_group;
 
-	/* register the custom type */
-	(void) mouse_capplet_check_button_get_type ();
-
 	dialog = glade_xml_new (GNOMECC_GLADE_DIR "/gnome-mouse-properties.glade", "mouse_properties_dialog", NULL);
 	if (!dialog)
 		return NULL;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]