Flutter Linux Embedder
fl_text_input_handler.h
Go to the documentation of this file.
1
// Copyright 2013 The Flutter Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef FLUTTER_SHELL_PLATFORM_LINUX_FL_TEXT_INPUT_HANDLER_H_
6
#define FLUTTER_SHELL_PLATFORM_LINUX_FL_TEXT_INPUT_HANDLER_H_
7
8
#include <gtk/gtk.h>
9
10
#include "
flutter/shell/platform/linux/fl_key_event.h
"
11
#include "
flutter/shell/platform/linux/fl_text_input_view_delegate.h
"
12
#include "
flutter/shell/platform/linux/public/flutter_linux/fl_binary_messenger.h
"
13
14
G_BEGIN_DECLS
15
16
G_DECLARE_DERIVABLE_TYPE
(FlTextInputHandler,
17
fl_text_input_handler,
18
FL
,
19
TEXT_INPUT_HANDLER,
20
GObject);
21
22
/**
23
* FlTextInputHandler:
24
*
25
* #FlTextInputHandler is a handler that implements the shell side
26
* of SystemChannels.textInput from the Flutter services library.
27
*/
28
29
struct
_FlTextInputHandlerClass
{
30
GObjectClass
parent_class
;
31
32
/**
33
* Virtual method called to filter a keypress.
34
*/
35
gboolean (*
filter_keypress
)(FlTextInputHandler*
self
, FlKeyEvent*
event
);
36
};
37
38
/**
39
* fl_text_input_handler_new:
40
* @messenger: an #FlBinaryMessenger.
41
* @im_context: (allow-none): a #GtkIMContext.
42
* @view_delegate: an #FlTextInputViewDelegate.
43
*
44
* Creates a new handler that implements SystemChannels.textInput from the
45
* Flutter services library.
46
*
47
* Returns: a new #FlTextInputHandler.
48
*/
49
FlTextInputHandler*
fl_text_input_handler_new
(
50
FlBinaryMessenger* messenger,
51
GtkIMContext* im_context,
52
FlTextInputViewDelegate* view_delegate);
53
54
/**
55
* fl_text_input_handler_filter_keypress
56
* @handler: an #FlTextInputHandler.
57
* @event: a #FlKeyEvent
58
*
59
* Process a Gdk key event.
60
*
61
* Returns: %TRUE if the event was used.
62
*/
63
gboolean
fl_text_input_handler_filter_keypress
(FlTextInputHandler* handler,
64
FlKeyEvent*
event
);
65
66
G_END_DECLS
67
68
#endif // FLUTTER_SHELL_PLATFORM_LINUX_FL_TEXT_INPUT_HANDLER_H_
event
FlKeyEvent * event
Definition:
fl_key_channel_responder.cc:118
fl_text_input_view_delegate.h
fl_text_input_handler_new
FlTextInputHandler * fl_text_input_handler_new(FlBinaryMessenger *messenger, GtkIMContext *im_context, FlTextInputViewDelegate *view_delegate)
Definition:
fl_text_input_handler.cc:747
_FlTextInputHandlerClass::parent_class
GObjectClass parent_class
Definition:
fl_text_input_handler.h:30
_FlTextInputHandlerClass
Definition:
fl_text_input_handler.h:29
fl_binary_messenger.h
FL
FL
Definition:
fl_binary_messenger.cc:27
G_DECLARE_DERIVABLE_TYPE
G_BEGIN_DECLS G_DECLARE_DERIVABLE_TYPE(FlTextInputHandler, fl_text_input_handler, FL, TEXT_INPUT_HANDLER, GObject)
fl_key_event.h
_FlTextInputHandlerClass::filter_keypress
gboolean(* filter_keypress)(FlTextInputHandler *self, FlKeyEvent *event)
Definition:
fl_text_input_handler.h:35
fl_text_input_handler_filter_keypress
gboolean fl_text_input_handler_filter_keypress(FlTextInputHandler *handler, FlKeyEvent *event)
Definition:
fl_text_input_handler.cc:778
shell
platform
linux
fl_text_input_handler.h
Generated by
1.8.17