cp7781 commented on a change in pull request #361: my first refactoring session
URL: https://github.com/apache/incubator-netbeans/pull/361#discussion_r161109835
##########
File path:
refactoring.api/src/org/netbeans/modules/refactoring/api/RefactoringSession.java
##########
@@ -210,34 +189,32 @@ public void start(ProgressEvent event) {
@Override
public void step(ProgressEvent event) {
- current = current + progressStep;
+ current += progressStep;
fireProgressListenerStep((int) current);
}
@Override
public void stop(ProgressEvent event) {
- // do not rely on plugins;
+ /* do not rely on plugins; */
}
+
}
-
+
/**
* do undo of previous doRefactoring()
+ *
* @param saveAfterDone save all if true
* @return instance of Problem or null, if everything is OK
*/
@CheckForNull
public Problem undoRefactoring(final boolean saveAfterDone) {
- return Utilities.runWithOnSaveTasksDisabled(new Action<Problem>() {
- @Override public Problem run() {
- return reallyUndoRefactoring(saveAfterDone);
- }
- });
+ return Utilities.runWithOnSaveTasksDisabled(() ->
reallyUndoRefactoring(saveAfterDone));
}
-
+
private Problem reallyUndoRefactoring(boolean saveAfterDone) {
try {
- ListIterator it = internalList.listIterator(internalList.size());
- fireProgressListenerStart(0, internalList.size()+1);
+ ListIterator internalListIterator =
internalList.listIterator(internalList.size());
Review comment:
It shall be done. Thank you!
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists