summaryrefslogtreecommitdiffstats
path: root/source/widgets/textbox.c
diff options
context:
space:
mode:
authorQuentin Glidic <sardemff7+git@sardemff7.net>2017-05-30 12:45:48 +0200
committerQuentin Glidic <sardemff7+git@sardemff7.net>2017-05-30 13:45:19 +0200
commitacc1fa45b955fa2a771cb1a22c541086d1425a19 (patch)
tree3b41149930995b646f082441841b6c58b9ba98aa /source/widgets/textbox.c
parent0555d15c469d0dffbbfc33f351f4eed5882b3370 (diff)
widget: Add motion grab support
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
Diffstat (limited to 'source/widgets/textbox.c')
-rw-r--r--source/widgets/textbox.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/widgets/textbox.c b/source/widgets/textbox.c
index f527b7a5..9fd9c0f5 100644
--- a/source/widgets/textbox.c
+++ b/source/widgets/textbox.c
@@ -106,7 +106,7 @@ static int textbox_get_desired_height ( widget *wid )
return height;
}
-static gboolean textbox_editable_trigger_action ( widget *wid, MouseBindingMouseDefaultAction action, gint x, gint y, G_GNUC_UNUSED void *user_data )
+static WidgetTriggerActionResult textbox_editable_trigger_action ( widget *wid, MouseBindingMouseDefaultAction action, gint x, gint y, G_GNUC_UNUSED void *user_data )
{
textbox *tb = (textbox *) wid;
switch ( action )
@@ -116,14 +116,14 @@ static gboolean textbox_editable_trigger_action ( widget *wid, MouseBindingMouse
gint i;
pango_layout_xy_to_index ( tb->layout, x * PANGO_SCALE, y * PANGO_SCALE, &i, NULL );
textbox_cursor ( tb, i );
- return TRUE;
+ return WIDGET_TRIGGER_ACTION_RESULT_HANDLED;
}
case MOUSE_CLICK_UP:
case MOUSE_DCLICK_DOWN:
case MOUSE_DCLICK_UP:
break;
}
- return FALSE;
+ return WIDGET_TRIGGER_ACTION_RESULT_IGNORED;
}
textbox* textbox_create_full ( WidgetType type, const char *name, TextboxFlags flags, TextBoxFontType tbft, const char *text )