Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/Jam/Parasite.py
diff options
context:
space:
mode:
authorGonzalo Odiard <godiard@gmail.com>2013-01-22 15:46:25 (GMT)
committer Gonzalo Odiard <godiard@gmail.com>2013-01-22 15:48:57 (GMT)
commit4e0210968c6fb8862b6c808f783536899ade1644 (patch)
treeec8a2e6444fe5cf8396590b58832b47753460710 /Jam/Parasite.py
parent2ced9950cd6511ef1ce36673df332e11d570c1d6 (diff)
Start port of TamTamJam to Gtk3
Using pygi-convert.sh, sugar-convert.sh and a few manual fixes. Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
Diffstat (limited to 'Jam/Parasite.py')
-rw-r--r--Jam/Parasite.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/Jam/Parasite.py b/Jam/Parasite.py
index 74b9e0d..c5ac2ec 100644
--- a/Jam/Parasite.py
+++ b/Jam/Parasite.py
@@ -1,6 +1,5 @@
-import pygtk
-pygtk.require( '2.0' )
-import gtk
+from gi.repository import Gtk
+from gi.repository import Gdk
import common.Config as Config
@@ -170,7 +169,7 @@ class LoopParasite:
playSample = False
- if event.type == gtk.gdk._2BUTTON_PRESS: # select bar
+ if event.type == Gdk._2BUTTON_PRESS: # select bar
self.potentialDeselect = False
start = 0
check = self.note.cs.onset - Config.TICKS_PER_BEAT
@@ -179,7 +178,7 @@ class LoopParasite:
check += self.note.cs.duration
while stop < check: stop += Config.TICKS_PER_BEAT
emitter.selectNotesByBar( self.note.track, start, stop )
- elif event.type == gtk.gdk._3BUTTON_PRESS: # select track
+ elif event.type == Gdk._3BUTTON_PRESS: # select track
self.potentialDeselect = False
emitter.selectNotesByTrack( self.note.track )
else: