/***************************************************************************
- * Copyright (C) 2010 by the Quassel Project *
+ * Copyright (C) 2005-2018 by the Quassel Project *
* devel@quassel-irc.org *
* *
* This class has been inspired by KDE's KKeySequenceWidget and uses *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
- * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
#include <QApplication>
#include <QToolButton>
// This defines the unicode symbols for special keys (kCommandUnicode and friends)
-#ifdef Q_WS_MAC
+#ifdef Q_OS_MAC
# include <Carbon/Carbon.h>
#endif
#include "action.h"
#include "actioncollection.h"
-#include "iconloader.h"
+#include "icon.h"
#include "keysequencewidget.h"
KeySequenceButton::KeySequenceButton(KeySequenceWidget *d_, QWidget *parent)
_keyButton = new KeySequenceButton(this, this);
_keyButton->setFocusPolicy(Qt::StrongFocus);
- _keyButton->setIcon(SmallIcon("configure"));
+ _keyButton->setIcon(icon::get("configure"));
_keyButton->setToolTip(tr("Click on the button, then enter the shortcut like you would in the program.\nExample for Ctrl+a: hold the Ctrl key and press a."));
layout->addWidget(_keyButton);
layout->addWidget(_clearButton);
if (qApp->isLeftToRight())
- _clearButton->setIcon(SmallIcon("edit-clear-locationbar-rtl"));
+ _clearButton->setIcon(icon::get("edit-clear-locationbar-rtl"));
else
- _clearButton->setIcon(SmallIcon("edit-clear-locationbar-ltr"));
+ _clearButton->setIcon(icon::get("edit-clear-locationbar-ltr"));
setLayout(layout);
if (_isRecording) {
if (_modifierKeys) {
-#ifdef Q_WS_MAC
+#ifdef Q_OS_MAC
if (_modifierKeys & Qt::META) s += QChar(kControlUnicode);
if (_modifierKeys & Qt::ALT) s += QChar(kOptionUnicode);
if (_modifierKeys & Qt::SHIFT) s += QChar(kShiftUnicode);