-
-
Notifications
You must be signed in to change notification settings - Fork 192
Key mapping capabilities for terminal in Shortcuts prefs #973
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
e4d4da6 to
e86dee8
Compare
e86dee8 to
81b715b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
partial review (147 out of 181)
| if (o == null || getClass() != o.getClass()) | ||
| return false; | ||
| ActionId actionId1 = (ActionId) o; | ||
| return Objects.equals(actionId, actionId1.actionId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't we also compare the type here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw later on that in order to distinguish between, let's say 'find' for terminal and 'find' for the file table, there's code that checks the scope of the action that we look for - in case of checking a terminal action we filter out the non-terminal actions and vice versa. I would prefer to get that logic here - to say that "this" ActionId is with with terminal scope then it doesn't equal any other command that is not with terminal scope, and vice versa
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will try to think about later (after fixing other remarks).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, you're right that it would be better, however I guess I don't want to refactor more with this PR :/
In ActionManager#getActionInstance line 382 - this will return null if we were to check type, because this is being used in context of toolbar via ToolBar:110 that is using ToolBarAttributes#DEFAULT_TOOLBAR_ACTIONS set as Toolbar.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, let's leave this one out of this PR
mucommander-core/src/main/java/com/mucommander/ui/dialog/customization/CommandBarDialog.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/dialog/customization/CommandBarDialog.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/dialog/pref/general/ShortcutsTable.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
still didn't review everything (175 / 181)
| if (o == null || getClass() != o.getClass()) | ||
| return false; | ||
| ActionId actionId1 = (ActionId) o; | ||
| return Objects.equals(actionId, actionId1.actionId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw later on that in order to distinguish between, let's say 'find' for terminal and 'find' for the file table, there's code that checks the scope of the action that we look for - in case of checking a terminal action we filter out the non-terminal actions and vice versa. I would prefer to get that logic here - to say that "this" ActionId is with with terminal scope then it doesn't equal any other command that is not with terminal scope, and vice versa
mucommander-core/src/main/java/com/mucommander/ui/action/ActionCategory.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/action/AcceleratorMap.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/terminal/TerminalSettingsProvider.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/terminal/TerminalSettingsProvider.java
Outdated
Show resolved
Hide resolved
mucommander-translator/src/main/resources/dictionary.properties
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/main/commandbar/CommandBarReader.java
Outdated
Show resolved
Hide resolved
81b715b to
bded831
Compare
|
PR updated with fixes after review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
complete review (so many changes..), also resolved some of the previous comments that were handled, looks good overall!
mucommander-core/src/main/java/com/mucommander/ui/action/ActionKeymap.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/action/ActionKeymapIO.java
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/action/ActionKeymapWriter.java
Outdated
Show resolved
Hide resolved
mucommander-core/src/main/java/com/mucommander/ui/action/ActionManager.java
Outdated
Show resolved
Hide resolved
51af32e to
385c6b6
Compare
|
PR updated, what is left is #973 (comment) - as in the comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one minor comment, besides that lgtm
mucommander-core/src/main/java/com/mucommander/ui/terminal/TerminalSettingsProvider.java
Outdated
Show resolved
Hide resolved
| if (o == null || getClass() != o.getClass()) | ||
| return false; | ||
| ActionId actionId1 = (ActionId) o; | ||
| return Objects.equals(actionId, actionId1.actionId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, let's leave this one out of this PR
385c6b6 to
5e66328
Compare
|
PR updated |
Key mapping capabilities for terminal in Shortcuts prefs.
A lot of changes to achieve that - should be carefully reviewed and tested for backward compatibility especially as it comes to preferences stored in xml (action_keymap.xml, command_bar etc).
By default, no keybindings are set - this means default key binding are being used as set by JediTerm.
Terminal keybindings have different "scope" i.e. it is possible to use existing key bindings from other shortcuts.