Skip to content

Commit 9415c3b

Browse files
committed
style(intellij): reformat and cleanup code
1 parent dcb20f7 commit 9415c3b

17 files changed

+32
-42
lines changed

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeCodeStyleSettings.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,4 @@ import com.intellij.psi.codeStyle.CodeStyleSettings
44
import com.intellij.psi.codeStyle.CustomCodeStyleSettings
55

66
class RobotCodeCodeStyleSettings(settings: CodeStyleSettings) :
7-
CustomCodeStyleSettings("GdCodeStyleSettings", settings) {
8-
}
7+
CustomCodeStyleSettings("GdCodeStyleSettings", settings)

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeLangCodeStyleSettingsProvider.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ class RobotCodeLangCodeStyleSettingsProvider : LanguageCodeStyleSettingsProvider
4949
}
5050
}
5151

52-
override fun getCodeSample(settingsType: SettingsType): String? {
52+
override fun getCodeSample(settingsType: SettingsType): String {
5353
return "*** Settings ***\n" +
5454
"Library SeleniumLibrary\n" +
5555
"\n" +

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeParserDefinition.kt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import com.intellij.psi.tree.TokenSet
2222
import org.jetbrains.plugins.textmate.TextMateService
2323
import org.jetbrains.plugins.textmate.language.syntax.lexer.TextMateHighlightingLexer
2424

25-
val FILE = IStubFileElementType<PsiFileStub<RobotFile>>("RobotSuiteFile", RobotFrameworkLanguage);
25+
val FILE = IStubFileElementType<PsiFileStub<RobotFile>>("RobotSuiteFile", RobotFrameworkLanguage)
2626

2727
class RobotCodeParserDefinition : ParserDefinition {
2828

@@ -81,6 +81,4 @@ class RobotPsiParser : PsiParser {
8181
}
8282
}
8383

84-
class RobotPsiElement(type: IElementType) : CompositePsiElement(type) {
85-
86-
}
84+
class RobotPsiElement(type: IElementType) : CompositePsiElement(type)

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeRunConfiguration.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ import com.intellij.execution.configurations.ConfigurationTypeBase
77
class RobotCodeRunConfiguration :
88
ConfigurationTypeBase("robotcode", "RobotCode", "Run Robot Framework Tests", RobotIcons.RobotCode) {
99
init {
10-
addFactory(RobotCodeRunConfigurationFactory(this));
10+
addFactory(RobotCodeRunConfigurationFactory(this))
1111
}
1212
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeRunConfigurationFactory.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package dev.robotcode.robotcode4ij
22

3-
import com.intellij.execution.configurations.ConfigurationFactory;
3+
import com.intellij.execution.configurations.ConfigurationFactory
44
import com.intellij.execution.configurations.ConfigurationType
55
import com.intellij.execution.configurations.RunConfiguration
66
import com.intellij.openapi.project.Project
@@ -16,6 +16,6 @@ class RobotCodeRunConfigurationFactory(type: ConfigurationType) : ConfigurationF
1616
}
1717

1818
override fun getIcon(): Icon? {
19-
return RobotIcons.RobotCode;
19+
return RobotIcons.RobotCode
2020
}
2121
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotCodeTextMateBundleProvider.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@ private fun getBundles(): List<TextMateBundleProvider.PluginBundle> {
1212
class RobotCodeTextMateBundleProvider : TextMateBundleProvider {
1313

1414
override fun getBundles(): List<TextMateBundleProvider.PluginBundle> {
15-
return robotCodeBundle;
15+
return robotCodeBundle
1616
}
1717
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotIcons.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ package dev.robotcode.robotcode4ij
33
import com.intellij.openapi.util.IconLoader
44
import javax.swing.Icon
55

6-
public class RobotIcons {
6+
class RobotIcons {
77
companion object {
8-
val Resource: Icon? = IconLoader.findIcon("/images/robot.svg", RobotIcons.Companion::class.java);
9-
val Suite: Icon? = IconLoader.findIcon("/images/robot.svg", RobotIcons.Companion::class.java);
10-
val RobotCode: Icon? = IconLoader.findIcon("/images/robotcode.svg", RobotIcons.Companion::class.java);
8+
val Resource: Icon? = IconLoader.findIcon("/images/robot.svg", Companion::class.java)
9+
val Suite: Icon? = IconLoader.findIcon("/images/robot.svg", Companion::class.java)
10+
val RobotCode: Icon? = IconLoader.findIcon("/images/robotcode.svg", Companion::class.java)
1111
}
1212

1313
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotResourceFileType.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import com.intellij.openapi.fileTypes.LanguageFileType
44
import com.intellij.openapi.fileTypes.OSFileIdeAssociation
55

66
object RobotResourceFileType : LanguageFileType(RobotFrameworkLanguage), OSFileIdeAssociation {
7-
override fun getName() = "ROBOT_FRAMEWORK_RESOURCE";
8-
override fun getDisplayName() = "Robot Framework Resource";
9-
override fun getDescription() = "Robot Framework resource files";
7+
override fun getName() = "ROBOT_FRAMEWORK_RESOURCE"
8+
override fun getDisplayName() = "Robot Framework Resource"
9+
override fun getDescription() = "Robot Framework resource files"
1010
override fun getDefaultExtension() = "robot"
1111
override fun getIcon() = RobotIcons.Resource
1212
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/RobotSuiteFileType.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import com.intellij.openapi.fileTypes.LanguageFileType
44
import com.intellij.openapi.fileTypes.OSFileIdeAssociation
55

66
object RobotSuiteFileType : LanguageFileType(RobotFrameworkLanguage), OSFileIdeAssociation {
7-
override fun getName() = "ROBOT_FRAMEWORK_SUITE";
8-
override fun getDisplayName() = "Robot Framework Suite";
9-
override fun getDescription() = "Robot Framework suite files";
7+
override fun getName() = "ROBOT_FRAMEWORK_SUITE"
8+
override fun getDisplayName() = "Robot Framework Suite"
9+
override fun getDescription() = "Robot Framework suite files"
1010
override fun getDefaultExtension() = "robot"
1111
override fun getIcon() = RobotIcons.Suite
1212
}

intellij-client/src/main/kotlin/dev/robotcode/robotcode4ij/lsp/RobotCodeLanguageClient.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ class RobotCodeLanguageClient(project: Project?) : IndexAwareLanguageClient(proj
99

1010
override fun handleServerStatusChanged(serverStatus: ServerStatus?) {
1111
if (serverStatus == ServerStatus.started) {
12-
triggerChangeConfiguration();
12+
triggerChangeConfiguration()
1313
}
1414
}
1515

0 commit comments

Comments
 (0)