xfdesktop changes ?

jp.guillemin jp.guillemin at free.fr
Tue Jan 13 18:18:18 CET 2009


from xfce-desktop.c :
______________________________________
static gboolean
xfce_desktop_button_press_event(GtkWidget *w,
                                GdkEventButton *evt)
{
    guint button = evt->button;
    guint state = evt->state;
   
    if(evt->type == GDK_BUTTON_PRESS) {
        if(button == 2 || (button == 1 && (state & GDK_SHIFT_MASK)
                           && (state & GDK_CONTROL_MASK)))
        {
            xfce_desktop_popup_secondary_root_menu(XFCE_DESKTOP(w),
                                                   button, evt->time);
            return TRUE;
        } else if(button == 3 || (button == 1 && (state & 
GDK_SHIFT_MASK))) {
            xfce_desktop_popup_root_menu(XFCE_DESKTOP(w),
                                         button, evt->time);
            return TRUE;
        }
    }
   
    return FALSE;
}
______________________________________

button == 1, button == 2 , button == 3 ... I think that each mouse 
button can be mapped to whatever callback... no ?


Brian J. Tarricone wrote:
> On Tue, 13 Jan 2009 10:51:33 +0100 (CET) jp.guillemin at free.fr wrote:
>
>   
>> What about the configuration option to affect each mouse button to a
>> different menu ? (I remind that you told me that you would add this
>> configuration option in the RC ..)
>>     
>
> I tried, but it turned out to be a bit more difficult than I expected.
> I think some key+mouse-button combinations are reserved by gtk, and I
> never figured out how to override them properly.
>
> Personally I don't care about this enough to try to break gtk, so if
> someone wants this, they'll have to come up with a patch themselves.
>
> 	-brian
> _______________________________________________
> Xfce4-dev mailing list
> Xfce4-dev at xfce.org
> http://foo-projects.org/mailman/listinfo/xfce4-dev
>   

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.xfce.org/pipermail/xfce4-dev/attachments/20090113/0e6a69d3/attachment.html>


More information about the Xfce4-dev mailing list