Comment 7 for bug 593141

Revision history for this message
Timo Reimerdes (timorei) wrote :

Ok, it seems as if the more interesting file is the panel-menu-items.c
I just did:
apt-get source gnome-panel
to get the sources and am fast-reading it a bit, since I never ever before touched this code. ;)

oh boy, seems as if this is actually a rather hardcoded option in the panel-menu:
Lines 1041 to 1069 in panel-menu-items.c:
 panel_menu_items_append_place_item (PANEL_ICON_HOME, NULL,
         name,
         _("Open your personal folder"),
         places_menu,
         G_CALLBACK (activate_home_uri),
         uri);
 g_free (name);
 g_free (uri);

 if (!gconf_client_get_bool (panel_gconf_get_client (),
        DESKTOP_IS_HOME_DIR_KEY,
        NULL)) {
  file = g_file_new_for_path (g_get_user_special_dir (G_USER_DIRECTORY_DESKTOP));
  uri = g_file_get_uri (file);
  g_object_unref (file);

  panel_menu_items_append_place_item (
    PANEL_ICON_DESKTOP, NULL,
    /* Translators: Desktop is used here as in
     * "Desktop Folder" (this is not the Desktop
     * environment). */
    C_("Desktop Folder", "Desktop"),
    _("Open the contents of your desktop in a folder"),
    places_menu,
    G_CALLBACK (activate_desktop_uri),
    /* FIXME: if the dir changes, we'd need to update the drag data since the uri is not the same */
    uri);
  g_free (uri);
 }

Maybe this gives you enough pointers for you code :)