[hamster-applet] allow to properly check for the drag thing



commit f8b3412ab0130a8fa1ce2c02e2181f12f8d0cf1d
Author: Toms Bauģis <toms baugis gmail com>
Date:   Fri Jan 22 15:25:20 2010 +0000

    allow to properly check for the drag thing

 hamster/graphics.py |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/hamster/graphics.py b/hamster/graphics.py
index ff9330b..b2bd0a1 100644
--- a/hamster/graphics.py
+++ b/hamster/graphics.py
@@ -33,7 +33,7 @@ class Colors(object):
 
     def parse(self, color):
         assert color is not None
-        
+
         #parse color into rgb values
         if isinstance(color, str) or isinstance(color, unicode):
             color = gtk.gdk.Color(color)
@@ -49,7 +49,7 @@ class Colors(object):
 
     def rgb(self, color):
         return [c * 255 for c in self.parse(color)]
-        
+
     def is_light(self, color):
         # tells you if color is dark or light, so you can up or down the scale for improved contrast
         return colorsys.rgb_to_hls(*self.rgb(color))[1] > 150
@@ -58,7 +58,7 @@ class Colors(object):
         # returns color darker by step (where step is in range 0..255)
         hls = colorsys.rgb_to_hls(*self.rgb(color))
         return colorsys.hls_to_rgb(hls[0], hls[1] - step, hls[2])
-        
+
 
 class Area(gtk.DrawingArea):
     """Abstraction on top of DrawingArea to work specifically with cairo"""
@@ -97,8 +97,8 @@ class Area(gtk.DrawingArea):
         self.last_frame_time = None
         self.__animating = False
 
-        self.mouse_drag = (None, None)
-        
+        self.mouse_drag = None
+
         self.colors = Colors() # handier this way
 
     def on_expose(self):



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]