Compare commits
14 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
4c2de8d78b | ||
|
96f4e2c784 | ||
|
5c3df9252d | ||
|
71f3bf9765 | ||
|
327011aae8 | ||
|
5bc55925ef | ||
|
ff2f169ed3 | ||
|
5f9ba4655d | ||
|
d977c73223 | ||
|
c2275c4f4f | ||
|
1b8e8b05fc | ||
|
7df225c81f | ||
|
10da188af6 | ||
|
6a81d20019 |
6
debian/changelog
vendored
6
debian/changelog
vendored
@ -1,3 +1,9 @@
|
|||||||
|
mintmenu (5.5.3.1) maya; urgency=medium
|
||||||
|
|
||||||
|
* Backported version of 5.5.6 for Maya and Petra
|
||||||
|
|
||||||
|
-- Clement Lefebvre <root@linuxmint.com> Thu, 22 May 2014 11:05:45 +0100
|
||||||
|
|
||||||
mintmenu (5.5.3) qiana; urgency=medium
|
mintmenu (5.5.3) qiana; urgency=medium
|
||||||
|
|
||||||
* 5.5.3
|
* 5.5.3
|
||||||
|
@ -58,7 +58,7 @@ class mintMenuConfig( object ):
|
|||||||
self.builder.get_object("swapGeneric").set_label(_("Swap name and generic name"))
|
self.builder.get_object("swapGeneric").set_label(_("Swap name and generic name"))
|
||||||
|
|
||||||
self.builder.get_object("label11").set_text(_("Border width:"))
|
self.builder.get_object("label11").set_text(_("Border width:"))
|
||||||
self.builder.get_object("label2").set_text(_("pixels"))
|
self.builder.get_object("label25").set_text(_("pixels"))
|
||||||
|
|
||||||
self.builder.get_object("label8").set_text(_("Opacity:"))
|
self.builder.get_object("label8").set_text(_("Opacity:"))
|
||||||
self.builder.get_object("label9").set_text("%")
|
self.builder.get_object("label9").set_text("%")
|
||||||
|
@ -561,14 +561,14 @@ class pluginclass( object ):
|
|||||||
def onHideMenu( self ):
|
def onHideMenu( self ):
|
||||||
self.settings.set( "int", "last-active-tab", self.lastActiveTab )
|
self.settings.set( "int", "last-active-tab", self.lastActiveTab )
|
||||||
|
|
||||||
def changeTab( self, tabNum ):
|
def changeTab( self, tabNum, clear = True ):
|
||||||
notebook = self.builder.get_object( "notebook2" )
|
notebook = self.builder.get_object( "notebook2" )
|
||||||
if tabNum == 0:
|
if tabNum == 0:
|
||||||
notebook.set_current_page( 0 )
|
notebook.set_current_page( 0 )
|
||||||
elif tabNum == 1:
|
elif tabNum == 1:
|
||||||
notebook.set_current_page( 1 )
|
notebook.set_current_page( 1 )
|
||||||
|
|
||||||
self.focusSearchEntry()
|
self.focusSearchEntry(clear)
|
||||||
self.lastActiveTab = tabNum
|
self.lastActiveTab = tabNum
|
||||||
|
|
||||||
|
|
||||||
@ -590,12 +590,12 @@ class pluginclass( object ):
|
|||||||
self.mintMenuWin.stopHiding()
|
self.mintMenuWin.stopHiding()
|
||||||
return False
|
return False
|
||||||
|
|
||||||
def focusSearchEntry( self ):
|
def focusSearchEntry( self, clear = True ):
|
||||||
# grab_focus() does select all text,
|
# grab_focus() does select all text,
|
||||||
# restoring the original selection is somehow broken, so just select the end
|
# restoring the original selection is somehow broken, so just select the end
|
||||||
# of the existing text, that's the most likely candidate anyhow
|
# of the existing text, that's the most likely candidate anyhow
|
||||||
self.searchEntry.grab_focus()
|
self.searchEntry.grab_focus()
|
||||||
if self.rememberFilter:
|
if self.rememberFilter or not clear:
|
||||||
gtk.gtk_editable_set_position(hash(self.searchEntry), -1)
|
gtk.gtk_editable_set_position(hash(self.searchEntry), -1)
|
||||||
else:
|
else:
|
||||||
self.searchEntry.set_text("")
|
self.searchEntry.set_text("")
|
||||||
@ -818,8 +818,7 @@ class pluginclass( object ):
|
|||||||
else:
|
else:
|
||||||
text = widget.get_text()
|
text = widget.get_text()
|
||||||
if self.lastActiveTab != 1:
|
if self.lastActiveTab != 1:
|
||||||
self.changeTab( 1 )
|
self.changeTab( 1, clear = False )
|
||||||
widget.set_text( text )
|
|
||||||
text = widget.get_text()
|
text = widget.get_text()
|
||||||
showns = False # Are any app shown?
|
showns = False # Are any app shown?
|
||||||
shownList = []
|
shownList = []
|
||||||
@ -1124,7 +1123,7 @@ class pluginclass( object ):
|
|||||||
#menu.reposition()
|
#menu.reposition()
|
||||||
#menu.reposition()
|
#menu.reposition()
|
||||||
#self.mintMenuWin.grab()
|
#self.mintMenuWin.grab()
|
||||||
self.focusSearchEntry()
|
self.focusSearchEntry(clear = False)
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def pos_func(self, menu=None):
|
def pos_func(self, menu=None):
|
||||||
@ -1756,8 +1755,15 @@ class pluginclass( object ):
|
|||||||
|
|
||||||
|
|
||||||
sortedApplicationList.sort()
|
sortedApplicationList.sort()
|
||||||
|
launcherNames = [] # Keep track of launcher names so we don't add them twice in the list..
|
||||||
for item in sortedApplicationList:
|
for item in sortedApplicationList:
|
||||||
self.applicationsBox.pack_start( item[1], False, False, 0 )
|
launcherName = item[0]
|
||||||
|
button = item[1]
|
||||||
|
self.applicationsBox.pack_start( button, False, False, 0 )
|
||||||
|
if launcherName in launcherNames:
|
||||||
|
button.hide()
|
||||||
|
else:
|
||||||
|
launcherNames.append(launcherName)
|
||||||
|
|
||||||
self.rebuildLock = False
|
self.rebuildLock = False
|
||||||
|
|
||||||
|
@ -176,7 +176,7 @@ class easyButton( Gtk.Button ):
|
|||||||
def addLabel( self, text, styles = None ):
|
def addLabel( self, text, styles = None ):
|
||||||
label = Gtk.Label()
|
label = Gtk.Label()
|
||||||
if "<b>" in text or "<span" in text:
|
if "<b>" in text or "<span" in text:
|
||||||
label.set_markup(text) # don't remove our pango
|
label.set_markup(text.replace('&', '&')) # don't remove our pango
|
||||||
else:
|
else:
|
||||||
label.set_text(text)
|
label.set_text(text)
|
||||||
|
|
||||||
|
@ -25,20 +25,11 @@ class PointerMonitor(GObject.GObject, threading.Thread):
|
|||||||
self.display = Display()
|
self.display = Display()
|
||||||
self.root = self.display.screen().root
|
self.root = self.display.screen().root
|
||||||
self.windows = []
|
self.windows = []
|
||||||
self.topWindows = []
|
|
||||||
|
|
||||||
# Receives GDK windows
|
# Receives GDK windows
|
||||||
def addWindowToMonitor(self, window):
|
def addWindowToMonitor(self, window):
|
||||||
xWindow = self.display.create_resource_object("window", gdk.gdk_x11_drawable_get_xid(hash(window)))
|
xWindow = self.display.create_resource_object("window", gdk.gdk_x11_drawable_get_xid(hash(window)))
|
||||||
self.windows.append(xWindow)
|
self.windows.append(xWindow)
|
||||||
self.topWindows.append(self.getToplevelParent(xWindow))
|
|
||||||
|
|
||||||
def getToplevelParent(self, window):
|
|
||||||
parent = window.query_tree().parent
|
|
||||||
if parent == self.root:
|
|
||||||
return window
|
|
||||||
else:
|
|
||||||
return self.getToplevelParent(parent)
|
|
||||||
|
|
||||||
def grabPointer(self):
|
def grabPointer(self):
|
||||||
self.root.grab_button(X.AnyButton, X.AnyModifier, True, X.ButtonPressMask, X.GrabModeSync, X.GrabModeAsync, 0, 0)
|
self.root.grab_button(X.AnyButton, X.AnyModifier, True, X.ButtonPressMask, X.GrabModeSync, X.GrabModeAsync, 0, 0)
|
||||||
@ -62,11 +53,7 @@ class PointerMonitor(GObject.GObject, threading.Thread):
|
|||||||
try:
|
try:
|
||||||
if event.type == X.ButtonPress:
|
if event.type == X.ButtonPress:
|
||||||
# Check if pointer is inside monitored windows
|
# Check if pointer is inside monitored windows
|
||||||
for w, topW in zip(self.windows, self.topWindows):
|
for w in self.windows:
|
||||||
if event.child == topW:
|
|
||||||
if topW == w:
|
|
||||||
break
|
|
||||||
else:
|
|
||||||
p = w.query_pointer()
|
p = w.query_pointer()
|
||||||
g = w.get_geometry()
|
g = w.get_geometry()
|
||||||
if p.win_x >= 0 and p.win_y >= 0 and p.win_x <= g.width and p.win_y <= g.height:
|
if p.win_x >= 0 and p.win_y >= 0 and p.win_x <= g.width and p.win_y <= g.height:
|
||||||
@ -74,8 +61,9 @@ class PointerMonitor(GObject.GObject, threading.Thread):
|
|||||||
else:
|
else:
|
||||||
# Is outside, so activate
|
# Is outside, so activate
|
||||||
GLib.idle_add(self.idle)
|
GLib.idle_add(self.idle)
|
||||||
|
|
||||||
self.display.allow_events(X.ReplayPointer, event.time)
|
self.display.allow_events(X.ReplayPointer, event.time)
|
||||||
|
else:
|
||||||
|
self.display.allow_events(X.ReplayPointer, X.CurrentTime)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print "Unexpected error: " + str(e)
|
print "Unexpected error: " + str(e)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user