[Sugar-devel] [PATCH sugar] Frame: reveal Palette on left click for device, friends and clipboard items v2

Sascha Silbe silbe at activitycentral.com
Tue Aug 21 05:15:07 EDT 2012


Simon Schampijer <simon at schampijer.de> writes:

> As well the clipboard icons will reveal now the Palette on left
> click. This is also true when selecting a clipboard item. Technically we
> have to listen to the 'button-release-event' of the child widget
> as the RadioToolButton does only emit a clicked signal. Using this
> would colide with the state changes of the clipboard items as those
> emit a signal [1]. We do let the event propagate further
> (return False) so that the state change when selecting another
> item is picked up.
[...]

[src/jarabe/frame/clipboardicon.py]
> +    def __button_release_event_cb(self, widget, event):
> +        if event.button != 1:
> +            return False
> +        self.props.palette_invoker.notify_right_click()
> +        return False

We should document why we are returning False here, as explained in the
commit message.

Sascha
-- 
http://sascha.silbe.org/
http://www.infra-silbe.de/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 489 bytes
Desc: not available
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20120821/e202e682/attachment-0001.pgp>


More information about the Sugar-devel mailing list