OSDN Git Service

Merge branch 'japaneseSearch' into develop
[neighbornote/NeighborNote.git] / src / cx / fbn / nevernote / dialog / ConfigDialog.java
index fc60069..aae31c4 100644 (file)
@@ -41,9 +41,9 @@ import com.trolltech.qt.gui.QListWidgetItem;
 import com.trolltech.qt.gui.QPushButton;\r
 import com.trolltech.qt.gui.QStackedWidget;\r
 import com.trolltech.qt.gui.QVBoxLayout;\r
-import com.trolltech.qt.gui.QWidget;\r
 \r
 import cx.fbn.nevernote.Global;\r
+import cx.fbn.nevernote.NeverNote;\r
 import cx.fbn.nevernote.sql.DatabaseConnection;\r
 import cx.fbn.nevernote.sql.driver.NSqlQuery;\r
 public class ConfigDialog extends QDialog {\r
@@ -55,13 +55,14 @@ public class ConfigDialog extends QDialog {
        private final ConfigAppearancePage              appearancePage;\r
        private final ConfigSpellPage                   spellPage;\r
        private final ConfigIndexPage                   indexPage;\r
-       // ICHANGED\r
-       private final ConfigRensoNoteListPage           rensoNoteListPage;\r
+       private final ConfigRensoNoteListPage   rensoNoteListPage;\r
+       private final NeverNote                                 parent;\r
        private final DatabaseConnection conn;\r
        \r
-    private final String iconPath = new String("classpath:cx/fbn/nevernote/icons/");\r
-       \r
-       public ConfigDialog(QWidget parent, DatabaseConnection conn) {\r
+       private final String iconPath = new String("classpath:cx/fbn/nevernote/icons/");\r
+    \r
+       public ConfigDialog(NeverNote parent, DatabaseConnection conn) {\r
+               this.parent = parent;\r
                this.conn = conn;\r
                \r
                contentsWidget = new QListWidget(this);\r
@@ -232,9 +233,10 @@ public class ConfigDialog extends QDialog {
                Global.setBrowseWeight(rensoNoteListPage.getBrowseWeight());\r
                Global.setCopyPasteWeight(rensoNoteListPage.getCopyPasteWeight());\r
                Global.setAddNewNoteWeight(rensoNoteListPage.getAddNewNoteWeight());\r
-               Global.setRensoItemClickWeight(rensoNoteListPage.getRensoItemClickWeight());
-               Global.setSameTagWeight(rensoNoteListPage.getSameTagWeight());
+               Global.setRensoItemClickWeight(rensoNoteListPage.getRensoItemClickWeight());\r
+               Global.setSameTagWeight(rensoNoteListPage.getSameTagWeight());\r
                Global.setSameNotebookWeight(rensoNoteListPage.getSameNotebookWeight());\r
+               Global.setENRelatedNotesWeight(rensoNoteListPage.getENRelatedNotesWeight());\r
                \r
                // ICHANGED\r
                Global.setMergeRensoNote(rensoNoteListPage.getMergeChecked());\r
@@ -242,6 +244,9 @@ public class ConfigDialog extends QDialog {
                Global.setVerifyExclude(rensoNoteListPage.getVerifyExcludeChecked());\r
                Global.setRensoListItemMaximum(rensoNoteListPage.getRensoListItemMaximum());\r
                \r
+               // 連想ノートリストをリフレッシュ\r
+               parent.getRensoNoteList().refreshRensoNoteList(parent.getCurrentNoteGuid());\r
+               \r
                // 全文検索の対象項目を再設定\r
                NSqlQuery nQuery = new NSqlQuery(conn.getConnection());\r
                NSqlQuery rQuery = new NSqlQuery(conn.getResourceConnection()); \r
@@ -276,7 +281,6 @@ public class ConfigDialog extends QDialog {
        // Create icons used for navigating the page\r
        public void createIcons() {\r
                String iconPath = new String("classpath:cx/fbn/nevernote/icons/");\r
-\r
                \r
                QListWidgetItem formatsButton = new QListWidgetItem(contentsWidget);\r
                formatsButton.setText(tr("Appearance"));\r