From 30093520a255545a7f6d871cce2c8283c8fdcf12 Mon Sep 17 00:00:00 2001 From: iovar Date: Sat, 1 Dec 2007 11:52:29 +0000 Subject: rmdFrame.py: do not move when hidden rmdSimple.py: hide frame when main window is hidden rmdTrayIcon.py: frame option in exec git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@447 f606c939-3180-4ac9-a4b8-4b8779d57d0a --- gtk-recordmydesktop/src/rmdFrame.py | 4 ++-- gtk-recordmydesktop/src/rmdSimple.py | 4 ++++ gtk-recordmydesktop/src/rmdTrayIcon.py | 2 ++ qt-recordmydesktop/src/rmdFrame.py | 4 ++-- qt-recordmydesktop/src/rmdSimple.py | 4 ++++ qt-recordmydesktop/src/rmdTrayIcon.py | 2 ++ 6 files changed, 16 insertions(+), 4 deletions(-) diff --git a/gtk-recordmydesktop/src/rmdFrame.py b/gtk-recordmydesktop/src/rmdFrame.py index 2dc556f..4441afb 100644 --- a/gtk-recordmydesktop/src/rmdFrame.py +++ b/gtk-recordmydesktop/src/rmdFrame.py @@ -75,10 +75,10 @@ class rmdFrame: self.disp=gtk.gdk.display_get_default() self.wroot = gtk.gdk.get_default_root_window() (self.wwidth, self.wheight) = self.wroot.get_size() - self.timed_id=gobject.timeout_add(10,self.moveFrame) + self.timed_id=gobject.timeout_add(100,self.moveFrame) def moveFrame(self): - if self.parent.values[15]==0: + if self.parent.values[15]==0 and self.parent.hidden[0]==0: npos=gtk.gdk.Display.get_pointer(self.disp) x=npos[1]-self.w/2 y=npos[2]-self.h/2 diff --git a/gtk-recordmydesktop/src/rmdSimple.py b/gtk-recordmydesktop/src/rmdSimple.py index 1bf2c2a..b9693db 100644 --- a/gtk-recordmydesktop/src/rmdSimple.py +++ b/gtk-recordmydesktop/src/rmdSimple.py @@ -168,9 +168,13 @@ class simpleWidget(object): if self.save_prefs()==False: print "Warning!!!Couldn't save preferences" def hide(self,Event=None): + if self.image.realFrame != None and self.values[25]==0: + self.image.realFrame.window.hide() self.window.hide() self.hidden[0]=1 def show(self,Event=None): + if self.image.realFrame != None and self.values[25]==0: + self.image.realFrame.window.show() self.window.show() self.hidden[0]=0 def __swap_visibility__(self,widget=None,event=None): diff --git a/gtk-recordmydesktop/src/rmdTrayIcon.py b/gtk-recordmydesktop/src/rmdTrayIcon.py index f6907f0..b97331e 100644 --- a/gtk-recordmydesktop/src/rmdTrayIcon.py +++ b/gtk-recordmydesktop/src/rmdTrayIcon.py @@ -198,6 +198,8 @@ class trayIcon(object): self.execargs.append('-use-jack') for i in self.parent.values[23]: self.execargs.append(i) + if self.parent.values[25] == 1: + self.execargs.append('--no-frame') if self.parent.values[26] != "": for i in self.parent.values[26].split(" "): if i!="": diff --git a/qt-recordmydesktop/src/rmdFrame.py b/qt-recordmydesktop/src/rmdFrame.py index bb11778..2d574c6 100644 --- a/qt-recordmydesktop/src/rmdFrame.py +++ b/qt-recordmydesktop/src/rmdFrame.py @@ -52,12 +52,12 @@ class rmdFrame: self.timer=QtCore.QTimer(None) self.timer.connect(self.timer,QtCore.SIGNAL("timeout()"), self.moveFrame) - self.timer.start(10) + self.timer.start(100) self.screen_width=QtGui.qApp.desktop().width() self.screen_height=QtGui.qApp.desktop().height() def moveFrame(self): - if self.parent.values[15]==0: + if self.parent.values[15]==0 and self.window.isVisible() : npos=QtGui.QCursor.pos() x=npos.x()-self.w/2 y=npos.y()-self.h/2 diff --git a/qt-recordmydesktop/src/rmdSimple.py b/qt-recordmydesktop/src/rmdSimple.py index e4b3585..c2bd03a 100644 --- a/qt-recordmydesktop/src/rmdSimple.py +++ b/qt-recordmydesktop/src/rmdSimple.py @@ -163,9 +163,13 @@ class simpleWidget(object): print "Warning!!!Couldn't save preferences" sys.exit() def hide(self,Event=None): + if self.image.realFrame != None and self.values[25]==0: + self.image.realFrame.window.hide() self.window.hide() self.hidden[0]=1 def show(self,Event=None): + if self.image.realFrame != None and self.values[25]==0: + self.image.realFrame.window.show() self.window.show() self.hidden[0]=0 def __swap_visibility__(self,event=None): diff --git a/qt-recordmydesktop/src/rmdTrayIcon.py b/qt-recordmydesktop/src/rmdTrayIcon.py index ae9b3cf..2f69e33 100644 --- a/qt-recordmydesktop/src/rmdTrayIcon.py +++ b/qt-recordmydesktop/src/rmdTrayIcon.py @@ -189,6 +189,8 @@ class trayIcon(object): self.execargs.append('-use-jack') for i in self.parent.values[23]: self.execargs.append(i) + if self.parent.values[25] == 1: + self.execargs.append('--no-frame') if self.parent.values[26] != "": for i in self.parent.values[26].split(" "): if i!="": -- cgit v1.2.3