summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <montel@kde.org>2014-10-01 12:02:01 (GMT)
committerMontel Laurent <montel@kde.org>2014-10-01 12:02:01 (GMT)
commitd386ea257eb1a22b900b9e8ed4b5f14ac408b9b0 (patch)
treea0bc1980a8076b227b0a288c91ca2376ce3c4292
parentaee3d941616043b0eba1f9d1115e01e864b0335b (diff)
Port to new connect api
-rw-r--r--conf/dlgaccessibility.cpp2
-rw-r--r--conf/dlgeditor.cpp2
-rw-r--r--conf/dlgperformance.cpp2
-rw-r--r--conf/dlgpresentation.cpp2
-rw-r--r--core/document.cpp4
-rw-r--r--core/generator.cpp6
-rw-r--r--core/generator_p.cpp2
7 files changed, 9 insertions, 11 deletions
diff --git a/conf/dlgaccessibility.cpp b/conf/dlgaccessibility.cpp
index cabda5c..bc9b593 100644
--- a/conf/dlgaccessibility.cpp
+++ b/conf/dlgaccessibility.cpp
@@ -28,7 +28,7 @@ DlgAccessibility::DlgAccessibility( QWidget * parent )
page->hide();
m_color_pages[ m_selected ]->show();
- connect( m_dlg->kcfg_RenderMode, SIGNAL(currentIndexChanged(int)), this, SLOT(slotColorMode(int)) );
+ connect(m_dlg->kcfg_RenderMode, static_cast<void (KComboBox::*)(int)>(&KComboBox::currentIndexChanged), this, &DlgAccessibility::slotColorMode);
}
DlgAccessibility::~DlgAccessibility()
diff --git a/conf/dlgeditor.cpp b/conf/dlgeditor.cpp
index 84f1cdd..18e9c26 100644
--- a/conf/dlgeditor.cpp
+++ b/conf/dlgeditor.cpp
@@ -23,7 +23,7 @@ DlgEditor::DlgEditor( QWidget * parent )
m_editors = Okular::buildEditorsMap();
- connect( m_dlg->kcfg_ExternalEditor, SIGNAL(currentIndexChanged(int)), this, SLOT(editorChanged(int)) );
+ connect(m_dlg->kcfg_ExternalEditor, static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this, &DlgEditor::editorChanged);
m_dlg->kcfg_ExternalEditor->addItem( i18nc( "Text editor", "Custom Text Editor" ) );
m_dlg->kcfg_ExternalEditor->addItem( i18nc( "Text editor", "Kate" ), 1 );
diff --git a/conf/dlgperformance.cpp b/conf/dlgperformance.cpp
index c35b0e9..9fa752e 100644
--- a/conf/dlgperformance.cpp
+++ b/conf/dlgperformance.cpp
@@ -27,7 +27,7 @@ DlgPerformance::DlgPerformance( QWidget * parent )
m_dlg->cpuLabel->setPixmap( BarIcon( "cpu", 32 ) );
// m_dlg->memoryLabel->setPixmap( BarIcon( "kcmmemory", 32 ) ); // TODO: enable again when proper icon is available
- connect( m_dlg->kcfg_MemoryLevel, SIGNAL(changed(int)), this, SLOT(radioGroup_changed(int)) );
+ connect(m_dlg->kcfg_MemoryLevel, &KButtonGroup::changed, this, &DlgPerformance::radioGroup_changed);
}
DlgPerformance::~DlgPerformance()
diff --git a/conf/dlgpresentation.cpp b/conf/dlgpresentation.cpp
index 67aa8c5..4e77084 100644
--- a/conf/dlgpresentation.cpp
+++ b/conf/dlgpresentation.cpp
@@ -47,7 +47,7 @@ DlgPresentation::DlgPresentation( QWidget * parent )
m_dlg->kcfg_SlidesAdvanceTime->setSuffix(ki18ncp("Advance every %1 seconds", " second", " seconds"));
- connect( m_dlg->screenCombo, SIGNAL(activated(int)), this, SLOT(screenComboChanged(int)) );
+ connect(m_dlg->screenCombo, static_cast<void (QComboBox::*)(int)>(&QComboBox::activated), this, &DlgPresentation::screenComboChanged);
}
DlgPresentation::~DlgPresentation()
diff --git a/core/document.cpp b/core/document.cpp
index 028b108..e7b70cd 100644
--- a/core/document.cpp
+++ b/core/document.cpp
@@ -2069,8 +2069,8 @@ Document::Document( QWidget *widget )
d->m_undoStack = new QUndoStack(this);
connect( SettingsCore::self(), SIGNAL(configChanged()), this, SLOT(_o_configChanged()) );
- connect( d->m_undoStack, SIGNAL( canUndoChanged(bool) ), this, SIGNAL( canUndoChanged(bool)));
- connect( d->m_undoStack, SIGNAL( canRedoChanged(bool) ), this, SIGNAL( canRedoChanged(bool) ) );
+ connect(d->m_undoStack, &QUndoStack::canUndoChanged, this, &Document::canUndoChanged);
+ connect(d->m_undoStack, &QUndoStack::canRedoChanged, this, &Document::canRedoChanged);
qRegisterMetaType<Okular::FontInfo>();
}
diff --git a/core/generator.cpp b/core/generator.cpp
index 6b0beec..76e6794 100644
--- a/core/generator.cpp
+++ b/core/generator.cpp
@@ -61,8 +61,7 @@ PixmapGenerationThread* GeneratorPrivate::pixmapGenerationThread()
Q_Q( Generator );
mPixmapGenerationThread = new PixmapGenerationThread( q );
- QObject::connect( mPixmapGenerationThread, SIGNAL(finished()),
- q, SLOT(pixmapGenerationFinished()),
+ QObject::connect( mPixmapGenerationThread, SIGNAL(finished()), q, SLOT(pixmapGenerationFinished()),
Qt::QueuedConnection );
return mPixmapGenerationThread;
@@ -75,8 +74,7 @@ TextPageGenerationThread* GeneratorPrivate::textPageGenerationThread()
Q_Q( Generator );
mTextPageGenerationThread = new TextPageGenerationThread( q );
- QObject::connect( mTextPageGenerationThread, SIGNAL(finished()),
- q, SLOT(textpageGenerationFinished()),
+ QObject::connect( mTextPageGenerationThread, SIGNAL(finished()), q, SLOT(textpageGenerationFinished()),
Qt::QueuedConnection );
return mTextPageGenerationThread;
diff --git a/core/generator_p.cpp b/core/generator_p.cpp
index e31fca5..4cfbf78 100644
--- a/core/generator_p.cpp
+++ b/core/generator_p.cpp
@@ -113,7 +113,7 @@ void FontExtractionThread::startExtraction( bool async )
{
if ( async )
{
- connect( this, SIGNAL(finished()), this, SLOT(deleteLater()) );
+ connect(this, &FontExtractionThread::finished, this, &FontExtractionThread::deleteLater);
start( QThread::InheritPriority );
}
else