[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kwordquiz] src: More Krazy fixes.
From:       Peter Hedlund <peter () peterandlinda ! com>
Date:       2013-03-10 22:27:40
Message-ID: 20130310222740.E4FC4A604F () git ! kde ! org
[Download RAW message or body]

Git commit 144541fd2de8dd3c53e7ad24cd12066764c5408f by Peter Hedlund.
Committed on 10/03/2013 at 23:27.
Pushed by hedlund into branch 'master'.

More Krazy fixes.

M  +12   -12   src/kwordquiz.cpp
M  +1    -1    src/kwqcleardialog.cpp
M  +1    -1    src/kwqquizmodel.h
M  +4    -4    src/kwqtableview.cpp
M  +1    -1    src/kwqtutor.cpp
M  +2    -2    src/multipleview.cpp
M  +8    -8    src/prefcardappearance.cpp

http://commits.kde.org/kwordquiz/144541fd2de8dd3c53e7ad24cd12066764c5408f

diff --git a/src/kwordquiz.cpp b/src/kwordquiz.cpp
index 85cd436..2c263a0 100644
--- a/src/kwordquiz.cpp
+++ b/src/kwordquiz.cpp
@@ -123,7 +123,7 @@ void KWordQuizApp::initActions()
   fileOpen->setToolTip(fileOpen->whatsThis());
   fileOpen->setStatusTip(fileOpen->whatsThis());
 
-  fileOpenRecent = KStandardAction::openRecent(this, SLOT(slotFileOpenRecent(const \
KUrl&)), actionCollection()); +  fileOpenRecent = KStandardAction::openRecent(this, \
SLOT(slotFileOpenRecent(KUrl)), actionCollection());  
   fileGHNS = KNS3::standardAction(i18n("Download New Vocabularies..."), this, \
SLOT(slotFileGHNS()), actionCollection(), "file_ghns");  \
fileGHNS->setShortcut(QKeySequence(Qt::CTRL + Qt::Key_G)); @@ -164,8 +164,8 @@ void \
KWordQuizApp::initActions()  editUndo = \
m_undoStack->createUndoAction(actionCollection());  editRedo = \
m_undoStack->createRedoAction(actionCollection());  connect(m_undoStack, \
                SIGNAL(cleanChanged(bool)), this, SLOT(slotCleanChanged(bool)));
-  connect(m_undoStack, SIGNAL(undoTextChanged(const QString &)), this, \
                SLOT(slotUndoTextChanged(const QString &)));
-  connect(m_undoStack, SIGNAL(redoTextChanged(const QString &)), this, \
SLOT(slotRedoTextChanged(const QString &))); +  connect(m_undoStack, \
SIGNAL(undoTextChanged(QString)), this, SLOT(slotUndoTextChanged(QString))); +  \
connect(m_undoStack, SIGNAL(redoTextChanged(QString)), this, \
SLOT(slotRedoTextChanged(QString)));  
   editCut = KStandardAction::cut(this, SLOT(slotEditCut()), actionCollection());
   editCut->setWhatsThis(i18n("Cuts the text from the selected cells and places it on \
the clipboard")); @@ -281,7 +281,7 @@ void KWordQuizApp::initActions()
   vocabLayouts->setMenu(m);
   
   m_layoutActionGroup = new QActionGroup(this);
-  connect(m_layoutActionGroup, SIGNAL(triggered(QAction *)), this, \
SLOT(slotLayoutActionGroupTriggered(QAction *))); +  connect(m_layoutActionGroup, \
SIGNAL(triggered(QAction*)), this, SLOT(slotLayoutActionGroupTriggered(QAction*)));  
   m_modeActionMenu = actionCollection()->add<KActionMenu>("mode_0");
   m_modeActionMenu->setIcon(KIcon("mode1"));
@@ -293,7 +293,7 @@ void KWordQuizApp::initActions()
   connect(m_modeActionMenu, SIGNAL(triggered(bool)), this, SLOT(slotModeChange()));
 
   m_modeActionGroup = new QActionGroup(this);
-  connect(m_modeActionGroup, SIGNAL(triggered(QAction *)), this, \
SLOT(slotModeActionGroupTriggered(QAction *))); +  connect(m_modeActionGroup, \
SIGNAL(triggered(QAction*)), this, SLOT(slotModeActionGroupTriggered(QAction*)));  
   for (int i = 1; i <=5; ++i) {
     a = actionCollection()->addAction(QString("mode_%1").arg(QString::number(i)));
@@ -440,7 +440,7 @@ void KWordQuizApp::initActions()
   configNotifications->setToolTip(configNotifications->whatsThis());
   configNotifications->setStatusTip(configNotifications->whatsThis());
 
-  configApp = KStandardAction::preferences(this, SLOT( slotConfigure()), \
actionCollection()); +  configApp = KStandardAction::preferences(this, \
SLOT(slotConfigure()), actionCollection());  configApp->setWhatsThis(i18n("Specifies \
preferences for the vocabulary editor and quiz sessions"));  \
configApp->setToolTip(configApp->whatsThis());  \
configApp->setToolTip(configApp->whatsThis()); @@ -508,7 +508,7 @@ void \
KWordQuizApp::initView()  m_pageWidget = new KPageWidget(this);
   m_pageWidget->setFaceType( KPageView::List );
   setCentralWidget(m_pageWidget);
-  connect(m_pageWidget, SIGNAL(currentPageChanged(KPageWidgetItem *, KPageWidgetItem \
*)), this, SLOT(slotCurrentPageChanged(KPageWidgetItem *, KPageWidgetItem *))); +  \
connect(m_pageWidget, SIGNAL(currentPageChanged(KPageWidgetItem*, KPageWidgetItem*)), \
this, SLOT(slotCurrentPageChanged(KPageWidgetItem*, KPageWidgetItem*)));  
   QVBoxLayout *editorLayout = new QVBoxLayout();
   editorLayout->setMargin(0);
@@ -527,7 +527,7 @@ void KWordQuizApp::initView()
   m_tableView->setColumnWidth(1, qvariant_cast<QSize>(m_tableModel->headerData(1, \
Qt::Horizontal, Qt::SizeHintRole)).width());  \
setCaption(m_doc->url().fileName(),false);  \
                m_tableView->setContextMenuPolicy(Qt::CustomContextMenu);
-  connect(m_tableView, SIGNAL(customContextMenuRequested(const QPoint &)), this, \
SLOT(slotTableContextMenuRequested(const QPoint &))); +  connect(m_tableView, \
SIGNAL(customContextMenuRequested(QPoint)), this, \
SLOT(slotTableContextMenuRequested(QPoint)));  connect(m_tableModel, \
SIGNAL(modelReset()), m_tableView, SLOT(slotModelReset()));  
   m_searchLine->setVisible(Prefs::showSearch());
@@ -1174,7 +1174,7 @@ void KWordQuizApp::slotCurrentPageChanged(KPageWidgetItem \
*current, KPageWidgetI  }
     m_quiz = new KWQQuizModel(this);
     m_quiz->setSourceModel(m_sortFilterModel);
-    connect(m_quiz, SIGNAL(checkingAnswer(int )), m_tableView, \
SLOT(slotCheckedAnswer(int ))); +    connect(m_quiz, SIGNAL(checkingAnswer(int)), \
m_tableView, SLOT(slotCheckedAnswer(int)));  \
m_quiz->setQuizType(Prefs::EnumStartSession::Flashcard);  \
m_quiz->setQuizMode(Prefs::mode());  if (m_quiz->init())
@@ -1206,7 +1206,7 @@ void KWordQuizApp::slotCurrentPageChanged(KPageWidgetItem \
*current, KPageWidgetI  }
     m_quiz = new KWQQuizModel(this);
     m_quiz->setSourceModel(m_sortFilterModel);
-    connect(m_quiz, SIGNAL(checkingAnswer(int )), m_tableView, \
SLOT(slotCheckedAnswer(int ))); +    connect(m_quiz, SIGNAL(checkingAnswer(int)), \
m_tableView, SLOT(slotCheckedAnswer(int)));  \
m_quiz->setQuizType(Prefs::EnumStartSession::MultipleChoice);  \
m_quiz->setQuizMode(Prefs::mode());  if (m_quiz->init())
@@ -1235,7 +1235,7 @@ void KWordQuizApp::slotCurrentPageChanged(KPageWidgetItem \
*current, KPageWidgetI  }
     m_quiz = new KWQQuizModel(this);
     m_quiz->setSourceModel(m_sortFilterModel);
-    connect(m_quiz, SIGNAL(checkingAnswer(int )), m_tableView, \
SLOT(slotCheckedAnswer(int ))); +    connect(m_quiz, SIGNAL(checkingAnswer(int)), \
m_tableView, SLOT(slotCheckedAnswer(int)));  \
m_quiz->setQuizType(Prefs::EnumStartSession::QA);  \
m_quiz->setQuizMode(Prefs::mode());  if (m_quiz->init())
@@ -1277,7 +1277,7 @@ void KWordQuizApp::slotConfigure()
 
   //KConfigDialog didn't find an instance of this dialog, so lets create it :
   KWordQuizPrefs* dialog = new KWordQuizPrefs(this, "settings",  Prefs::self(), \
                actionCollection());
-  connect(dialog, SIGNAL(settingsChanged(const QString &)), this, \
SLOT(slotApplyPreferences())); +  connect(dialog, SIGNAL(settingsChanged(QString)), \
this, SLOT(slotApplyPreferences()));  dialog->show();
 }
 
diff --git a/src/kwqcleardialog.cpp b/src/kwqcleardialog.cpp
index e7e2c7e..573f0f4 100644
--- a/src/kwqcleardialog.cpp
+++ b/src/kwqcleardialog.cpp
@@ -28,7 +28,7 @@ KWQClearDialog::KWQClearDialog(QWidget* parent): KDialog(parent)
     setButtons(Ok|Cancel);
     setupUi(mainWidget());
 
-    connect(clearButtonGroup, SIGNAL(changed(int )), this, \
SLOT(buttonGroupChanged(int))); +    connect(clearButtonGroup, SIGNAL(changed(int)), \
this, SLOT(buttonGroupChanged(int)));  
     updateCheckBoxes();
 }
diff --git a/src/kwqquizmodel.h b/src/kwqquizmodel.h
index 061360c..1a8460f 100644
--- a/src/kwqquizmodel.h
+++ b/src/kwqquizmodel.h
@@ -35,7 +35,7 @@ class KWQQuizModel : public QSortFilterProxyModel
 public:
     enum QuizIcon {IconLeftCol, IconRightCol, IconQuestion, IconCorrect, IconError};
 
-    KWQQuizModel(QObject *parent);
+    explicit KWQQuizModel(QObject *parent);
 
     void setSourceModel(KWQSortFilterModel * sourceModel);
     KWQSortFilterModel * sourceModel() const;
diff --git a/src/kwqtableview.cpp b/src/kwqtableview.cpp
index 26e9ea5..9d9f067 100644
--- a/src/kwqtableview.cpp
+++ b/src/kwqtableview.cpp
@@ -59,7 +59,7 @@ KWQTableView::KWQTableView(KUndoStack *undoStack, QWidget *parent) \
: QTableView(  setSelectionBehavior(QAbstractItemView::SelectItems);
   setEditTriggers(QAbstractItemView::AnyKeyPressed | \
QAbstractItemView::EditKeyPressed | QAbstractItemView::DoubleClicked);  \
                setTabKeyNavigation(true);
-  connect(horizontalHeader(), SIGNAL(sectionResized(int, int, int)), this, \
SLOT(horizontalHeaderResized(int, int, int))); +  connect(horizontalHeader(), \
SIGNAL(sectionResized(int,int,int)), this, \
SLOT(horizontalHeaderResized(int,int,int)));  connect(horizontalHeader(), \
SIGNAL(sectionClicked(int)), this, SLOT(slotHeaderClicked(int)));  m_delegate = new \
KWQTableDelegate(this);  setItemDelegate(m_delegate);
@@ -627,9 +627,9 @@ void KWQTableView::setModel(KWQSortFilterModel * model)
   m_model = model;
   setCurrentIndex(model->index(0, 0));
   scrollTo(currentIndex());
-  connect(verticalHeader(), SIGNAL(sectionResized(int, int, int)), this, \
                SLOT(verticalHeaderResized(int, int, int)));
-  connect(horizontalHeader(), SIGNAL(sectionResized(int, int, int)), this, \
                SLOT(horizontalHeaderResized(int, int, int)));
-  connect(m_model, SIGNAL(headerDataChanged(Qt::Orientation, int, int)), this, \
SLOT(horizontalHeaderDataChanged(Qt::Orientation, int, int))); +  \
connect(verticalHeader(), SIGNAL(sectionResized(int,int,int)), this, \
SLOT(verticalHeaderResized(int,int,int))); +  connect(horizontalHeader(), \
SIGNAL(sectionResized(int,int,int)), this, \
SLOT(horizontalHeaderResized(int,int,int))); +  connect(m_model, \
SIGNAL(headerDataChanged(Qt::Orientation,int,int)), this, \
SLOT(horizontalHeaderDataChanged(Qt::Orientation,int,int)));  }
 
 void KWQTableView::closeEditor(QWidget * editor, QAbstractItemDelegate::EndEditHint \
                hint)
diff --git a/src/kwqtutor.cpp b/src/kwqtutor.cpp
index 8fa5aea..2e91b19 100644
--- a/src/kwqtutor.cpp
+++ b/src/kwqtutor.cpp
@@ -157,7 +157,7 @@ void KWQTutor::showPrefMenu()
 
   //KConfigDialog didn't find an instance of this dialog, so lets create it :
   KWQTutorPrefs* dialog = new KWQTutorPrefs(0, "settings",  Prefs::self(), \
                m_globalCollection);
-  connect(dialog, SIGNAL(settingsChanged(const QString &)), this, \
SLOT(slotApplyPreferences())); +  connect(dialog, SIGNAL(settingsChanged(QString)), \
this, SLOT(slotApplyPreferences()));  dialog->show();
 }
 
diff --git a/src/multipleview.cpp b/src/multipleview.cpp
index 5c96911..ecde93b 100644
--- a/src/multipleview.cpp
+++ b/src/multipleview.cpp
@@ -38,9 +38,9 @@ MultipleView::MultipleView(QWidget *parent, KActionCollection \
*actionCollection)  m_choicesButtons->addButton(opt1, 1);
   m_choicesButtons->addButton(opt2, 2);
   m_choicesButtons->addButton(opt3, 3);
-  connect(m_choicesButtons, SIGNAL(buttonClicked(int )), this, \
SLOT(slotChoiceClicked(int ))); +  connect(m_choicesButtons, \
SIGNAL(buttonClicked(int)), this, SLOT(slotChoiceClicked(int)));  m_choicesActions = \
                new QActionGroup(this);
-  connect(m_choicesActions, SIGNAL(triggered(QAction *)), this, \
SLOT(slotChoiceActionTriggered(QAction *))); +  connect(m_choicesActions, \
SIGNAL(triggered(QAction*)), this, SLOT(slotChoiceActionTriggered(QAction*)));  \
m_choicesActions->addAction(m_actionCollection->action("quiz_Opt1"));  \
m_choicesActions->addAction(m_actionCollection->action("quiz_Opt2"));  \
                m_choicesActions->addAction(m_actionCollection->action("quiz_Opt3"));
diff --git a/src/prefcardappearance.cpp b/src/prefcardappearance.cpp
index fefea84..8f814fc 100644
--- a/src/prefcardappearance.cpp
+++ b/src/prefcardappearance.cpp
@@ -26,14 +26,14 @@ PrefCardAppearance::PrefCardAppearance(QWidget *parent) : \
QWidget(parent)  setupUi(this);
 
   connect(flipButton, SIGNAL(clicked()), this, SLOT(slotFlipButtonClicked()));
-  connect(kcfg_FrontFont, SIGNAL(fontSelected(const QFont&)), this, \
                SLOT(slotFontChanged(const QFont&)));
-  connect(kcfg_FrontTextColor, SIGNAL(changed(const QColor&)), this, \
                SLOT(slotTextColorChanged(const QColor&)));
-  connect(kcfg_FrontCardColor, SIGNAL(changed(const QColor&)), this, \
                SLOT(slotCardColorChanged(const QColor&)));
-  connect(kcfg_FrontFrameColor, SIGNAL(changed(const QColor&)), this, \
                SLOT(slotFrameColorChanged(const QColor&)));
-  connect(kcfg_BackFont, SIGNAL(fontSelected(const QFont&)), this, \
                SLOT(slotFontChanged(const QFont&)));
-  connect(kcfg_BackTextColor, SIGNAL(changed(const QColor&)), this, \
                SLOT(slotTextColorChanged(const QColor&)));
-  connect(kcfg_BackCardColor, SIGNAL(changed(const QColor&)), this, \
                SLOT(slotCardColorChanged(const QColor&)));
-  connect(kcfg_BackFrameColor, SIGNAL(changed(const QColor&)), this, \
SLOT(slotFrameColorChanged(const QColor&))); +  connect(kcfg_FrontFont, \
SIGNAL(fontSelected(QFont)), this, SLOT(slotFontChanged(QFont&))); +  \
connect(kcfg_FrontTextColor, SIGNAL(changed(QColor)), this, \
SLOT(slotTextColorChanged(QColor))); +  connect(kcfg_FrontCardColor, \
SIGNAL(changed(QColor)), this, SLOT(slotCardColorChanged(QColor))); +  \
connect(kcfg_FrontFrameColor, SIGNAL(changed(QColor)), this, \
SLOT(slotFrameColorChanged(QColor))); +  connect(kcfg_BackFont, \
SIGNAL(fontSelected(QFont)), this, SLOT(slotFontChanged(QFont))); +  \
connect(kcfg_BackTextColor, SIGNAL(changed(QColor)), this, \
SLOT(slotTextColorChanged(QColor))); +  connect(kcfg_BackCardColor, \
SIGNAL(changed(QColor)), this, SLOT(slotCardColorChanged(QColor))); +  \
connect(kcfg_BackFrameColor, SIGNAL(changed(QColor)), this, \
SLOT(slotFrameColorChanged(QColor)));  connect(widgetStack, \
SIGNAL(currentChanged(int)), this, SLOT(slotCurrentChanged(int)));  
   widgetStack->setCurrentWidget(frontStackPage);


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic