]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Take care to listen for changes of the settings-widgets after loadSettings() is invok...
authorPeter Penz <peter.penz19@gmail.com>
Fri, 5 Nov 2010 17:32:46 +0000 (17:32 +0000)
committerPeter Penz <peter.penz19@gmail.com>
Fri, 5 Nov 2010 17:32:46 +0000 (17:32 +0000)
svn path=/trunk/KDE/kdebase/apps/; revision=1193350

src/settings/general/behaviorsettingspage.cpp
src/settings/general/contextmenusettingspage.cpp
src/settings/general/previewssettingspage.cpp
src/settings/general/statusbarsettingspage.cpp
src/settings/navigation/navigationsettingspage.cpp
src/settings/startup/startupsettingspage.cpp
src/settings/trash/trashsettingspage.cpp
src/settings/viewmodes/columnviewsettingspage.cpp
src/settings/viewmodes/detailsviewsettingspage.cpp
src/settings/viewmodes/iconsviewsettingspage.cpp

index 0dae09d525959c24bc2533761db8ed4a100a26e5..0864a4bba89143b57af386b21db8870a70f46480 100644 (file)
@@ -59,10 +59,8 @@ BehaviorSettingsPage::BehaviorSettingsPage(const KUrl& url, QWidget* parent) :
     propsBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
 
     m_localProps = new QRadioButton(i18nc("@option:radio", "Remember view properties for each folder"), propsBox);
     propsBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
 
     m_localProps = new QRadioButton(i18nc("@option:radio", "Remember view properties for each folder"), propsBox);
-    connect(m_localProps, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     m_globalProps = new QRadioButton(i18nc("@option:radio", "Use common view properties for all folders"), propsBox);
 
     m_globalProps = new QRadioButton(i18nc("@option:radio", "Use common view properties for all folders"), propsBox);
-    connect(m_globalProps, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     QVBoxLayout* propsBoxLayout = new QVBoxLayout(propsBox);
     propsBoxLayout->addWidget(m_localProps);
 
     QVBoxLayout* propsBoxLayout = new QVBoxLayout(propsBox);
     propsBoxLayout->addWidget(m_localProps);
@@ -73,13 +71,10 @@ BehaviorSettingsPage::BehaviorSettingsPage(const KUrl& url, QWidget* parent) :
     confirmBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
     m_confirmMoveToTrash = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                                "Moving files or folders to trash"), confirmBox);
     confirmBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
     m_confirmMoveToTrash = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                                "Moving files or folders to trash"), confirmBox);
-    connect(m_confirmMoveToTrash, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
     m_confirmDelete = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                           "Deleting files or folders"), confirmBox);
     m_confirmDelete = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                           "Deleting files or folders"), confirmBox);
-    connect(m_confirmDelete, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
     m_confirmClosingMultipleTabs = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                                        "Closing windows with multiple tabs"), confirmBox);
     m_confirmClosingMultipleTabs = new QCheckBox(i18nc("@option:check Ask for Confirmation When",
                                                        "Closing windows with multiple tabs"), confirmBox);
-    connect(m_confirmClosingMultipleTabs, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     QVBoxLayout* confirmBoxLayout = new QVBoxLayout(confirmBox);
     confirmBoxLayout->addWidget(m_confirmMoveToTrash);
 
     QVBoxLayout* confirmBoxLayout = new QVBoxLayout(confirmBox);
     confirmBoxLayout->addWidget(m_confirmMoveToTrash);
@@ -88,30 +83,23 @@ BehaviorSettingsPage::BehaviorSettingsPage(const KUrl& url, QWidget* parent) :
 
     // 'Rename inline'
     m_renameInline = new QCheckBox(i18nc("@option:check", "Rename inline"), this);
 
     // 'Rename inline'
     m_renameInline = new QCheckBox(i18nc("@option:check", "Rename inline"), this);
-    connect(m_renameInline, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // 'Show tooltips'
     QWidget* toolTipContainer = new QWidget(this);
     QHBoxLayout* toolTipsLayout = new QHBoxLayout(toolTipContainer);
     toolTipsLayout->setMargin(0);
     m_showToolTips = new QCheckBox(i18nc("@option:check", "Show tooltips"), toolTipContainer);
 
     // 'Show tooltips'
     QWidget* toolTipContainer = new QWidget(this);
     QHBoxLayout* toolTipsLayout = new QHBoxLayout(toolTipContainer);
     toolTipsLayout->setMargin(0);
     m_showToolTips = new QCheckBox(i18nc("@option:check", "Show tooltips"), toolTipContainer);
-    connect(m_showToolTips, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
-    connect(m_showToolTips, SIGNAL(toggled(bool)), this, SLOT(updateConfigureButton()));
 
     m_configureToolTips = new QLabel(toolTipContainer);
 
     m_configureToolTips = new QLabel(toolTipContainer);
-    connect(m_configureToolTips, SIGNAL(linkActivated(const QString&)),
-            this, SLOT(configureToolTips()));
 
     toolTipsLayout->addWidget(m_showToolTips);
     toolTipsLayout->addWidget(m_configureToolTips, 1, Qt::AlignLeft);
 
     // 'Show selection marker'
     m_showSelectionToggle = new QCheckBox(i18nc("@option:check", "Show selection marker"), this);
 
     toolTipsLayout->addWidget(m_showToolTips);
     toolTipsLayout->addWidget(m_configureToolTips, 1, Qt::AlignLeft);
 
     // 'Show selection marker'
     m_showSelectionToggle = new QCheckBox(i18nc("@option:check", "Show selection marker"), this);
-    connect(m_showSelectionToggle, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // 'Natural sorting of items'
     m_naturalSorting = new QCheckBox(i18nc("option:check", "Natural sorting of items"), this);
 
     // 'Natural sorting of items'
     m_naturalSorting = new QCheckBox(i18nc("option:check", "Natural sorting of items"), this);
-    connect(m_naturalSorting, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     topLayout->addWidget(propsBox);
     topLayout->addWidget(confirmBox);
 
     topLayout->addWidget(propsBox);
     topLayout->addWidget(confirmBox);
@@ -122,6 +110,18 @@ BehaviorSettingsPage::BehaviorSettingsPage(const KUrl& url, QWidget* parent) :
     topLayout->addStretch();
 
     loadSettings();
     topLayout->addStretch();
 
     loadSettings();
+
+    connect(m_localProps, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_globalProps, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_confirmMoveToTrash, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_confirmDelete, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_confirmClosingMultipleTabs, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_renameInline, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_showToolTips, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_showToolTips, SIGNAL(toggled(bool)), this, SLOT(updateConfigureButton()));
+    connect(m_configureToolTips, SIGNAL(linkActivated(const QString&)), this, SLOT(configureToolTips()));
+    connect(m_showSelectionToggle, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_naturalSorting, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 }
 
 BehaviorSettingsPage::~BehaviorSettingsPage()
 }
 
 BehaviorSettingsPage::~BehaviorSettingsPage()
index 233e899b4a657d25035b25c2d0f433b90a513029..592e25ba7667d326e4946eacd94a023e9e9118cf 100644 (file)
@@ -41,10 +41,8 @@ ContextMenuSettingsPage::ContextMenuSettingsPage(QWidget* parent) :
     vBox->setSpacing(KDialog::spacingHint());
 
     m_showDeleteCommand = new QCheckBox(i18nc("@option:check", "Show 'Delete' command"), vBox);
     vBox->setSpacing(KDialog::spacingHint());
 
     m_showDeleteCommand = new QCheckBox(i18nc("@option:check", "Show 'Delete' command"), vBox);
-    connect(m_showDeleteCommand, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     m_showCopyMoveMenu = new QCheckBox(i18nc("@option:check", "Show 'Copy To' and 'Move To' commands"), vBox);
 
     m_showCopyMoveMenu = new QCheckBox(i18nc("@option:check", "Show 'Copy To' and 'Move To' commands"), vBox);
-    connect(m_showCopyMoveMenu, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
@@ -54,6 +52,9 @@ ContextMenuSettingsPage::ContextMenuSettingsPage(QWidget* parent) :
     topLayout->addWidget(vBox);
 
     loadSettings();
     topLayout->addWidget(vBox);
 
     loadSettings();
+
+    connect(m_showDeleteCommand, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_showCopyMoveMenu, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 }
 
 ContextMenuSettingsPage::~ContextMenuSettingsPage()
 }
 
 ContextMenuSettingsPage::~ContextMenuSettingsPage()
index 1059e854770bcd3413137e012464199ef0fa9e23..265dc209faaa2b4e055cb27509d18bbc05e5b095 100644 (file)
@@ -65,8 +65,6 @@ PreviewsSettingsPage::PreviewsSettingsPage(QWidget* parent) :
     m_previewPluginsList = new QListWidget(this);
     m_previewPluginsList->setSortingEnabled(true);
     m_previewPluginsList->setSelectionMode(QAbstractItemView::NoSelection);
     m_previewPluginsList = new QListWidget(this);
     m_previewPluginsList->setSortingEnabled(true);
     m_previewPluginsList->setSelectionMode(QAbstractItemView::NoSelection);
-    connect(m_previewPluginsList, SIGNAL(itemClicked(QListWidgetItem*)),
-            this, SIGNAL(changed()));
 
     QVBoxLayout* listBoxLayout = new QVBoxLayout(listBox);
     listBoxLayout->addWidget(m_previewPluginsList);
 
     QVBoxLayout* listBoxLayout = new QVBoxLayout(listBox);
     listBoxLayout->addWidget(m_previewPluginsList);
@@ -81,8 +79,6 @@ PreviewsSettingsPage::PreviewsSettingsPage(QWidget* parent) :
     m_localFileSizeBox->setSingleStep(1);
     m_localFileSizeBox->setSuffix(QLatin1String(" MB"));
     m_localFileSizeBox->setRange(0, 9999); /* MB */
     m_localFileSizeBox->setSingleStep(1);
     m_localFileSizeBox->setSuffix(QLatin1String(" MB"));
     m_localFileSizeBox->setRange(0, 9999); /* MB */
-    connect(m_localFileSizeBox, SIGNAL(valueChanged(int)),
-            this, SIGNAL(changed()));
 
     QLabel* remoteFileSizeLabel = new QLabel(i18nc("@label Don't create previews for: <Remote files above:> XX MByte",
                                                    "Remote files above:"), this);
 
     QLabel* remoteFileSizeLabel = new QLabel(i18nc("@label Don't create previews for: <Remote files above:> XX MByte",
                                                    "Remote files above:"), this);
@@ -91,8 +87,6 @@ PreviewsSettingsPage::PreviewsSettingsPage(QWidget* parent) :
     m_remoteFileSizeBox->setSingleStep(1);
     m_remoteFileSizeBox->setSuffix(QLatin1String(" MB"));
     m_remoteFileSizeBox->setRange(0, 9999); /* MB */
     m_remoteFileSizeBox->setSingleStep(1);
     m_remoteFileSizeBox->setSuffix(QLatin1String(" MB"));
     m_remoteFileSizeBox->setRange(0, 9999); /* MB */
-    connect(m_remoteFileSizeBox, SIGNAL(valueChanged(int)),
-            this, SIGNAL(changed()));
 
     QGridLayout* fileSizeBoxLayout = new QGridLayout(fileSizeBox);
     fileSizeBoxLayout->addWidget(localFileSizeLabel, 0, 0, Qt::AlignRight);
 
     QGridLayout* fileSizeBoxLayout = new QGridLayout(fileSizeBox);
     fileSizeBoxLayout->addWidget(localFileSizeLabel, 0, 0, Qt::AlignRight);
@@ -104,6 +98,10 @@ PreviewsSettingsPage::PreviewsSettingsPage(QWidget* parent) :
     topLayout->addWidget(fileSizeBox);
 
     loadSettings();
     topLayout->addWidget(fileSizeBox);
 
     loadSettings();
+
+    connect(m_previewPluginsList, SIGNAL(itemClicked(QListWidgetItem*)), this, SIGNAL(changed()));
+    connect(m_localFileSizeBox, SIGNAL(valueChanged(int)), this, SIGNAL(changed()));
+    connect(m_remoteFileSizeBox, SIGNAL(valueChanged(int)), this, SIGNAL(changed()));
 }
 
 
 }
 
 
index 5c2d34af80b7f3fb5523e0d7b6ba54f5286b2499..4d9b9a3f2c7257fb58708a0e015717979bc54fb4 100644 (file)
@@ -40,10 +40,8 @@ StatusBarSettingsPage::StatusBarSettingsPage(QWidget* parent) :
     vBox->setSpacing(KDialog::spacingHint());
 
     m_showZoomSlider = new QCheckBox(i18nc("@option:check", "Show zoom slider"), vBox);
     vBox->setSpacing(KDialog::spacingHint());
 
     m_showZoomSlider = new QCheckBox(i18nc("@option:check", "Show zoom slider"), vBox);
-    connect(m_showZoomSlider, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     m_showSpaceInfo = new QCheckBox(i18nc("@option:check", "Show space information"), vBox);
 
     m_showSpaceInfo = new QCheckBox(i18nc("@option:check", "Show space information"), vBox);
-    connect(m_showSpaceInfo, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
@@ -53,6 +51,9 @@ StatusBarSettingsPage::StatusBarSettingsPage(QWidget* parent) :
     topLayout->addWidget(vBox);
 
     loadSettings();
     topLayout->addWidget(vBox);
 
     loadSettings();
+
+    connect(m_showZoomSlider, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_showSpaceInfo, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 }
 
 StatusBarSettingsPage::~StatusBarSettingsPage()
 }
 
 StatusBarSettingsPage::~StatusBarSettingsPage()
index 31f4d47c0b02706275056a0ded81438bf26ee747..00ea3aad3ea59b3f91eeeeda31df4c8a94d4d82a 100644 (file)
@@ -50,20 +50,16 @@ NavigationSettingsPage::NavigationSettingsPage(QWidget* parent) :
     mouseBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
     m_singleClick = new QRadioButton(i18nc("@option:check Mouse Settings",
                                            "Single-click to open files and folders"), mouseBox);
     mouseBox->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum);
     m_singleClick = new QRadioButton(i18nc("@option:check Mouse Settings",
                                            "Single-click to open files and folders"), mouseBox);
-    connect(m_singleClick, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
     m_doubleClick = new QRadioButton(i18nc("@option:check Mouse Settings",
                                            "Double-click to open files and folders"), mouseBox);
     m_doubleClick = new QRadioButton(i18nc("@option:check Mouse Settings",
                                            "Double-click to open files and folders"), mouseBox);
-    connect(m_doubleClick, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     QVBoxLayout* mouseBoxLayout = new QVBoxLayout(mouseBox);
     mouseBoxLayout->addWidget(m_singleClick);
     mouseBoxLayout->addWidget(m_doubleClick);
 
     m_openArchivesAsFolder = new QCheckBox(i18nc("@option:check", "Open archives as folder"), vBox);
 
     QVBoxLayout* mouseBoxLayout = new QVBoxLayout(mouseBox);
     mouseBoxLayout->addWidget(m_singleClick);
     mouseBoxLayout->addWidget(m_doubleClick);
 
     m_openArchivesAsFolder = new QCheckBox(i18nc("@option:check", "Open archives as folder"), vBox);
-    connect(m_openArchivesAsFolder, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     m_autoExpandFolders = new QCheckBox(i18nc("option:check", "Open folders during drag operations"), vBox);
 
     m_autoExpandFolders = new QCheckBox(i18nc("option:check", "Open folders during drag operations"), vBox);
-    connect(m_autoExpandFolders, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
@@ -73,6 +69,11 @@ NavigationSettingsPage::NavigationSettingsPage(QWidget* parent) :
     topLayout->addWidget(vBox);
 
     loadSettings();
     topLayout->addWidget(vBox);
 
     loadSettings();
+
+    connect(m_singleClick, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_doubleClick, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_openArchivesAsFolder, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
+    connect(m_autoExpandFolders, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 }
 
 NavigationSettingsPage::~NavigationSettingsPage()
 }
 
 NavigationSettingsPage::~NavigationSettingsPage()
index 907b3f2cd33d633d5ce7711fb841ba32dd101d1e..4dd7d19f55cf07728e4097de2355b819cb83fb3e 100644 (file)
@@ -98,8 +98,7 @@ StartupSettingsPage::StartupSettingsPage(const KUrl& url, QWidget* parent) :
 
     loadSettings();
 
 
     loadSettings();
 
-    // Connecting the signals must be done after loading the settings
-    connect(m_homeUrl, SIGNAL(textChanged(const QString&)), this, SIGNAL(changed()));
+    connect(m_homeUrl, SIGNAL(textChanged(const QString&)), this, SLOT(slotSettingsChanged()));
     connect(m_splitView,    SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
     connect(m_editableUrl,  SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
     connect(m_showFullPath, SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
     connect(m_splitView,    SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
     connect(m_editableUrl,  SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
     connect(m_showFullPath, SIGNAL(toggled(bool)), this, SLOT(slotSettingsChanged()));
index e23028b082accd39936ccf55268f7cc2c78acbf2..f507cbab5baf4182717b87f2bc08c5cb43af57a9 100644 (file)
@@ -37,7 +37,6 @@ TrashSettingsPage::TrashSettingsPage(QWidget* parent) :
     vBox->setSpacing(spacing);
 
     m_proxy = new KCModuleProxy("kcmtrash");
     vBox->setSpacing(spacing);
 
     m_proxy = new KCModuleProxy("kcmtrash");
-    connect(m_proxy, SIGNAL(changed(bool)), this, SIGNAL(changed()));
     topLayout->addWidget(m_proxy);
 
     // Add a dummy widget with no restriction regarding
     topLayout->addWidget(m_proxy);
 
     // Add a dummy widget with no restriction regarding
@@ -47,6 +46,8 @@ TrashSettingsPage::TrashSettingsPage(QWidget* parent) :
     topLayout->addWidget(vBox);
 
     loadSettings();
     topLayout->addWidget(vBox);
 
     loadSettings();
+
+    connect(m_proxy, SIGNAL(changed(bool)), this, SIGNAL(changed()));
 }
 
 TrashSettingsPage::~TrashSettingsPage()
 }
 
 TrashSettingsPage::~TrashSettingsPage()
index 2a6265f2fd4d80bb66663cb4efdb6cfdae0e4dae..0919e1618ff03f36df7dbe737ea7f6109fa0d441 100644 (file)
@@ -61,18 +61,12 @@ ColumnViewSettingsPage::ColumnViewSettingsPage(QWidget* parent) :
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
-    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)),
-            this, SIGNAL(changed()));
-    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)),
-            this, SIGNAL(changed()));
-
     // create "Text" properties
     QGroupBox* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
     textGroup->setSizePolicy(sizePolicy);
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
     // create "Text" properties
     QGroupBox* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
     textGroup->setSizePolicy(sizePolicy);
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
-    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
 
     QLabel* textWidthLabel = new QLabel(i18nc("@label:listbox", "Text width:"), textGroup);
     m_textWidthBox = new KComboBox(textGroup);
 
     QLabel* textWidthLabel = new QLabel(i18nc("@label:listbox", "Text width:"), textGroup);
     m_textWidthBox = new KComboBox(textGroup);
@@ -80,7 +74,6 @@ ColumnViewSettingsPage::ColumnViewSettingsPage(QWidget* parent) :
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Medium"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Large"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Huge"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Medium"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Large"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Huge"));
-    connect(m_textWidthBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 
     QGridLayout* textGroupLayout = new QGridLayout(textGroup);
     textGroupLayout->addWidget(fontLabel, 0, 0, Qt::AlignRight);
 
     QGridLayout* textGroupLayout = new QGridLayout(textGroup);
     textGroupLayout->addWidget(fontLabel, 0, 0, Qt::AlignRight);
@@ -94,6 +87,11 @@ ColumnViewSettingsPage::ColumnViewSettingsPage(QWidget* parent) :
     new QWidget(this);
 
     loadSettings();
     new QWidget(this);
 
     loadSettings();
+
+    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
+    connect(m_textWidthBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 }
 
 ColumnViewSettingsPage::~ColumnViewSettingsPage()
 }
 
 ColumnViewSettingsPage::~ColumnViewSettingsPage()
index 253d12a799b15d16d97de94432c61a33b8348f3a..79fedd5102187dbc86e31ca088381337c5b5bba2 100644 (file)
@@ -61,18 +61,12 @@ DetailsViewSettingsPage::DetailsViewSettingsPage(QWidget* parent) :
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
-    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)),
-            this, SIGNAL(changed()));
-    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)),
-            this, SIGNAL(changed()));
-
     // create "Text" properties
     QWidget* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
     textGroup->setSizePolicy(sizePolicy);
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
     // create "Text" properties
     QWidget* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
     textGroup->setSizePolicy(sizePolicy);
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
-    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
 
     QHBoxLayout* textLayout = new QHBoxLayout(textGroup);
     textLayout->addWidget(fontLabel, 0, Qt::AlignRight);
 
     QHBoxLayout* textLayout = new QHBoxLayout(textGroup);
     textLayout->addWidget(fontLabel, 0, Qt::AlignRight);
@@ -80,7 +74,6 @@ DetailsViewSettingsPage::DetailsViewSettingsPage(QWidget* parent) :
 
     // create "Expandable Folders" checkbox
     m_expandableFolders = new QCheckBox(i18nc("@option:check", "Expandable folders"), this);
 
     // create "Expandable Folders" checkbox
     m_expandableFolders = new QCheckBox(i18nc("@option:check", "Expandable folders"), this);
-    connect(m_expandableFolders, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
 
     // Add a dummy widget with no restriction regarding
     // a vertical resizing. This assures that the dialog layout
@@ -88,6 +81,11 @@ DetailsViewSettingsPage::DetailsViewSettingsPage(QWidget* parent) :
     new QWidget(this);
 
     loadSettings();
     new QWidget(this);
 
     loadSettings();
+
+    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
+    connect(m_expandableFolders, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
 }
 
 DetailsViewSettingsPage::~DetailsViewSettingsPage()
 }
 
 DetailsViewSettingsPage::~DetailsViewSettingsPage()
index a01b4a2db6e4b06be2adace39627a2c06f74aec2..a711254c339f3f6d5cb51b38b3ef7ed04165853b 100644 (file)
@@ -67,11 +67,6 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
     m_iconSizeGroupBox->setDefaultSizeRange(min, max);
     m_iconSizeGroupBox->setPreviewSizeRange(min, max);
 
-    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)),
-            this, SIGNAL(changed()));
-    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)),
-            this, SIGNAL(changed()));
-
     // create 'Text' group for selecting the font, the number of lines
     // and the text width
     QGroupBox* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
     // create 'Text' group for selecting the font, the number of lines
     // and the text width
     QGroupBox* textGroup = new QGroupBox(i18nc("@title:group", "Text"), this);
@@ -79,13 +74,11 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
 
     QLabel* fontLabel = new QLabel(i18nc("@label:listbox", "Font:"), textGroup);
     m_fontRequester = new DolphinFontRequester(textGroup);
-    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
 
     QLabel* textlinesCountLabel = new QLabel(i18nc("@label:textbox", "Number of lines:"), textGroup);
     m_textlinesCountBox = new KIntSpinBox(textGroup);
     m_textlinesCountBox->setMinimum(1);
     m_textlinesCountBox->setMaximum(5);
 
     QLabel* textlinesCountLabel = new QLabel(i18nc("@label:textbox", "Number of lines:"), textGroup);
     m_textlinesCountBox = new KIntSpinBox(textGroup);
     m_textlinesCountBox->setMinimum(1);
     m_textlinesCountBox->setMaximum(5);
-    connect(m_textlinesCountBox, SIGNAL(valueChanged(int)), this, SIGNAL(changed()));
 
     QLabel* textWidthLabel = new QLabel(i18nc("@label:listbox", "Text width:"), textGroup);
     m_textWidthBox = new KComboBox(textGroup);
 
     QLabel* textWidthLabel = new QLabel(i18nc("@label:listbox", "Text width:"), textGroup);
     m_textWidthBox = new KComboBox(textGroup);
@@ -93,7 +86,6 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Medium"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Large"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Huge"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Medium"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Large"));
     m_textWidthBox->addItem(i18nc("@item:inlistbox Text width", "Huge"));
-    connect(m_textWidthBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 
     QGridLayout* textGroupLayout = new QGridLayout(textGroup);
     textGroupLayout->addWidget(fontLabel, 0, 0, Qt::AlignRight);
 
     QGridLayout* textGroupLayout = new QGridLayout(textGroup);
     textGroupLayout->addWidget(fontLabel, 0, 0, Qt::AlignRight);
@@ -111,7 +103,6 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
     m_arrangementBox = new KComboBox(gridGroup);
     m_arrangementBox->addItem(i18nc("@item:inlistbox Arrangement", "Columns"));
     m_arrangementBox->addItem(i18nc("@item:inlistbox Arrangement", "Rows"));
     m_arrangementBox = new KComboBox(gridGroup);
     m_arrangementBox->addItem(i18nc("@item:inlistbox Arrangement", "Columns"));
     m_arrangementBox->addItem(i18nc("@item:inlistbox Arrangement", "Rows"));
-    connect(m_arrangementBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 
     QLabel* gridSpacingLabel = new QLabel(i18nc("@label:listbox", "Grid spacing:"), gridGroup);
     m_gridSpacingBox = new KComboBox(gridGroup);
 
     QLabel* gridSpacingLabel = new QLabel(i18nc("@label:listbox", "Grid spacing:"), gridGroup);
     m_gridSpacingBox = new KComboBox(gridGroup);
@@ -119,7 +110,6 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Small"));
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Medium"));
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Large"));
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Small"));
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Medium"));
     m_gridSpacingBox->addItem(i18nc("@item:inlistbox Grid spacing", "Large"));
-    connect(m_gridSpacingBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 
     QGridLayout* gridGroupLayout = new QGridLayout(gridGroup);
     gridGroupLayout->addWidget(arrangementLabel, 0, 0, Qt::AlignRight);
 
     QGridLayout* gridGroupLayout = new QGridLayout(gridGroup);
     gridGroupLayout->addWidget(arrangementLabel, 0, 0, Qt::AlignRight);
@@ -133,6 +123,14 @@ IconsViewSettingsPage::IconsViewSettingsPage(QWidget* parent) :
     new QWidget(this);
 
     loadSettings();
     new QWidget(this);
 
     loadSettings();
+
+    connect(m_iconSizeGroupBox, SIGNAL(defaultSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_iconSizeGroupBox, SIGNAL(previewSizeChanged(int)), this, SIGNAL(changed()));
+    connect(m_fontRequester, SIGNAL(changed()), this, SIGNAL(changed()));
+    connect(m_textlinesCountBox, SIGNAL(valueChanged(int)), this, SIGNAL(changed()));
+    connect(m_textWidthBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
+    connect(m_arrangementBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
+    connect(m_gridSpacingBox, SIGNAL(currentIndexChanged(int)), this, SIGNAL(changed()));
 }
 
 IconsViewSettingsPage::~IconsViewSettingsPage()
 }
 
 IconsViewSettingsPage::~IconsViewSettingsPage()