Skip to content

Commit 1cf2008

Browse files
authored
Merge pull request #19 from adrienpessu/fix_issues6
another try
2 parents dbefa1b + 774ad0d commit 1cf2008

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ pluginGroup = com.github.adrienpessu.sarifviewer
44
pluginName = SARIF-viewer
55
pluginRepositoryUrl = https://github.com/adrienpessu/SARIF-viewer
66
# SemVer format -> https://semver.org
7-
pluginVersion = 0.0.1
7+
pluginVersion = 0.0.6
88

99
# Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
1010
pluginSinceBuild = 223

src/main/kotlin/com/github/adrienpessu/sarifviewer/toolWindow/SarifViewerWindowFactory.kt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ import git4idea.repo.GitRepositoryChangeListener
2626
import git4idea.repo.GitRepositoryManager
2727
import java.awt.Component
2828
import java.awt.Desktop
29+
import java.awt.event.ActionListener
2930
import java.io.BufferedReader
3031
import java.io.File
3132
import java.io.FileReader
@@ -205,7 +206,7 @@ class SarifViewerWindowFactory : ToolWindowFactory {
205206
jToolBar.alignmentX = Component.LEFT_ALIGNMENT
206207
jToolBar.add(refreshButton)
207208

208-
selectList.addActionListener { event ->
209+
selectList.addActionListener(ActionListener() { event ->
209210
val comboBox = event.source as JComboBox<*>
210211
if (event.actionCommand == "comboBoxChanged" && comboBox.selectedItem != null) {
211212
val selectedOption = comboBox.selectedItem
@@ -224,7 +225,7 @@ class SarifViewerWindowFactory : ToolWindowFactory {
224225
add(JLabel("No Git repository found"))
225226
}
226227
}
227-
}
228+
})
228229

229230
jToolBar.add(selectList)
230231

@@ -252,7 +253,7 @@ class SarifViewerWindowFactory : ToolWindowFactory {
252253
root.add(ruleNode)
253254
}
254255

255-
refreshButton.addActionListener {
256+
refreshButton.addActionListener(ActionListener(){
256257
clearJSplitPane()
257258
populateCombo(currentBranch, token, repositoryFullName)
258259
val mapSarif = extractSarif(token, repositoryFullName)
@@ -262,7 +263,7 @@ class SarifViewerWindowFactory : ToolWindowFactory {
262263
thisLogger().info("Load result for the repository $repositoryFullName and branch ${currentBranch.name}")
263264
buildContent(mapSarif, token, repositoryFullName, currentBranch)
264265
}
265-
}
266+
})
266267

267268
myList = JTree(root)
268269

0 commit comments

Comments
 (0)