Ticket #4414: 0001-Fix-Object-Chooser-windows-not-attached-to-activity-.patch

File 0001-Fix-Object-Chooser-windows-not-attached-to-activity-.patch, 1.4 KB (added by manuq, 11 years ago)

Patch

  • src/jarabe/journal/objectchooser.py

    From 9297f277a87f5faef13326b40abe9525f5882f09 Mon Sep 17 00:00:00 2001
    From: =?UTF-8?q?Manuel=20Qui=C3=B1ones?= <manuq@laptop.org>
    Date: Wed, 6 Feb 2013 16:45:05 -0300
    Subject: [PATCH] Fix Object Chooser windows not attached to activity windows -
     SL #4414
    MIME-Version: 1.0
    Content-Type: text/plain; charset=UTF-8
    Content-Transfer-Encoding: 8bit
    Mail-Followup-To: <sugar-devel@lists.sugarlabs.org>
    
    Calling Gtk.Window.set_transient_for() with a Gdk.Window fails with a
    TypeError.  Following the code it seems OK that a Gdk.Window is passed
    as the parent parameter of shell's ObjectChooser constructor.  So the
    fix is to call the method with the same name of the ObjectChooser
    Gdk.Window.
    
    Signed-off-by: Manuel Quiñones <manuq@laptop.org>
    ---
     src/jarabe/journal/objectchooser.py | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/src/jarabe/journal/objectchooser.py b/src/jarabe/journal/objectchooser.py
    index e7da414..9315192 100644
    a b class ObjectChooser(Gtk.Window): 
    101101            self._toolbar.set_what_filter(what_filter)
    102102
    103103    def __realize_cb(self, chooser, parent):
    104         self.set_transient_for(parent)
     104        self.get_window().set_transient_for(parent)
    105105        # TODO: Should we disconnect the signal here?
    106106
    107107    def __window_closed_cb(self, screen, window, parent):