[Jiemamy-notify:1474] commit [2699] インデックスタブの内容が表示されていなかった。 /

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2009年 2月 21日 (土) 15:23:52 JST


Revision: 2699
          http://svn.sourceforge.jp/view?root=jiemamy&view=rev&rev=2699
Author:   daisuke_m
Date:     2009-02-21 15:23:52 +0900 (Sat, 21 Feb 2009)

Log Message:
-----------
インデックスタブの内容が表示されていなかった。 /
refactor

Modified Paths:
--------------
    vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/ColumnSelectDialog.java
    vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialog.java
    vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialogCheckTab.java


-------------- next part --------------
Modified: vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/ColumnSelectDialog.java
===================================================================
--- vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/ColumnSelectDialog.java	2009-02-21 03:32:46 UTC (rev 2698)
+++ vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/ColumnSelectDialog.java	2009-02-21 06:23:52 UTC (rev 2699)
@@ -66,18 +66,11 @@
 		this.columns = columns;
 	}
 	
-// @Override
-// protected void constrainShellSize() {
-// Shell shell = getShell();
-// shell.pack();
-// shell.setSize(shell.getSize().x, 400);
-// }
-	
 	/**
-	 * 選択結果を取得します。
-	 * 
-	 * @return 選択されたカラム
-	 */
+	* 選択結果を取得します。
+	* 
+	* @return 選択されたカラム
+	*/
 	public ColumnModel getResult() {
 		if (selectIndex >= 0 && selectIndex < columns.size()) {
 			return columns.get(selectIndex);
@@ -85,6 +78,13 @@
 		return null;
 	}
 	
+//	@Override
+//	protected void constrainShellSize() {
+//		Shell shell = getShell();
+//		shell.pack();
+//		shell.setSize(shell.getSize().x, 400);
+//	}
+	
 	@Override
 	protected Control createDialogArea(Composite parent) {
 		getShell().setText("Select column"); // RESOURCE

Modified: vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialog.java
===================================================================
--- vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialog.java	2009-02-21 03:32:46 UTC (rev 2698)
+++ vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialog.java	2009-02-21 06:23:52 UTC (rev 2699)
@@ -43,6 +43,7 @@
 
 import org.jiemamy.eclipse.Images;
 import org.jiemamy.eclipse.JiemamyPlugin;
+import org.jiemamy.eclipse.editor.dialog.root.RootEditDialogDataSetTab;
 import org.jiemamy.eclipse.ui.helper.TextSelectionAdapter;
 import org.jiemamy.eclipse.ui.tab.TextEditTab;
 import org.jiemamy.model.RootModel;
@@ -68,16 +69,18 @@
 	
 	private Text txtLogicalName;
 	
+	@SuppressWarnings("unused")
 	private TableEditDialogColumnTab tabColumns;
 	
+	@SuppressWarnings("unused")
 	private TableEditDialogLocalKeyTab tabLocalKeys;
 	
+	@SuppressWarnings("unused")
 	private TableEditDialogCheckTab tabChecks;
 	
+	@SuppressWarnings("unused")
 	private TableEditDialogIndexTab tabIndexes;
 	
-//	private TableEditDialogRecordTab tabRecords;
-	
 	private TextEditTab tabBeginScript;
 	
 	private TextEditTab tabEndScript;
@@ -183,9 +186,6 @@
 		// ---- B-4. インデックス
 		tabIndexes = new TableEditDialogIndexTab(tabFolder, SWT.NULL, tableModel);
 		
-		// ---- B-5. BeginScript
-//		tabRecords = new TableEditDialogRecordTab(tabFolder, SWT.NULL, tableModel);
-		
 		// ---- B-6. BeginScript
 		String beginScript = StringUtils.defaultIfEmpty(tableModel.getBeginScript(), "");
 		tabBeginScript = new TextEditTab(tabFolder, Messages.Tab_Table_BeginScript, beginScript);
@@ -203,14 +203,16 @@
 	
 	@Override
 	protected void okPressed() {
-		if (canExecuteOk()) {
-			tableModel.setName(txtTableName.getText());
-			tableModel.setLogicalName(StringUtils.defaultIfEmpty(txtLogicalName.getText(), null));
-			tableModel.setBeginScript(StringUtils.defaultIfEmpty(tabBeginScript.getTextWidget().getText(), null));
-			tableModel.setEndScript(StringUtils.defaultIfEmpty(tabEndScript.getTextWidget().getText(), null));
-			tableModel.setDescription(StringUtils.defaultIfEmpty(tabDescription.getTextWidget().getText(), null));
-			super.okPressed();
+		if (canExecuteOk() == false) {
+			return;
+			
 		}
+		tableModel.setName(txtTableName.getText());
+		tableModel.setLogicalName(StringUtils.defaultIfEmpty(txtLogicalName.getText(), null));
+		tableModel.setBeginScript(StringUtils.defaultIfEmpty(tabBeginScript.getTextWidget().getText(), null));
+		tableModel.setEndScript(StringUtils.defaultIfEmpty(tabEndScript.getTextWidget().getText(), null));
+		tableModel.setDescription(StringUtils.defaultIfEmpty(tabDescription.getTextWidget().getText(), null));
+		super.okPressed();
 	}
 	
 	private boolean canExecuteOk() {
@@ -232,19 +234,15 @@
 			columnNames.add(column.getName());
 		}
 		
-		boolean entityCheckOk;
-		boolean columnCheckOk;
+		boolean entityCheckOk = true;
+		boolean columnCheckOk = true;
 		
 		if (entityNames.contains(txtTableName.getText())) {
 			entityCheckOk = MessageDialog.openQuestion(getParentShell(), "Confirm", "エンティティ名が重複しますが、よろしいですか?"); // RESOURCE
-		} else {
-			entityCheckOk = true;
 		}
 		
 		if (columnNames.size() != columns.size()) {
 			columnCheckOk = MessageDialog.openQuestion(getParentShell(), "Confirm", "カラム名が重複しますが、よろしいですか?"); // RESOURCE
-		} else {
-			columnCheckOk = true;
 		}
 		
 		return entityCheckOk && columnCheckOk;

Modified: vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialogCheckTab.java
===================================================================
--- vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialogCheckTab.java	2009-02-21 03:32:46 UTC (rev 2698)
+++ vesta/trunk/org.jiemamy.eclipse/src/main/java/org/jiemamy/eclipse/editor/dialog/table/TableEditDialogCheckTab.java	2009-02-21 06:23:52 UTC (rev 2699)
@@ -92,7 +92,6 @@
 		checkEditor = new CheckTableEditor(composite, SWT.NULL);
 		checkEditor.configure();
 		checkEditor.disableEditControls();
-		checkEditor.disableEditControls();
 		
 		getTabItem().setControl(composite);
 	}



Jiemamy-notify メーリングリストの案内
Back to archive index