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

gitlab.com/Remmina/Remmina.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntenore Gatta <antenore@simbiosi.org>2018-07-12 23:48:55 +0300
committerAntenore Gatta <antenore@simbiosi.org>2018-07-12 23:48:55 +0300
commitc3e73a3eb646b64605c186f91f0532f0961813f2 (patch)
tree5124b85b554cf885489689f688ef37fa8eca9621 /src/remmina.c
parent5502acc90e372ffef54c52d7cdeff400950357ff (diff)
Kiosk mode, initial implementation
Diffstat (limited to 'src/remmina.c')
-rw-r--r--src/remmina.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/remmina.c b/src/remmina.c
index d32f15429..61610058c 100644
--- a/src/remmina.c
+++ b/src/remmina.c
@@ -41,6 +41,7 @@
#include <stdlib.h>
#include "config.h"
+#include "remmina.h"
#include "remmina_exec.h"
#include "remmina_file_manager.h"
#include "remmina_icon.h"
@@ -73,6 +74,8 @@ static int gcrypt_thread_initialized = 0;
#endif /* !GCRYPT_VERSION_NUMBER */
#endif /* HAVE_LIBGCRYPT */
+gboolean kioskmode;
+
static GOptionEntry remmina_options[] =
{
{ "about", 'a', 0, G_OPTION_ARG_NONE, NULL, N_("Show about dialog"), NULL },
@@ -80,6 +83,7 @@ static GOptionEntry remmina_options[] =
{ G_OPTION_REMAINING, '\0', 0, G_OPTION_ARG_FILENAME_ARRAY, NULL, N_("Connect to a .remmina file"), "FILE" },
{ "edit", 'e', 0, G_OPTION_ARG_FILENAME, NULL, N_("Edit a .remmina file"), "FILE" },
{ "help", '?', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE, NULL, NULL, NULL },
+ { "kiosk", 'k', 0, G_OPTION_ARG_NONE, NULL, N_("Start Remmina in Kiosk mode"), NULL },
{ "new", 'n', 0, G_OPTION_ARG_NONE, NULL, N_("Create a new connection profile"), NULL },
{ "pref", 'p', 0, G_OPTION_ARG_STRING, NULL, N_("Show preferences dialog page"), "PAGENR" },
{ "plugin", 'x', 0, G_OPTION_ARG_STRING, NULL, N_("Execute the plugin"), "PLUGIN" },
@@ -131,7 +135,7 @@ static gint remmina_on_command_line(GApplication *app, GApplicationCommandLine *
/** @todo This should be a G_OPTION_ARG_FILENAME_ARRAY (^aay) so that
* we can implement multi profile connection:
- * https://github.com/FreeRDP/Remmina/issues/915
+ * https://gitlab.com/Remmina/Remmina/issues/915
*/
if (g_variant_dict_lookup(opts, "connect", "^ay", &str)) {
remmina_exec_command(REMMINA_COMMAND_CONNECT, g_strdup(str));
@@ -151,6 +155,12 @@ static gint remmina_on_command_line(GApplication *app, GApplicationCommandLine *
executed = TRUE;
}
+ if (g_variant_dict_lookup_value(opts, "kiosk", NULL)) {
+ kioskmode = TRUE;
+ remmina_exec_command(REMMINA_COMMAND_MAIN, NULL);
+ executed = TRUE;
+ }
+
if (g_variant_dict_lookup_value(opts, "new", NULL)) {
if (!g_variant_dict_lookup(opts, "protocol", "&s", &protocol))
protocol = NULL;