File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
core/src/main/kotlin/cc/unitmesh/devti/sketch/ui/patch Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -73,7 +73,6 @@ class SingleFileDiffSketch(
73
73
})
74
74
}
75
75
76
- // read content, count add and remove line by '+' and '-' in patch.hunks
77
76
val addLine = patch.hunks.sumOf {
78
77
it.lines.count { it.type == PatchLine .Type .ADD }
79
78
}
@@ -146,7 +145,7 @@ class SingleFileDiffSketch(
146
145
// })
147
146
// }
148
147
149
- val viewDiffButton = JButton (" View" ).apply {
148
+ val viewButton = JButton (" View" ).apply {
150
149
icon = AllIcons .Actions .ListChanges
151
150
toolTipText = AutoDevBundle .message(" sketch.patch.action.viewDiff.tooltip" )
152
151
@@ -157,7 +156,7 @@ class SingleFileDiffSketch(
157
156
})
158
157
}
159
158
160
- val runStreamButton = JButton (" Apply" ).apply {
159
+ val applyButton = JButton (" Apply" ).apply {
161
160
icon = AllIcons .Actions .RunAll
162
161
toolTipText = AutoDevBundle .message(" sketch.patch.action.runDiff.tooltip" )
163
162
isEnabled = appliedPatch?.status == ApplyPatchStatus .SUCCESS
@@ -201,7 +200,7 @@ class SingleFileDiffSketch(
201
200
}
202
201
}
203
202
204
- return listOf (viewDiffButton, runStreamButton , repairButton)
203
+ return listOf (viewButton, applyButton , repairButton)
205
204
}
206
205
207
206
override fun getViewText (): String = currentFile.readText()
You can’t perform that action at this time.
0 commit comments