File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
sqldev/src/main/java/org/utplsql/sqldev/ui/runner Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -25,18 +25,29 @@ import org.utplsql.sqldev.resources.UtplsqlResources
25
25
class TestOverviewTableModel extends DefaultTableModel {
26
26
LinkedHashMap<String , Test > tests
27
27
String commonPrefix
28
+ boolean commonPrefixCalculated
28
29
29
30
new () {
30
31
super ()
31
32
}
32
33
34
+ private def calcCommonPrefix () {
35
+ if (! commonPrefixCalculated && tests. size > 0 ) {
36
+ this . commonPrefix = PrefixTools . commonPrefix(tests. keySet. toList)
37
+ fireTableDataChanged()
38
+ commonPrefixCalculated = true
39
+ }
40
+ }
41
+
33
42
def setModel (LinkedHashMap<String , Test > tests ) {
43
+ commonPrefixCalculated = false
34
44
this . tests = tests
35
- this . commonPrefix = PrefixTools . commonPrefix(tests . keySet . toList)
45
+ calcCommonPrefix
36
46
fireTableDataChanged()
37
47
}
38
48
39
49
def getTestIdColumnName () {
50
+ calcCommonPrefix
40
51
if (commonPrefix == = null || commonPrefix == " " ) {
41
52
return UtplsqlResources . getString(" RUNNER_TEST_ID" )
42
53
} else {
You can’t perform that action at this time.
0 commit comments