-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from martinsmith1968/feature/context-menu-options
Feature/context menu options
- Loading branch information
Showing
18 changed files
with
674 additions
and
331 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
# To Do | ||
|
||
- Move Window Positions Menu to Context Menu (Option?) | ||
- Move Saved Desktop Icon Positions Menu to Context Menu (Option?) | ||
- History list of Saved Window Positions | ||
- History list of Saved Desktop Icon Positions | ||
- Add icons to other context menu items | ||
- Support other config value types as required |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
#Include Lib\Logging.ahk | ||
|
||
;-------------------------------------------------------------------------------- | ||
; ResetMenu - Remove all items from a Menu | ||
ResetMenu(menuName) | ||
{ | ||
try Menu, %menuName%, DeleteAll | ||
} | ||
|
||
;-------------------------------------------------------------------------------- | ||
; AddMenuItem - Add a Menu Item to a Menu | ||
AddMenuItem(menuName, text, handler, menuIndex := 0) | ||
{ | ||
If (text = "") | ||
{ | ||
LogText("Adding Menu Separator: " . menuName) | ||
Menu, %menuName%, Add | ||
} | ||
else | ||
{ | ||
LogText("Adding Menu: " . menuName . " - " . text . " = " . handler) | ||
Menu, %menuName%, Add, %text%, %handler% | ||
} | ||
|
||
return menuIndex + 1 | ||
} | ||
|
||
;-------------------------------------------------------------------------------- | ||
; AddMenuItem - Add a Menu Item to a Menu, and set its Icon | ||
AddMenuItemWithIcon(menuName, text, handler, iconFileName, iconIndex, menuIndex := 0) | ||
{ | ||
menuIndex := AddMenuItem(menuName, text, handler, menuIndex) | ||
|
||
if (iconIndex > 0) | ||
{ | ||
try Menu, %menuName%, Icon, %text%, %iconFileName%, %iconIndex% | ||
} | ||
|
||
return menuIndex + 1 | ||
} | ||
|
||
;-------------------------------------------------------------------------------- | ||
; AddMenuItemSeparator - Add a Menu Item separator to a Menu | ||
AddMenuItemSeparator(menuName, menuIndex) | ||
{ | ||
AddMenuItem(menuName, "", "", menuIndex) | ||
} | ||
|
||
;-------------------------------------------------------------------------------- | ||
; EnableMenuItem - Enable / Disable a menu item | ||
EnableMenuItem(menuName, menuTitle, enabled) | ||
{ | ||
state := enabled ? "Enable" : "Disable" | ||
LogText("Enabling: " . menuName . " - " . menuTitle . ", with " . enabled . " = " . state) | ||
|
||
Menu, %menuName%, %state%, %menuTitle% | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.