コミットメタ情報

リビジョン7ed214be8acffe781fb82c8feb0bac1ad386a212 (tree)
日時2013-11-21 23:43:02
作者argius <argius.net@gmai...>
コミッターargius

ログメッセージ

When refreshing ResultSetTable, not only rowCount but columnCount of the table sets zero

変更サマリ

差分

--- a/src/net/argius/stew/ui/window/ResultSetTable.java
+++ b/src/net/argius/stew/ui/window/ResultSetTable.java
@@ -890,7 +890,9 @@ final class ResultSetTable extends JTable implements AnyActionListener, TextSear
890890
891891 @Override
892892 public void reset() {
893- ((DefaultTableModel)getModel()).setRowCount(0);
893+ DefaultTableModel m = (DefaultTableModel)getModel();
894+ m.setColumnCount(0);
895+ m.setRowCount(0);
894896 lastSortedIndex = -1;
895897 lastSortedIsReverse = false;
896898 }
--- a/src/net/argius/stew/ui/window/WindowOutputProcessor.java
+++ b/src/net/argius/stew/ui/window/WindowOutputProcessor.java
@@ -5,14 +5,17 @@ import static net.argius.stew.Bootstrap.getPropertyAsInt;
55 import static net.argius.stew.ui.window.AnyActionKey.*;
66 import static net.argius.stew.ui.window.Utilities.getImageIcon;
77 import static net.argius.stew.ui.window.Utilities.sleep;
8+
89 import java.awt.*;
910 import java.awt.event.*;
1011 import java.io.*;
1112 import java.sql.*;
1213 import java.util.*;
1314 import java.util.List;
15+
1416 import javax.swing.*;
1517 import javax.swing.table.*;
18+
1619 import net.argius.stew.*;
1720 import net.argius.stew.io.*;
1821 import net.argius.stew.ui.*;
@@ -154,9 +157,9 @@ final class WindowOutputProcessor extends JFrame implements OutputProcessor, Any
154157
155158 @SuppressWarnings("unused")
156159 private void clearResultSetTable() {
157- resultSetTable.setVisible(false);
158160 resultSetTable.getTableHeader().setVisible(false);
159161 resultSetTable.reset();
162+ resultSetTable.setVisible(false);
160163 rstsp.setVisible(false);
161164 }
162165
旧リポジトリブラウザで表示