Skip to content

Commit

Permalink
fix: hidden pop button when user playing shortcut
Browse files Browse the repository at this point in the history
  • Loading branch information
AkaShark committed Dec 27, 2023
1 parent 26e4e99 commit 363b879
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Easydict/Feature/Shortcut/EZShortcut.m
Original file line number Diff line number Diff line change
Expand Up @@ -48,23 +48,29 @@ + (void)setup {
[[MASShortcutBinder sharedBinder] setBindingOptions:@{NSValueTransformerNameBindingOption: NSSecureUnarchiveFromDataTransformerName}];
*/

// hidden pop button when user playing shortcut
[[MASShortcutBinder sharedBinder] bindShortcutWithDefaultsKey:EZSelectionShortcutKey toAction:^{
[windowManager.popButtonWindow close];
[windowManager selectTextTranslate];
}];

[[MASShortcutBinder sharedBinder] bindShortcutWithDefaultsKey:EZSnipShortcutKey toAction:^{
[windowManager.popButtonWindow close];
[windowManager snipTranslate];
}];

[[MASShortcutBinder sharedBinder] bindShortcutWithDefaultsKey:EZInputShortcutKey toAction:^{
[windowManager.popButtonWindow close];
[windowManager inputTranslate];
}];

[[MASShortcutBinder sharedBinder] bindShortcutWithDefaultsKey:EZShowMiniShortcutKey toAction:^{
[windowManager.popButtonWindow close];
[windowManager showMiniFloatingWindow];
}];

[[MASShortcutBinder sharedBinder] bindShortcutWithDefaultsKey:EZScreenshotOCRShortcutKey toAction:^{
[windowManager.popButtonWindow close];
[windowManager screenshotOCR];
}];

Expand Down

0 comments on commit 363b879

Please sign in to comment.