-
Notifications
You must be signed in to change notification settings - Fork 193
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
Change the classes with shortcut #2413
Conversation
21d07b3
to
402bd75
Compare
Test Results 1 821 files ±0 1 821 suites ±0 1h 52m 18s ⏱️ + 6m 53s For more details on these failures, see this check. Results for commit 473cefe. ± Comparison against base commit 136afb4. ♻️ This comment has been updated with latest results. |
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.
Small nitpicks. I can check functionality later and merge if it works
* | ||
* @param folder | ||
* @return if there are any items which are not shown in the folder (tabs in the | ||
* >> column) |
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.
the ">> column" is called "the chevron"
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.
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.
done
/** | ||
* checks if there are any hidden items | ||
* | ||
* @param folder |
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.
please describe further
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.
done
* >> column) | ||
*/ | ||
private boolean areHiddenItems(CTabFolder folder) { | ||
for (CTabItem i : folder.getItems()) { |
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.
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.
done
/** | ||
* Sets the current selection to the second-to-last item in the given direction. | ||
* | ||
* @param folder |
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.
describe folder and forward
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.
done
e40fc60
to
bb64c62
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
bb64c62
to
66be584
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
66be584
to
9a98ff4
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
9a98ff4
to
867d55e
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
867d55e
to
89130d3
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
89130d3
to
9553700
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
9553700
to
473cefe
Compare
Control control = focusControl; | ||
|
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.
empty diff
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.
done
do { | ||
if (control instanceof CTabFolder folder && isFinalItemInCTabFolder(folder, forward) | ||
&& !areHiddenItems(folder)) { | ||
loopToSecondToFirstItemInCTabFolder(folder, forward); |
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.
"loopToSecondToFirstItemInCTabFolder" is not a desirable name. Are you referring to the "second to last" item or to the "second" item?
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.
done
} | ||
|
||
return false; | ||
} |
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.
by convention, please add a line here
return null; | ||
} | ||
|
||
private boolean areHiddenItems(CTabFolder folder) { | ||
CTabItem[] items = folder.getItems(); | ||
for (CTabItem i : items) { |
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.
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.
done
@@ -70,5 +124,4 @@ protected Method getMethodToExecute() { | |||
} | |||
return null; | |||
} | |||
|
|||
} | |||
} |
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.
please keep the diff clean
} | ||
} | ||
|
||
/**https://github.com/jannisCode/eclipse.jdt.ui.git |
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.
By convention, the first line of javadoc comments is empty (atleast that's what I have seen everywhere else)
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.
done
} | ||
|
||
/** | ||
* Sets the current selection to the second-to-last item in the given direction. |
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.
second to last? or second to first?
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.
done
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
473cefe
to
575359a
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
575359a
to
9bc6fff
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist eclipse-platform#2413
3e7bafa
to
aa3f7d1
Compare
aa3f7d1
to
69f6e45
Compare
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
Tab change can now handle the chevron. And after reaching the last tab, it jumps to the first, if chevron doesn´t exist
This PR finishes the PR started by @Wittmaxi , who also did most of the work here: #1874
The objective of @Wittmaxi ´s PR is to be able to expand the functionality of the nextTab shortcut (default crtl + pgdown) so that after reaching the last tab, one more click changes the active tab back to the first one.
What this PR does
When there are too many tabs open, #1874 still went back to the first tab, ignoring the remaining tabs stored in the chevron (the >> container).
With the changes from this PR, when there are stored tabs in the chevron, clicking once more after the last tab has the same functionality as the default eclipse, going into the chevron.
tabaction.mp4