Flutter Engine
 
Loading...
Searching...
No Matches
fl_windowing_channel.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_WINDOWING_CHANNEL_H_
6#define FLUTTER_SHELL_PLATFORM_LINUX_FL_WINDOWING_CHANNEL_H_
7
10
11G_BEGIN_DECLS
12
13G_DECLARE_FINAL_TYPE(FlWindowingChannel,
14 fl_windowing_channel,
15 FL,
16 WINDOWING_CHANNEL,
17 GObject);
18
19// States that a window can be in.
26
27// Size dimensions used in windowing channel.
28typedef struct {
29 double width;
30 double height;
32
33/**
34 * FlWindowingChannel:
35 *
36 * #FlWindowingChannel is a channel that implements the shell side
37 * of SystemChannels.windowing from the Flutter services library.
38 */
39
40typedef struct {
41 FlMethodResponse* (*create_regular)(FlWindowingSize* size,
42 FlWindowingSize* min_size,
43 FlWindowingSize* max_size,
44 const gchar* title,
45 FlWindowState state,
46 gpointer user_data);
47 FlMethodResponse* (*modify_regular)(int64_t view_id,
48 FlWindowingSize* size,
49 const gchar* title,
50 FlWindowState state,
51 gpointer user_data);
52 FlMethodResponse* (*destroy_window)(int64_t view_id, gpointer user_data);
54
55/**
56 * fl_windowing_channel_new:
57 * @messenger: an #FlBinaryMessenger
58 * @vtable: callbacks for incoming method calls.
59 * @user_data: data to pass in callbacks.
60 *
61 * Creates a new channel that sends handled windowing requests from the
62 * platform.
63 *
64 * Returns: a new #FlWindowingChannel
65 */
66FlWindowingChannel* fl_windowing_channel_new(FlBinaryMessenger* messenger,
68 gpointer user_data);
69
71 int64_t view_id,
72 FlWindowingSize* size,
73 FlWindowState state);
74
76
78
79G_END_DECLS
80
81#endif // FLUTTER_SHELL_PLATFORM_LINUX_FL_WINDOWING_CHANNEL_H_
G_BEGIN_DECLS FlutterViewId view_id
FlWindowingChannel * fl_windowing_channel_new(FlBinaryMessenger *messenger, FlWindowingChannelVTable *vtable, gpointer user_data)
@ FL_WINDOW_STATE_UNDEFINED
@ FL_WINDOW_STATE_MINIMIZED
@ FL_WINDOW_STATE_MAXIMIZED
@ FL_WINDOW_STATE_RESTORED
FlMethodResponse * fl_windowing_channel_make_create_regular_response(int64_t view_id, FlWindowingSize *size, FlWindowState state)
FlMethodResponse * fl_windowing_channel_make_modify_regular_response()
G_BEGIN_DECLS G_DECLARE_FINAL_TYPE(FlWindowingChannel, fl_windowing_channel, FL, WINDOWING_CHANNEL, GObject)
FlMethodResponse * fl_windowing_channel_make_destroy_window_response()