From 71a4a614d9e72f1895cf2d1043185499a47c02fb Mon Sep 17 00:00:00 2001 From: Salvatore Iovene Date: Sun, 6 Dec 2009 13:33:38 +0200 Subject: [PATCH] Create desktop snap button. --- modules/maemo-tweaks-desktop.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/modules/maemo-tweaks-desktop.c b/modules/maemo-tweaks-desktop.c index 24ba0d5..5422017 100644 --- a/modules/maemo-tweaks-desktop.c +++ b/modules/maemo-tweaks-desktop.c @@ -107,11 +107,6 @@ maemo_tweaks_desktop_section_class_init section_class->save = _save; } -static void -maemo_tweaks_desktop_section_init (MaemoTweaksDesktopSection *section) -{ -} - GtkWidget * _build_snap_to_grid (void) { const gchar *options[] = {"Default", "Small grid", "Large grid", NULL}; @@ -138,6 +133,20 @@ GtkWidget * _build_snap_to_grid (void) return button; } +static void +maemo_tweaks_desktop_section_init (MaemoTweaksDesktopSection *section) +{ + GtkWidget * snap_button; + MaemoTweaksSection *iface; + + snap_button = _build_snap_to_grid (); + iface = MAEMO_TWEAKS_SECTION (section); + + iface->widget = gtk_vbox_new (FALSE, 0); + gtk_box_pack_start (GTK_BOX (iface->widget), snap_button, + FALSE, FALSE, 0); +} + static void _save (MaemoTweaksSection *section) { } -- 1.7.9.5