00001 /*************************************************************************** 00002 shortcutdlg.h - dialog for setting a shortcut 00003 ------------------- 00004 begin : Fre, 11 Apr 2003 00005 copyright : (C) 2003 by Heiko Köhler 00006 email : heicom@users.sourceforge.net 00007 ***************************************************************************/ 00008 00009 /*************************************************************************** 00010 * * 00011 * This program is free software; you can redistribute it and/or modify * 00012 * it under the terms of the GNU General Public License as published by * 00013 * the Free Software Foundation; either version 2 of the License, or * 00014 * (at your option) any later version. * 00015 * * 00016 ***************************************************************************/ 00017 00018 #include <qkeysequence.h> 00019 00020 #include "ui/shortcutdialog.h" 00021 00023 class ShortcutDlg : public ShortcutDialog 00024 { 00025 Q_OBJECT 00026 public: 00027 ShortcutDlg(QWidget *parent=0, const char *name=0); 00029 void setKey(QKeySequence key); 00030 protected slots: 00032 void clearPressed(); 00034 void okPressed(); 00036 void keyPressEvent(QKeyEvent *e); 00037 signals: 00039 void shortcutChanged(QKeySequence key); 00040 private: 00041 int keys[4]; 00042 int keyIndex; 00043 };