| Flutter Linux Embedder |

fl_plugin_registry.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_PLUGIN_REGISTRY_H_
6 #define FLUTTER_SHELL_PLATFORM_LINUX_FL_PLUGIN_REGISTRY_H_
7
8 #if !defined(__FLUTTER_LINUX_INSIDE__) && !defined(FLUTTER_LINUX_COMPILATION)
9 #error "Only <flutter_linux/flutter_linux.h> can be included directly."
10 #endif
11
12 #include <glib-object.h>
13 #include <gmodule.h>
14
15 #include "fl_plugin_registrar.h"
16
17 G_BEGIN_DECLS
18
19 G_MODULE_EXPORT
20 G_DECLARE_INTERFACE(FlPluginRegistry,
21 fl_plugin_registry,
22 FL,
23 PLUGIN_REGISTRY,
24 GObject)
25
26 /**
27 * FlPluginRegistry:
28 *
29 * #FlPluginRegistry vends #FlPluginRegistrar objects for named plugins.
30 */
31
32 struct _FlPluginRegistryInterface {
33 GTypeInterface g_iface;
34
35 /**
36 * FlPluginRegistry::get_registrar_for_plugin:
37 * @registry: an #FlPluginRegistry.
38 * @name: plugin name.
39 *
40 * Gets the plugin registrar for the plugin with @name.
41 *
42 * Returns: (transfer full): an #FlPluginRegistrar.
43 */
44 FlPluginRegistrar* (*get_registrar_for_plugin)(FlPluginRegistry* registry,
45 const gchar* name);
46 };
47
48 /**
49 * fl_plugin_registry_get_registrar_for_plugin:
50 * @registry: an #FlPluginRegistry.
51 * @name: plugin name.
52 *
53 * Gets the plugin registrar for the plugin with @name.
54 *
55 * Returns: (transfer full): an #FlPluginRegistrar.
56 */
57 FlPluginRegistrar* fl_plugin_registry_get_registrar_for_plugin(
58 FlPluginRegistry* registry,
59 const gchar* name);
60
61 G_END_DECLS
62
63 #endif // FLUTTER_SHELL_PLATFORM_LINUX_FL_PLUGIN_REGISTRY_H_
fl_plugin_registrar.h
G_DECLARE_INTERFACE
G_DECLARE_INTERFACE(FlKeyResponder, fl_key_responder, FL, KEY_RESPONDER, GObject)
fl_plugin_registry_get_registrar_for_plugin
FlPluginRegistrar * fl_plugin_registry_get_registrar_for_plugin(FlPluginRegistry *registry, const gchar *name)
Definition: fl_plugin_registry.cc:13
FL
FL
Definition: fl_binary_messenger.cc:27