mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-31 11:02:35 +01:00
Also allow relaunching from the window menu.
Allow relaunching an application from its window menu.
This commit is contained in:
committed by
Carlos R. Mafra
parent
8352c9ef60
commit
3d01e5c879
@@ -55,9 +55,10 @@
|
|||||||
#define MC_PROPERTIES 7
|
#define MC_PROPERTIES 7
|
||||||
#define MC_OPTIONS 8
|
#define MC_OPTIONS 8
|
||||||
#define MC_SHORTCUT 8
|
#define MC_SHORTCUT 8
|
||||||
|
#define MC_RELAUNCH 9
|
||||||
|
|
||||||
#define MC_CLOSE 9
|
#define MC_CLOSE 10
|
||||||
#define MC_KILL 10
|
#define MC_KILL 11
|
||||||
|
|
||||||
#define WO_KEEP_ON_TOP 0
|
#define WO_KEEP_ON_TOP 0
|
||||||
#define WO_KEEP_AT_BOTTOM 1
|
#define WO_KEEP_AT_BOTTOM 1
|
||||||
@@ -167,6 +168,10 @@ static void execMenuCommand(WMenu * menu, WMenuEntry * entry)
|
|||||||
wShowInspectorForWindow(wwin);
|
wShowInspectorForWindow(wwin);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case MC_RELAUNCH:
|
||||||
|
(void) RelaunchWindow(wwin);
|
||||||
|
break;
|
||||||
|
|
||||||
case MC_HIDE:
|
case MC_HIDE:
|
||||||
wapp = wApplicationOf(wwin->main_window);
|
wapp = wApplicationOf(wwin->main_window);
|
||||||
wHideApplication(wapp);
|
wHideApplication(wapp);
|
||||||
@@ -454,6 +459,9 @@ static WMenu *createWindowMenu(WScreen * scr)
|
|||||||
wMenuEntrySetCascade(menu, entry, makeMakeShortcutMenu(scr));
|
wMenuEntrySetCascade(menu, entry, makeMakeShortcutMenu(scr));
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
entry = wMenuAddCallback(menu, _("Launch"), execMenuCommand, NULL);
|
||||||
|
entry->rtext = getShortcutString(wKeyBindings[WKBD_RELAUNCH]);
|
||||||
|
|
||||||
entry = wMenuAddCallback(menu, _("Close"), execMenuCommand, NULL);
|
entry = wMenuAddCallback(menu, _("Close"), execMenuCommand, NULL);
|
||||||
entry->rtext = getShortcutString(wKeyBindings[WKBD_CLOSE]);
|
entry->rtext = getShortcutString(wKeyBindings[WKBD_CLOSE]);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user