From ed92917ebb56bf1cff945ad1a34c2d7fcdbeb4ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Thu, 29 Oct 2009 17:03:12 +0000 Subject: [PATCH] Fix the crash when clicking twice on configure layout in kcmtabbox. BUG: 208301 svn path=/trunk/KDE/kdebase/workspace/; revision=1042347 --- kcmkwin/kwintabbox/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kcmkwin/kwintabbox/main.cpp b/kcmkwin/kwintabbox/main.cpp index 3845abd65b..a83d67e686 100644 --- a/kcmkwin/kwintabbox/main.cpp +++ b/kcmkwin/kwintabbox/main.cpp @@ -70,8 +70,6 @@ KWinTabBoxConfig::KWinTabBoxConfig( QWidget* parent, const QVariantList& args ) layout->addWidget( infoLabel ); layout->addWidget( tabWidget ); - m_configForm = new TabBox::LayoutConfig(); - m_editor = new KShortcutsEditor( m_primaryTabBoxUi, KShortcutsEditor::GlobalAction ); // Shortcut config. The shortcut belongs to the component "kwin"! m_actionCollection = new KActionCollection( this, KComponentData("kwin") ); @@ -590,6 +588,7 @@ void KWinTabBoxConfig::slotConfigureLayoutClicked() dialog->setButtons( KDialog::Ok | KDialog::Cancel | KDialog::Default ); connect( dialog, SIGNAL(okClicked()), this, SLOT(slotLayoutChanged())); + m_configForm = new TabBox::LayoutConfig( dialog ); m_configForm->setConfig( m_tabBoxConfig ); dialog->setMainWidget( m_configForm ); @@ -610,6 +609,7 @@ void KWinTabBoxConfig::slotConfigureLayoutClickedAlternative() dialog->setButtons( KDialog::Ok | KDialog::Cancel | KDialog::Default ); connect( dialog, SIGNAL(okClicked()), this, SLOT(slotLayoutChangedAlternative())); + m_configForm = new TabBox::LayoutConfig( dialog ); m_configForm->setConfig( m_tabBoxAlternativeConfig ); dialog->setMainWidget( m_configForm );