]> git.pld-linux.org Git - packages/desktop-file-utils.git/blob - desktop-file-utils-directory_noshowin.patch
- add missed computer:// and network://
[packages/desktop-file-utils.git] / desktop-file-utils-directory_noshowin.patch
1 diff -urN aa/desktop-file-utils-0.7/src/menu-entries.c desktop-file-utils-0.7/src/menu-entries.c
2 --- aa/desktop-file-utils-0.7/src/menu-entries.c        2004-07-28 22:11:07.960290344 +0200
3 +++ desktop-file-utils-0.7/src/menu-entries.c   2004-07-28 22:13:30.869564832 +0200
4 @@ -1980,6 +1980,47 @@
5                 g_free (onlyshowin);          
6         }
7         /* End checking for OnlyShowIn */
8 +
9 +       if (!show)
10 +       {
11 +               e = entry_new (ENTRY_DIRECTORY, basename, filename, show);
12 +               g_free (str);
13 +               return e;
14 +       }
15 +       
16 +       /* Check for NoShowIn */
17 +       char *noshowin;
18 +
19 +       show = TRUE;
20 +
21 +       noshowin = find_value (str, "NoShowIn");
22 +
23 +       if (noshowin != NULL)
24 +       {
25 +               char **split;
26 +               int i;
27 +
28 +               split = string_list_from_desktop_value (noshowin);
29 +               i = 0;
30 +               while (split[i] != NULL)
31 +               {
32 +                       if (strcmp (split[i], "GNOME") == 0)
33 +                       {
34 +                               show = FALSE;
35 +                               break;
36 +                       }
37 +
38 +                       ++i;
39 +               }
40 +
41 +               if (!show)
42 +                       menu_verbose ("Not showing \"%s\" due to NoShowIn=%s\n",
43 +                               filename, noshowin);
44 +
45 +               g_strfreev (split);
46 +               g_free (noshowin);          
47 +       }
48 +       /* End checking for NoShowIn */
49         
50         if (!show)
51         {
This page took 0.863788 seconds and 3 git commands to generate.