diff --git a/pw3270.cbp b/pw3270.cbp
index 5b99b7f..fe8d403 100644
--- a/pw3270.cbp
+++ b/pw3270.cbp
@@ -111,6 +111,9 @@
+
+
+
diff --git a/src/objects/window/actions/sethost.c b/src/objects/window/actions/sethost.c
new file mode 100644
index 0000000..96c5a04
--- /dev/null
+++ b/src/objects/window/actions/sethost.c
@@ -0,0 +1,80 @@
+/*
+ * "Software pw3270, desenvolvido com base nos códigos fontes do WC3270 e X3270
+ * (Paul Mattes Paul.Mattes@usa.net), de emulação de terminal 3270 para acesso a
+ * aplicativos mainframe. Registro no INPI sob o nome G3270.
+ *
+ * Copyright (C) <2008>
+ *
+ * Este programa é software livre. Você pode redistribuí-lo e/ou modificá-lo sob
+ * os termos da GPL v.2 - Licença Pública Geral GNU, conforme publicado pela
+ * Free Software Foundation.
+ *
+ * Este programa é distribuído na expectativa de ser útil, mas SEM QUALQUER
+ * GARANTIA; sem mesmo a garantia implícita de COMERCIALIZAÇÃO ou de ADEQUAÇÃO
+ * A QUALQUER PROPÓSITO EM PARTICULAR. Consulte a Licença Pública Geral GNU para
+ * obter mais detalhes.
+ *
+ * Você deve ter recebido uma cópia da Licença Pública Geral GNU junto com este
+ * programa; se não, escreva para a Free Software Foundation, Inc., 51 Franklin
+ * St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Este programa está nomeado como - e possui - linhas de código.
+ *
+ * Contatos:
+ *
+ * perry.werneck@gmail.com (Alexandre Perry de Souza Werneck)
+ * erico.mendonca@gmail.com (Erico Mascarenhas Mendonça)
+ *
+ */
+
+ #include "../private.h"
+ #include
+ #include
+ #include
+
+ static void on_response(GtkDialog *dialog, gint response_id, GtkWidget *settings) {
+
+ v3270_settings_on_dialog_response(dialog,response_id,settings);
+
+ if(response_id == GTK_RESPONSE_APPLY) {
+#ifndef DEBUG
+ #error TO DO!
+#endif // DEBUG
+ }
+
+ gtk_widget_destroy(GTK_WIDGET(dialog));
+
+ }
+
+ void pw3270_window_set_host_activated(GSimpleAction G_GNUC_UNUSED(* action), GVariant G_GNUC_UNUSED(*parameter), gpointer window) {
+
+ debug("%s",__FUNCTION__);
+
+ if(!PW3270_IS_APPLICATION_WINDOW(window))
+ return;
+
+ GtkWidget * terminal = gtk_window_get_default_widget(GTK_WINDOW(window));
+ if(!GTK_IS_V3270(terminal))
+ return;
+
+ GtkWidget * settings = v3270_host_select_new();
+ GtkWidget * dialog =
+ v3270_settings_dialog_new(
+ terminal,
+ settings
+ );
+
+ if(dialog) {
+
+ v3270_dialog_setup(dialog,_("Setup host"),_("C_onnect"));
+
+ gtk_window_set_default_size(GTK_WINDOW(dialog), 700, 150);
+
+ g_signal_connect(dialog,"close",G_CALLBACK(gtk_widget_destroy),NULL);
+ g_signal_connect(dialog,"response",G_CALLBACK(on_response),settings);
+
+ gtk_widget_show_all(dialog);
+ }
+
+ }
+
diff --git a/src/objects/window/private.h b/src/objects/window/private.h
index 10fc5f8..f83c721 100644
--- a/src/objects/window/private.h
+++ b/src/objects/window/private.h
@@ -68,5 +68,7 @@
G_GNUC_INTERNAL void pw3270_window_open_activated(GSimpleAction * action, GVariant *parameter, gpointer application);
G_GNUC_INTERNAL void pw3270_window_close_activated(GSimpleAction * action, GVariant *parameter, gpointer application);
G_GNUC_INTERNAL void pw3270_window_preferences_activated(GSimpleAction * action, GVariant *parameter, gpointer application);
+ G_GNUC_INTERNAL void pw3270_window_set_host_activated(GSimpleAction G_GNUC_UNUSED(* action), GVariant G_GNUC_UNUSED(*parameter), gpointer application);
+
#endif // PRIVATE_H_INCLUDED
diff --git a/src/objects/window/window.c b/src/objects/window/window.c
index c592cf2..f9ced01 100644
--- a/src/objects/window/window.c
+++ b/src/objects/window/window.c
@@ -115,6 +115,12 @@
.activate = pw3270_window_preferences_activated,
},
+ {
+ .name = "set.host",
+ .activate = pw3270_window_set_host_activated,
+ },
+
+
};
g_action_map_add_action_entries(
diff --git a/ui/application.xml b/ui/application.xml
index 0b3a17e..41c2047 100644
--- a/ui/application.xml
+++ b/ui/application.xml
@@ -144,7 +144,7 @@
-
Paste text file
- win.pastefile
+ win.paste_file
@@ -210,7 +210,7 @@
-
Configure host
- win.setup_host
+ win.set.host
-
@@ -231,17 +231,17 @@
-
Colors
- win.coloers
+ win.edit.colors
-
Select font
- win.select_font
+ win.select.font
-
Screen sizes
- win.screen_sizes
+ win.screen.sizes
--
libgit2 0.21.2