diff -r 5d37b2f2ae16 -r a9966d51ebf1 src/MainWindow.h --- a/src/MainWindow.h Wed Mar 05 20:49:28 2014 +0200 +++ b/src/MainWindow.h Sun Mar 09 14:58:46 2014 +0200 @@ -191,6 +191,8 @@ //! Gets the shortcut configuration for the given \c action KeySequenceConfig* shortcutForAction (QAction* action); + void endAction(); + public slots: void changeCurrentFile(); void slot_action(); @@ -303,8 +305,6 @@ QTabBar* m_tabs; bool m_updatingTabs; - void endAction(); - private slots: void slot_selectionChanged(); void slot_recentFile(); @@ -325,15 +325,15 @@ //! Asks the user a yes/no question with the given \c message and the given //! window \c title. //! \returns true if the user answered yes, false if no. -bool confirm (QString title, QString message); // Generic confirm prompt +bool confirm (const QString& title, const QString& message); // Generic confirm prompt //! An overload of \c confirm(), this asks the user a yes/no question with the //! given \c message. //! \returns true if the user answered yes, false if no. -bool confirm (QString message); +bool confirm (const QString& message); //! Displays an error prompt with the given \c message -void critical (QString message); +void critical (const QString& message); //! Makes an icon of \c size x \c size pixels to represent \c colinfo QIcon makeColorIcon (LDColor* colinfo, const int size); @@ -351,9 +351,9 @@ //! \returns by the user. //! template -T radioSwitch (const T& defval, QList> haystack) +T radioSwitch (const T& defval, QList> haystack) { - for (pair i : haystack) + for (Pair i : haystack) if (i.first->isChecked()) return i.second; @@ -365,9 +365,9 @@ //! found radio button whose respsective value matches \c expr have the given value. //! template -void radioDefault (const T& expr, QList> haystack) +void radioDefault (const T& expr, QList> haystack) { - for (pair i : haystack) + for (Pair i : haystack) { if (i.second == expr) {