Ticket #2184: remove_resizable_false.patch

File remove_resizable_false.patch, 1.9 KB (added by manuq, 11 years ago)

Remove resizable false, and add some logging

  • src/sugar3/graphics/palettewindow.py

    diff --git a/src/sugar3/graphics/palettewindow.py b/src/sugar3/graphics/palettewindow.py
    index c48ae55..95cf92e 100644
    a b class _PaletteWindowWidget(Gtk.Window): 
    276276
    277277        self._palette = palette
    278278        self.set_decorated(False)
    279         self.set_resizable(False)
     279#        self.set_resizable(False)
     280        self.set_has_resize_grip(False)
    280281        self.set_position(Gtk.WindowPosition.NONE)
    281282
     283        self.connect('draw', self.draw_cb)
     284
    282285        context = self.get_style_context()
    283286        # Just assume all borders are the same
    284287        border = context.get_border(Gtk.StateFlags.ACTIVE).right
    class _PaletteWindowWidget(Gtk.Window): 
    351354
    352355        return rect
    353356
     357    def draw_cb(self, win, cr):
     358        logging.debug("MANUQ draw_cb")
     359
    354360    def do_draw(self, cr):
     361        logging.debug("MANUQ do_draw")
    355362        # Fall trough to the container expose handler.
    356363        # (Leaving out the window expose handler which redraws everything)
    357364        Gtk.Window.do_draw(self, cr)
    class _PaletteWindowWidget(Gtk.Window): 
    387394            self.emit('leave-notify')
    388395
    389396    def popup(self, invoker):
     397        logging.debug("MANUQ _PaletteWindowWidget popup %r", self.get_visible())
    390398        if self.get_visible():
    391399            return
    392400        self.connect('enter-notify-event', self.__enter_notify_event_cb)
    class _PaletteWindowWidget(Gtk.Window): 
    398406            return
    399407        self.disconnect_by_func(self.__enter_notify_event_cb)
    400408        self.disconnect_by_func(self.__leave_notify_event_cb)
     409        logging.debug("MANUQ _PaletteWindowWidget popdown")
    401410        self.hide()
    402411
    403412
    class Invoker(GObject.GObject): 
    975984
    976985    def notify_toggle_state(self):
    977986        self._ensure_palette_exists()
     987        logging.debug("MANUQ notify_toggle_state")
    978988        self.emit('toggle-state')
    979989
    980990    def get_palette(self):