Skip to content

Commit 0c3de27

Browse files
eclipse-platform-botakurtakov
authored andcommitted
Perform clean code of platform/org.eclipse.platform
1 parent 422dc13 commit 0c3de27

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

platform/org.eclipse.platform/src-intro/org/eclipse/platform/internal/CheatSheetStandbyContent.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,9 @@ public Control getControl() {
5656
@Override
5757
public void setInput(Object input) {
5858
// if the new input is null, use cacched input from momento.
59-
if (input != null)
59+
if (input != null) {
6060
this.input = (String) input;
61+
}
6162
viewer.setInput(this.input);
6263
}
6364

@@ -74,16 +75,18 @@ public void dispose() {
7475
@Override
7576
public void saveState(IMemento memento) {
7677
String currentCheatSheetId = viewer.getCheatSheetID();
77-
if (currentCheatSheetId != null)
78+
if (currentCheatSheetId != null) {
7879
memento.putString(MEMENTO_CHEATSHEET_ID_ATT, currentCheatSheetId);
80+
}
7981
}
8082

8183
/**
8284
* Tries to create the last content part viewed, based on content part id..
8385
*/
8486
private String getCachedInput(IMemento memento) {
85-
if (memento == null)
87+
if (memento == null) {
8688
return null;
89+
}
8790
return memento.getString(MEMENTO_CHEATSHEET_ID_ATT);
8891

8992
}

platform/org.eclipse.platform/src-intro/org/eclipse/platform/internal/LaunchUpdateIntroAction.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,9 @@ public LaunchUpdateIntroAction() {
3737
public void run(IIntroSite site, Properties params) {
3838
Shell currentShell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell();
3939
currentShell.getDisplay().asyncExec(() -> {
40-
if (!executeUpdateCommand(COMMAND_P2))
40+
if (!executeUpdateCommand(COMMAND_P2)) {
4141
executeUpdateCommand(COMMAND_UPDATE_MANAGER);
42+
}
4243
});
4344
}
4445

0 commit comments

Comments
 (0)