summaryrefslogtreecommitdiff
path: root/qt-recordmydesktop/src
diff options
context:
space:
mode:
authoriovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a>2007-12-04 22:20:20 +0000
committeriovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a>2007-12-04 22:20:20 +0000
commit7d077ad3d11417086eb1cf7414d1177bfdd8219a (patch)
treee063843da9f82c4147d015f7eb2ace2b4206e267 /qt-recordmydesktop/src
parentf1a9989a2a735fac913184218e2f9f7443d0aaad (diff)
rmdPrefsWidget.py, rmdSimple.py: added shortcuts for actions
git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@456 f606c939-3180-4ac9-a4b8-4b8779d57d0a
Diffstat (limited to 'qt-recordmydesktop/src')
-rw-r--r--qt-recordmydesktop/src/rmdPrefsWidget.py6
-rw-r--r--qt-recordmydesktop/src/rmdSimple.py25
2 files changed, 30 insertions, 1 deletions
diff --git a/qt-recordmydesktop/src/rmdPrefsWidget.py b/qt-recordmydesktop/src/rmdPrefsWidget.py
index 72f5d91..7ba2786 100644
--- a/qt-recordmydesktop/src/rmdPrefsWidget.py
+++ b/qt-recordmydesktop/src/rmdPrefsWidget.py
@@ -357,7 +357,11 @@ class prefsWidget(object):
self.optionsOpen=optionsOpen
self.window = QtGui.QWidget()
self.window.closeEvent= self.destroy
-
+ esc_sh=QtGui.QShortcut(QtGui.QKeySequence("Esc"),self.window)
+ self.window.connect(esc_sh,
+ QtCore.SIGNAL("activated()"),
+ self.window,
+ QtCore.SLOT("close()"))
self.window.setWindowTitle("recordMyDesktop: "+smplButtonStrings[0])
self.__subWidgets__()
self.__makeCons__()
diff --git a/qt-recordmydesktop/src/rmdSimple.py b/qt-recordmydesktop/src/rmdSimple.py
index c2bd03a..809c609 100644
--- a/qt-recordmydesktop/src/rmdSimple.py
+++ b/qt-recordmydesktop/src/rmdSimple.py
@@ -238,6 +238,30 @@ class simpleWidget(object):
self.start_button.connect(self.start_button,QtCore.SIGNAL("clicked()"),self.trayIcon.record_ext)
self.s_button.connect(self.s_button,QtCore.SIGNAL("clicked()"),self.__sound_check__)
self.win_button.connect(self.win_button,QtCore.SIGNAL("clicked()"),self.__select_window__)
+ def __register_shortcuts__(self):
+ exit_sh=QtGui.QShortcut(QtGui.QKeySequence("Ctrl+q"),self.window)
+ self.window.connect(exit_sh,
+ QtCore.SIGNAL("activated()"),
+ self.window,
+ QtCore.SLOT("close()"))
+ rec_sh=QtGui.QShortcut(QtGui.QKeySequence("Ctrl+r"),self.window)
+ self.window.connect(rec_sh,
+ QtCore.SIGNAL("activated()"),
+ self.trayIcon.record_ext)
+ adv_sh=QtGui.QShortcut(QtGui.QKeySequence("Ctrl+p"),self.window)
+ self.window.connect(adv_sh,
+ QtCore.SIGNAL("activated()"),
+ self.advanced)
+ save_sh=QtGui.QShortcut(QtGui.QKeySequence("Ctrl+s"),self.window)
+ self.window.connect(save_sh,
+ QtCore.SIGNAL("activated()"),
+ self.__fileSelect__)
+ hide_sh=QtGui.QShortcut(QtGui.QKeySequence("Ctrl+h"),self.window)
+ self.window.connect(hide_sh,
+ QtCore.SIGNAL("activated()"),
+ self.trayIcon.tray_popup._prefs_widget)
+
+
def __sound_check__(self,widget=None):
self.s_quality.setEnabled(self.values[2])
@@ -447,6 +471,7 @@ class simpleWidget(object):
self.trayIcon=trayIcon(self)
self.__makeCons__()
+ self.__register_shortcuts__()
if self.values[24]==0:
self.__tooltips__()
© All Rights Reserved