[maemo-commits] [maemo-commits] r12137 - in projects/haf/trunk/hildon-plugins-settings: . src
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Wed Jun 6 19:23:04 EEST 2007
- Previous message: [maemo-commits] r12136 - in projects/haf/trunk/hildon-desktop: . src
- Next message: [maemo-commits] r12138 - in projects/haf/trunk/hildon-plugins-settings: . data debian src
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: moimart Date: 2007-06-06 19:23:03 +0300 (Wed, 06 Jun 2007) New Revision: 12137 Modified: projects/haf/trunk/hildon-plugins-settings/ChangeLog projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings-dialog.c projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings.c Log: 2007-06-06 Moises Martinez <moises.martinez at nokia.com> * src/hildon-plugin-settings-dialog.c: Fixed toggling checkboxes when using a TreeModelFilter. * src/hildon-plugin-settings.c: Added visibility_filter for Tasknavigator. * ChangeLog updated. Modified: projects/haf/trunk/hildon-plugins-settings/ChangeLog =================================================================== --- projects/haf/trunk/hildon-plugins-settings/ChangeLog 2007-06-06 15:24:33 UTC (rev 12136) +++ projects/haf/trunk/hildon-plugins-settings/ChangeLog 2007-06-06 16:23:03 UTC (rev 12137) @@ -1,5 +1,12 @@ 2007-06-06 Moises Martinez <moises.martinez at nokia.com> + * src/hildon-plugin-settings-dialog.c: Fixed toggling checkboxes when + using a TreeModelFilter. + * src/hildon-plugin-settings.c: Added visibility_filter for + Tasknavigator. + +2007-06-06 Moises Martinez <moises.martinez at nokia.com> + * configure.ac: Added hildon-1 for standalone application. * src/hildon-plugin-settings-dialog.[ch]: - Make Ok & Cancel buttons plubic. Modified: projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings-dialog.c =================================================================== --- projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings-dialog.c 2007-06-06 15:24:33 UTC (rev 12136) +++ projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings-dialog.c 2007-06-06 16:23:03 UTC (rev 12137) @@ -129,7 +129,7 @@ static void hildon_plugin_settings_dialog_renderer_toggled_cb (GtkCellRendererToggle *cell_renderer, gchar *path, - GtkTreeModel *tm); + GtkTreeView *tw); static void hildon_desktop_plugin_settings_dialog_switch_nb_cb (GtkNotebook *nb, GtkNotebookPage *nb_page, @@ -524,7 +524,7 @@ g_signal_connect (G_OBJECT(renderer_toggle), "toggled", G_CALLBACK (hildon_plugin_settings_dialog_renderer_toggled_cb), - gtk_tree_view_get_model (tw)); + (gpointer)tw); } static gboolean @@ -647,6 +647,7 @@ "Icon", GDK_TYPE_PIXBUF, "Mandatory", G_TYPE_BOOLEAN, "X-Settings", HILDON_PLUGIN_TYPE_MODULE_SETTINGS, + "Category", G_TYPE_STRING, NULL); settings->priv->tabs = g_list_append (settings->priv->tabs, tab); @@ -705,28 +706,30 @@ static void hildon_plugin_settings_dialog_renderer_toggled_cb (GtkCellRendererToggle *cell_renderer, gchar *path, - GtkTreeModel *tm) + GtkTreeView *tw) { GtkTreeIter iter; gboolean selected; - + GtkTreeModel *tm = gtk_tree_view_get_model (tw); + if (!gtk_tree_model_get_iter_from_string (tm, &iter, path)) return; - + gtk_tree_model_get (tm, &iter, HP_COL_CHECKBOX, &selected, -1); - + if (GTK_IS_TREE_MODEL_FILTER (tm)) { GtkTreeIter real_iter; - + gtk_tree_model_filter_convert_iter_to_child_iter (GTK_TREE_MODEL_FILTER (tm),&real_iter,&iter); - gtk_list_store_set (GTK_LIST_STORE (tm), &real_iter, - HP_COL_CHECKBOX, !selected, - -1); + gtk_list_store_set + (GTK_LIST_STORE (gtk_tree_model_filter_get_model (GTK_TREE_MODEL_FILTER(tm))), &real_iter, + HP_COL_CHECKBOX, !selected, + -1); } else { @@ -856,3 +859,4 @@ return filter; } + Modified: projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings.c =================================================================== --- projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings.c 2007-06-06 15:24:33 UTC (rev 12136) +++ projects/haf/trunk/hildon-plugins-settings/src/hildon-plugin-settings.c 2007-06-06 16:23:03 UTC (rev 12137) @@ -31,8 +31,13 @@ #include <libintl.h> #define _(a) dgettext(PACKAGE, a) +/* HARDCODE_PARTY */ +/* Plugins to not be shown */ +#define HP_APPLICATION_SWITCHER "/usr/share/applications/hildon-navigator/app-switcher.desktop" +#define HP_SWITCHER_MENU "/usr/share/applications/hildon-navigator/switcher-menu.desktop" + static gboolean -filter_is_visible (GtkTreeModel *model, +_tn_visibility_filter (GtkTreeModel *model, GtkTreeIter *iter, gpointer data) { @@ -44,7 +49,8 @@ &name, -1); - if (g_str_equal (name,"/usr/share/applications/hildon-navigator/hildon-task-navigator-bookmarks.desktop")) + if (g_str_equal (name,HP_APPLICATION_SWITCHER) || + g_str_equal (name,HP_SWITCHER_MENU)) return FALSE; return TRUE; @@ -62,7 +68,7 @@ hildon_plugin_settings_dialog_set_visibility_filter (HILDON_PLUGIN_SETTINGS_DIALOG (dialog), "Tasknavigator", - filter_is_visible, + _tn_visibility_filter, NULL, NULL);
- Previous message: [maemo-commits] r12136 - in projects/haf/trunk/hildon-desktop: . src
- Next message: [maemo-commits] r12138 - in projects/haf/trunk/hildon-plugins-settings: . data debian src
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]