summaryrefslogtreecommitdiffstats
path: root/superkaramba/examples/autoHide
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2022-11-11 17:41:30 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2022-11-13 12:09:49 +0900
commitda9cd0c056c8275033fca84a1c8d49a8edb0c8ee (patch)
tree2521f74c0b2868d82518e13053fb01cc179e9a23 /superkaramba/examples/autoHide
parent5dab6232ef3b3715630cf88eb40c4c6021e65f07 (diff)
downloadtdeutils-da9cd0c056c8275033fca84a1c8d49a8edb0c8ee.tar.gz
tdeutils-da9cd0c056c8275033fca84a1c8d49a8edb0c8ee.zip
superkaramba: convert examples to python3.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'superkaramba/examples/autoHide')
-rw-r--r--superkaramba/examples/autoHide/main.py22
1 files changed, 4 insertions, 18 deletions
diff --git a/superkaramba/examples/autoHide/main.py b/superkaramba/examples/autoHide/main.py
index 85e2b37..0dce2e0 100644
--- a/superkaramba/examples/autoHide/main.py
+++ b/superkaramba/examples/autoHide/main.py
@@ -18,7 +18,6 @@ def widgetUpdated(widget):
hidden = 1
karamba.moveWidget(widget, 0, -210)
-
#This gets called everytime our widget is clicked.
#Notes:
# widget = reference to our widget
@@ -33,21 +32,10 @@ def widgetUpdated(widget):
def widgetClicked(widget, x, y, button):
pass
-#This gets called everytime our widget is clicked.
-#Notes
-# widget = reference to our widget
-# x = x position (relative to our widget)
-# y = y position (relative to our widget)
-# botton = button being held:
-# 0 = No Mouse Button
-# 1 = Left Mouse Button
-# 2 = Middle Mouse Button
-# 3 = Right Mouse Button, but this will never happen
-# because the right mouse button brings up the
-# Karamba menu.
+#This gets called everytime the mouse moves on the widget area
+#Warning: Don't do anything too intensive here
+#You don't want to run some complex piece of code everytime the mouse moves
def widgetMouseMoved(widget, x, y, button):
- #Warning: Don't do anything too intensive here
- #You don't want to run some complex piece of code everytime the mouse moves
global hidden
global counter
if (hidden==1):
@@ -55,8 +43,6 @@ def widgetMouseMoved(widget, x, y, button):
hidden = 0
counter = 0
-
-
# This will be printed when the widget loads.
-print "Loaded my python extension!"
+print("Loaded my python extension!")