示例#1
0
文件: views.c 项目: BYC/geany-plugins
gboolean on_view_button_1_press(GtkWidget *widget, GdkEventButton *event, ViewSeeker seeker)
{
	if (event->button == 1 && (pref_auto_view_source || event->type == GDK_2BUTTON_PRESS))
	{
		utils_handle_button_press(widget, event);
		seeker(event->type == GDK_2BUTTON_PRESS);
		return TRUE;
	}

	return FALSE;
}
示例#2
0
static gboolean on_button_3_press(GtkWidget *widget, GdkEventButton *event, GtkMenu *menu)
{
	if (event->button == 3)
	{
		utils_handle_button_press(widget, event);
		gtk_menu_popup(menu, NULL, NULL, NULL, NULL, event->button, event->time);
		return TRUE;
	}

	return FALSE;
}