From: "Alexey I. Froloff" <[email protected]> Last group from a desktop file is always added to menu regardless of NoDisplay property. Properly handle the NoDisplay and Hidden properties at the end of file.
Signed-off-by: Alexey I. Froloff <[email protected]> --- util/wmmenugen_parse_xdg.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/util/wmmenugen_parse_xdg.c b/util/wmmenugen_parse_xdg.c index f39a83e..16a2fda 100644 --- a/util/wmmenugen_parse_xdg.c +++ b/util/wmmenugen_parse_xdg.c @@ -180,9 +180,13 @@ void parse_xdg(const char *file, void (*addWMMenuEntryCallback)(WMMenuEntry *aEn fclose(fp); - /* at the end of the file, might as well try to menuize what we have */ - if (xdg_to_wm(&xdg, &wm)) - (*addWMMenuEntryCallback)(wm); + if (InGroup) { + /* at the end of the file, might as well try to menuize what we have + * unless there was no group at all or it was marked as hidden + */ + if (xdg_to_wm(&xdg, &wm)) + (*addWMMenuEntryCallback)(wm); + } } -- 1.7.10.2 -- To unsubscribe, send mail to [email protected].
