Welcome to mirror list, hosted at ThFree Co, Russian Federation.

remmina_pref.h « src « remmina - gitlab.com/Remmina/Remmina.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 8e6f97d2d9e7eb7120f796a8615023601649d651 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
/*
 * Remmina - The GTK+ Remote Desktop Client
 * Copyright (C) 2009-2011 Vic Lee
 * Copyright (C) 2014-2015 Antenore Gatta, Fabio Castelli, Giovanni Panozzo
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA  02110-1301, USA.
 *
 *  In addition, as a special exception, the copyright holders give
 *  permission to link the code of portions of this program with the
 *  OpenSSL library under certain conditions as described in each
 *  individual source file, and distribute linked combinations
 *  including the two.
 *  You must obey the GNU General Public License in all respects
 *  for all of the code used other than OpenSSL. *  If you modify
 *  file(s) with this exception, you may extend this exception to your
 *  version of the file(s), but you are not obligated to do so. *  If you
 *  do not wish to do so, delete this exception statement from your
 *  version. *  If you delete this exception statement from all source
 *  files in the program, then also delete it here.
 *
 */

#ifndef __REMMINAPREF_H__
#define __REMMINAPREF_H__

/*
 * Remmina Perference Loader
 */

G_BEGIN_DECLS

enum
{
	REMMINA_VIEW_FILE_LIST,
	REMMINA_VIEW_FILE_TREE
};

enum
{
	REMMINA_ACTION_CONNECT = 0,
	REMMINA_ACTION_EDIT = 1
};

enum
{
	AUTO_MODE = 0,
	SCROLLED_WINDOW_MODE = 1,
	FULLSCREEN_MODE = 2,
	SCROLLED_FULLSCREEN_MODE = 3,
	VIEWPORT_FULLSCREEN_MODE = 4
};

enum
{
	FLOATING_TOOLBAR_PLACEMENT_TOP = 0,
	FLOATING_TOOLBAR_PLACEMENT_BOTTOM = 1
};

enum
{
	TOOLBAR_PLACEMENT_TOP = 0,
	TOOLBAR_PLACEMENT_RIGHT = 1,
	TOOLBAR_PLACEMENT_BOTTOM = 2,
	TOOLBAR_PLACEMENT_LEFT = 3
 };

enum
{
	REMMINA_TAB_BY_GROUP = 0,
	REMMINA_TAB_BY_PROTOCOL = 1,
	REMMINA_TAB_ALL = 2,
	REMMINA_TAB_NONE = 3
};

typedef struct _RemminaPref
{
	/* In RemminaPrefDialog options tab */
	gboolean save_view_mode;
	gboolean save_when_connect;
	gboolean survey;
	gint default_action;
	gint scale_quality;
	gint ssh_loglevel;
	gboolean ssh_parseconfig;
	gint sshtunnel_port;
	gint auto_scroll_step;
	gint recent_maximum;
	gchar *resolutions;
	gchar *keystrokes;
	/* In RemminaPrefDialog appearance tab */
	gboolean invisible_toolbar;
	gboolean always_show_tab;
	gboolean hide_connection_toolbar;
	gint default_mode;
	gint tab_mode;
	gint show_buttons_icons;
	gint show_menu_icons;
	/* In RemminaPrefDialog applet tab */
	gboolean applet_new_ontop;
	gboolean applet_hide_count;
	gboolean disable_tray_icon;
	/* In RemminaPrefDialog keyboard tab */
	guint hostkey;
	guint shortcutkey_fullscreen;
	guint shortcutkey_autofit;
	guint shortcutkey_prevtab;
	guint shortcutkey_nexttab;
	guint shortcutkey_scale;
	guint shortcutkey_grab;
	guint shortcutkey_minimize;
	guint shortcutkey_disconnect;
	guint shortcutkey_toolbar;
	/* In RemminaPrefDialog terminal tab */
	gchar *vte_font;
	gboolean vte_allow_bold_text;
	gboolean vte_system_colors;
	gchar *vte_foreground_color;
	gchar *vte_background_color;
	gint vte_lines;
	guint vte_shortcutkey_copy;
	guint vte_shortcutkey_paste;
	/* In View menu */
	gboolean hide_toolbar;
	gboolean hide_statusbar;
	gboolean show_quick_search;
	gboolean hide_quick_connect;
	gboolean small_toolbutton;
	gint view_file_mode;
	/* In tray icon */
	gboolean applet_enable_avahi;
	/* Auto */
	gint main_width;
	gint main_height;
	gboolean main_maximize;
	gint main_sort_column_id;
	gint main_sort_order;
	gchar *expanded_group;
	gboolean toolbar_pin_down;
	gint floating_toolbar_placement;
	gint toolbar_placement;

	/* Crypto */
	gchar *secret;

	/* UID */
	gchar *uid;

	/* Remmina birthday julian format*/
	guint32 bdate;
} RemminaPref;

#define DEFAULT_SSH_PARSECONFIG TRUE
#define DEFAULT_SSHTUNNEL_PORT 4732
#define DEFAULT_SSH_PORT 22
#define DEFAULT_SSH_LOGLEVEL 1

extern const gchar *default_resolutions;
extern gchar *remmina_pref_file;
extern RemminaPref remmina_pref;

void remmina_pref_init(void);
void remmina_pref_save(void);

gboolean remmina_pref_get_survey(void);

void remmina_pref_add_recent(const gchar *protocol, const gchar *server);
gchar* remmina_pref_get_recent(const gchar *protocol);
void remmina_pref_clear_recent(void);

guint remmina_pref_keymap_get_keyval(const gchar *keymap, guint keyval);
gchar** remmina_pref_keymap_groups(void);

gint remmina_pref_get_scale_quality(void);
gint remmina_pref_get_ssh_loglevel(void);
gboolean remmina_pref_get_ssh_parseconfig(void);
gint remmina_pref_get_sshtunnel_port(void);

void remmina_pref_set_value(const gchar *key, const gchar *value);
gchar* remmina_pref_get_value(const gchar *key);

G_END_DECLS

#endif  /* __REMMINAPREF_H__  */