forked from AuroraMiddleware/gtk
gtkcalendar: Use symbolic names for button numbers
This commit is contained in:
parent
e796f3a4e7
commit
c5d9c6f27c
@ -2986,7 +2986,7 @@ calendar_main_button_press (GtkCalendar *calendar,
|
|||||||
if (!gtk_widget_has_focus (widget))
|
if (!gtk_widget_has_focus (widget))
|
||||||
gtk_widget_grab_focus (widget);
|
gtk_widget_grab_focus (widget);
|
||||||
|
|
||||||
if (event->button == 1)
|
if (event->button == GDK_BUTTON_PRIMARY)
|
||||||
{
|
{
|
||||||
priv->in_drag = 1;
|
priv->in_drag = 1;
|
||||||
priv->drag_start_x = x;
|
priv->drag_start_x = x;
|
||||||
@ -3027,7 +3027,7 @@ gtk_calendar_button_press (GtkWidget *widget,
|
|||||||
/* only call the action on single click, not double */
|
/* only call the action on single click, not double */
|
||||||
if (event->type == GDK_BUTTON_PRESS)
|
if (event->type == GDK_BUTTON_PRESS)
|
||||||
{
|
{
|
||||||
if (event->button == 1)
|
if (event->button == GDK_BUTTON_PRIMARY)
|
||||||
calendar_start_spinning (calendar, arrow);
|
calendar_start_spinning (calendar, arrow);
|
||||||
|
|
||||||
calendar_arrow_action (calendar, arrow);
|
calendar_arrow_action (calendar, arrow);
|
||||||
@ -3047,7 +3047,7 @@ gtk_calendar_button_release (GtkWidget *widget,
|
|||||||
GtkCalendar *calendar = GTK_CALENDAR (widget);
|
GtkCalendar *calendar = GTK_CALENDAR (widget);
|
||||||
GtkCalendarPrivate *priv = GTK_CALENDAR_GET_PRIVATE (widget);
|
GtkCalendarPrivate *priv = GTK_CALENDAR_GET_PRIVATE (widget);
|
||||||
|
|
||||||
if (event->button == 1)
|
if (event->button == GDK_BUTTON_PRIMARY)
|
||||||
{
|
{
|
||||||
calendar_stop_spinning (calendar);
|
calendar_stop_spinning (calendar);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user