Enlightenment CVS committal Author : kwo Project : e16 Module : e
Dir : e16/e/src Modified Files: borders.c menus.c Log Message: Fix action when using keyboard to navigate menus + cleanups. =================================================================== RCS file: /cvsroot/enlightenment/e16/e/src/borders.c,v retrieving revision 1.214 retrieving revision 1.215 diff -u -3 -r1.214 -r1.215 --- borders.c 13 Jul 2004 19:58:58 -0000 1.214 +++ borders.c 14 Jul 2004 19:05:30 -0000 1.215 @@ -1308,18 +1308,21 @@ ewin->skip_ext_pager = 1; ewin->no_actions = 1; ewin->skipfocus = 1; + ewin->skipwinlist = 1; break; case EWIN_TYPE_ICONBOX: ewin->sticky = 1; ewin->skiptask = 1; ewin->skip_ext_pager = 1; ewin->skipfocus = 1; + ewin->skipwinlist = 1; break; case EWIN_TYPE_PAGER: ewin->sticky = 1; ewin->skiptask = 1; ewin->skip_ext_pager = 1; ewin->skipfocus = 1; + ewin->skipwinlist = 1; break; } =================================================================== RCS file: /cvsroot/enlightenment/e16/e/src/menus.c,v retrieving revision 1.145 retrieving revision 1.146 diff -u -3 -r1.145 -r1.146 --- menus.c 12 Jul 2004 23:33:15 -0000 1.145 +++ menus.c 14 Jul 2004 19:05:30 -0000 1.146 @@ -1779,14 +1779,13 @@ lst = EwinListGetAll(&num); for (i = 0; i < num; i++) { - if ((!lst[i]->menu) && (!lst[i]->pager) && (!lst[i]->skipwinlist) - && (EwinGetTitle(lst[i])) && (!lst[i]->ibox)) - { - Esnprintf(s, sizeof(s), "%i", (int)(lst[i]->client.win)); - mi = MenuItemCreate(EwinGetTitle(lst[i]), NULL, - ACTION_FOCUS_SET, s, NULL); - MenuAddItem(m, mi); - } + if (lst[i]->skipwinlist || !EwinGetTitle(lst[i])) + continue; + + Esnprintf(s, sizeof(s), "%lu", lst[i]->client.win); + mi = MenuItemCreate(EwinGetTitle(lst[i]), NULL, + ACTION_FOCUS_SET, s, NULL); + MenuAddItem(m, mi); } EDBUG_RETURN(m); @@ -1810,16 +1809,14 @@ lst = EwinListGetAll(&num); for (i = 0; i < num; i++) { - if (((lst[i]->desktop == desk) || (lst[i]->sticky)) - && (!lst[i]->menu) && (!lst[i]->pager) - && (!lst[i]->skipwinlist) && (lst[i]->client.title) - && (!lst[i]->ibox)) - { - Esnprintf(s, sizeof(s), "%i", (int)(lst[i]->client.win)); - mi = MenuItemCreate(lst[i]->client.title, NULL, - ACTION_FOCUS_SET, s, NULL); - MenuAddItem(m, mi); - } + if (lst[i]->skipwinlist || !EwinGetTitle(lst[i]) || + EwinGetDesk(lst[i]) != j) + continue; + + Esnprintf(s, sizeof(s), "%lu", lst[i]->client.win); + mi = MenuItemCreate(lst[i]->client.title, NULL, + ACTION_FOCUS_SET, s, NULL); + MenuAddItem(m, mi); } EDBUG_RETURN(m); @@ -1851,15 +1848,14 @@ MenuAddItem(mm, mi); for (i = 0; i < num; i++) { - if (((lst[i]->desktop == j) || (lst[i]->sticky)) && (!lst[i]->menu) - && (!lst[i]->pager) && (!lst[i]->skipwinlist) - && (EwinGetTitle(lst[i])) && (!lst[i]->ibox)) - { - Esnprintf(s, sizeof(s), "%i", (int)(lst[i]->client.win)); - mi = MenuItemCreate(EwinGetTitle(lst[i]), NULL, - ACTION_FOCUS_SET, s, NULL); - MenuAddItem(mm, mi); - } + if (lst[i]->skipwinlist || !EwinGetTitle(lst[i]) || + EwinGetDesk(lst[i]) != j) + continue; + + Esnprintf(s, sizeof(s), "%lu", lst[i]->client.win); + mi = MenuItemCreate(EwinGetTitle(lst[i]), NULL, + ACTION_FOCUS_SET, s, NULL); + MenuAddItem(mm, mi); } mm->parent = m; Esnprintf(s, sizeof(s), _("Desktop %i"), j); @@ -2394,19 +2390,14 @@ if (active_menu && active_item && active_menu != m) MenuActivateItem(active_menu, NULL); MenuActivateItem(m, mi); -#if 0 - XWarpPointer(disp, None, mi->win, 0, 0, 0, 0, mi->text_w / 2, - mi->text_h / 2); -#endif break; case XK_Return: if (!mi) break; if (!mi->act_id) break; - ewin = MenuFindContextEwin(m); MenusHide(); - ActionsCall(mi->act_id, ewin, mi->params); + ActionsCall(mi->act_id, NULL, mi->params); break; } ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click _______________________________________________ enlightenment-cvs mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs