deskbar-applet-02-multihead-support.diff revision 13642
--- deskbar-applet-2.23.2.old/deskbar/ui/AbstractCuemiacDeskbarIcon.py 2008-05-29 16:18:39.929746000 +0100
+++ deskbar-applet-2.23.2/deskbar/ui/AbstractCuemiacDeskbarIcon.py 2008-05-29 16:20:59.272081000 +0100
@@ -31,7 +31,7 @@
self._active_view = deskbar.BUTTON_UI_NAME
def create_window_ui(self):
- self._view = CuemiacWindowView(self._controller, self._core)
+ self._view = CuemiacWindowView(self._controller, self._core, self.applet)
self._active_view = deskbar.WINDOW_UI_NAME
def _setup_core (self):
--- deskbar-applet-2.23.2.old/deskbar/ui/CuemiacAlignedView.py 2008-05-29 16:18:39.930265000 +0100
+++ deskbar-applet-2.23.2/deskbar/ui/CuemiacAlignedView.py 2008-05-29 16:27:55.476993000 +0100
@@ -24,6 +24,7 @@
self.set_type_hint (gtk.gdk.WINDOW_TYPE_HINT_MENU)
self.applet.set_applet_flags(gnomeapplet.EXPAND_MINOR)
self.applet.set_flags(gtk.CAN_FOCUS)
+ self.set_screen(applet.get_screen())
self.applet.connect("change-orient", self._on_change_orient)
self._screen_height = self.get_screen().get_height ()
@@ -59,6 +60,9 @@
def get_toplevel(self):
return self
+
+ def get_topwindow(self):
+ return self.applet.window
def receive_focus(self, time):
self.applet.set_state(gtk.STATE_SELECTED)
@@ -135,4 +139,4 @@
else:
self.vbox_main.reorder_child(self.results_box, 0)
self.vbox_main.reorder_child(self.header, 2)
-
\ No newline at end of file
+
--- deskbar-applet-2.23.5.old/deskbar/ui/CuemiacWindowView.py 2008-05-29 16:18:39.930125000 +0100
+++ deskbar-applet-2.23.5/deskbar/ui/CuemiacWindowView.py 2008-05-29 16:25:32.072521000 +0100
@@ -8,11 +8,13 @@
This class is responsible for setting up the GUI.
"""
- def __init__(self, controller, model):
+ def __init__(self, controller, model, applet):
AbstractCuemiacView.__init__(self, controller, model)
gtk.Window.__init__(self)
self._controller.register_view(self)
self.__small_window_height = None
+ self.applet = applet
+ self.set_screen(applet.get_screen())
self.connect("configure-event", self.__save_window_size)
self.connect("delete-event", self._controller.on_quit)
@@ -50,6 +50,9 @@
def get_toplevel(self):
return self
+ def get_topwindow(self):
+ return self.applet.window
+
def receive_focus(self, time):
self.move( self._model.get_window_x(), self._model.get_window_y() )
self.entry.grab_focus()
--- deskbar-applet-2.23.2.old/deskbar/ui/CuemiacWindowController.py 2008-05-29 16:18:39.929974000 +0100
+++ deskbar-applet-2.23.2/deskbar/ui/CuemiacWindowController.py 2008-05-29 16:24:18.865026000 +0100
@@ -1,6 +1,6 @@
import gtk
import gtk.gdk
-import gnomevfs
+import gnome
import logging
import deskbar
import deskbar.interfaces.Controller
@@ -49,14 +49,14 @@
return True
def on_show_about(self, sender):
- show_about(self._view.get_toplevel())
+ show_about(self._view.get_topwindow())
def on_show_preferences(self, sender):
prefs = DeskbarPreferences(self._model)
- prefs.show_run_hide(self._view.get_toplevel())
+ prefs.show_run_hide(self._view.get_topwindow())
def on_show_help(self, sender):
- gnomevfs.url_show("ghelp:deskbar")
+ gnome.ui.help_display_uri_on_screen("ghelp:deskbar", (self._view_get_topwindow()).get_screen())
def on_query_entry_changed(self, entry):
self._view.set_clear()