[maemo-commits] [maemo-commits] r12809 - in projects/haf/trunk/hildon-desktop: . src
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Tue Jul 24 15:44:40 EEST 2007
- Previous message: [maemo-commits] r12808 - projects/haf/trunk/hail/debian
- Next message: [maemo-commits] r12810 - in projects/haf/trunk/hildon-desktop: . libhildondesktop libhildonwm src
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: lucasr Date: 2007-07-24 15:44:38 +0300 (Tue, 24 Jul 2007) New Revision: 12809 Modified: projects/haf/trunk/hildon-desktop/ChangeLog projects/haf/trunk/hildon-desktop/src/hd-applications-menu.c Log: 2007-07-24 Lucas Rocha <lucas.rocha at nokia.com> * src/hd-applications-menu.c (hd_applications_menu_init): check if directories exists before adding monitors in order to avoid desktop process from waking up every now and then. Fixes NB#62159. Modified: projects/haf/trunk/hildon-desktop/ChangeLog =================================================================== --- projects/haf/trunk/hildon-desktop/ChangeLog 2007-07-24 12:12:36 UTC (rev 12808) +++ projects/haf/trunk/hildon-desktop/ChangeLog 2007-07-24 12:44:38 UTC (rev 12809) @@ -1,3 +1,9 @@ +2007-07-24 Lucas Rocha <lucas.rocha at nokia.com> + + * src/hd-applications-menu.c (hd_applications_menu_init): check if + directories exists before adding monitors in order to avoid desktop + process from waking up every now and then. Fixes NB#62159. + 2007-07-23 Moises Martinez <moises.martinez at nokia.com> * src/hn-app-switcher.c: (refresh_app_button): Modified: projects/haf/trunk/hildon-desktop/src/hd-applications-menu.c =================================================================== --- projects/haf/trunk/hildon-desktop/src/hd-applications-menu.c 2007-07-24 12:12:36 UTC (rev 12808) +++ projects/haf/trunk/hildon-desktop/src/hd-applications-menu.c 2007-07-24 12:44:38 UTC (rev 12809) @@ -1190,10 +1190,11 @@ g_free (dir); g_free (conf_file); - + /* Monitor the .desktop directories, so we can regenerate the menu * when a new application is installed */ - if (gnome_vfs_monitor_add (&button->priv->desktop_dir_monitor, + if (g_file_test (HD_DESKTOP_ENTRY_PATH, G_FILE_TEST_EXISTS) && + gnome_vfs_monitor_add (&button->priv->desktop_dir_monitor, HD_DESKTOP_ENTRY_PATH, GNOME_VFS_MONITOR_DIRECTORY, (GnomeVFSMonitorCallback) hd_applications_menu_dir_changed, @@ -1205,8 +1206,10 @@ } /* Monitor the hildon .desktop directories, so we can regenerate the - * menu when a new application is installed */ - if (gnome_vfs_monitor_add (&button->priv->desktop_dir_monitor, + * menu when a new application is installed. Do this only if the default + * directory is the standard one ($datadir/applications) */ + if (g_file_test (HD_DESKTOP_ENTRY_PATH "/hildon", G_FILE_TEST_EXISTS) && + gnome_vfs_monitor_add (&button->priv->desktop_dir_monitor, HD_DESKTOP_ENTRY_PATH "/hildon", GNOME_VFS_MONITOR_DIRECTORY, (GnomeVFSMonitorCallback) hd_applications_menu_dir_changed,
- Previous message: [maemo-commits] r12808 - projects/haf/trunk/hail/debian
- Next message: [maemo-commits] r12810 - in projects/haf/trunk/hildon-desktop: . libhildondesktop libhildonwm src
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]