[network-manager-sstp/gtk4-work] Change to Makefile.am, wrong name
- From: Eivind Næss <eivnaes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-sstp/gtk4-work] Change to Makefile.am, wrong name
- Date: Fri, 1 Apr 2022 03:55:54 +0000 (UTC)
commit 518b6c77e521b5b2a29636ab107ff73628cb0ba1
Author: Eivind Næss <eivnaes yahoo com>
Date: Thu Mar 31 07:38:48 2022 -0700
Change to Makefile.am, wrong name
Signed-off-by: Eivind Næss <eivnaes yahoo com>
Makefile.am | 2 +-
configure.ac | 12 +++++-------
po/POTFILES.skip | 1 +
properties/advanced-dialog.c | 13 +++++++++----
properties/nm-sstp-dialog.ui | 38 +++++++++++++++++++++++++++++++++++++-
properties/nm-sstp-editor-plugin.c | 15 ++++++++++++---
properties/nm-sstp-editor.c | 14 ++++++++------
7 files changed, 73 insertions(+), 22 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 8a8645b..c62e254 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -146,7 +146,7 @@ gtk4/%.ui: properties/%.ui
# Include a prebuilt file in tarball, to avoid hitting
# https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/4415
EXTRA_DIST += \
- gtk4/nm-pptp-dialog.ui
+ gtk4/nm-sstp-dialog.ui
plugin_sources = \
shared/nm-utils/nm-vpn-plugin-macros.h \
diff --git a/configure.ac b/configure.ac
index fa5780f..2e7e58f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
AC_PREREQ([2.69])
AC_INIT([NetworkManager-sstp],[1.3.0],[eivnaes yahoo com],[NetworkManager-sstp])
-AM_INIT_AUTOMAKE([1.9 no-dist-gzip dist-xz -Wno-portability])
+AM_INIT_AUTOMAKE([1.9 no-dist-gzip dist-bzip2 -Wno-portability])
AM_MAINTAINER_MODE
AM_SILENT_RULES([yes])
@@ -22,8 +22,6 @@ AC_PROG_INSTALL
LT_INIT
AC_PATH_PROG(GLIB_COMPILE_RESOURCES, glib-compile-resources)
-AC_USE_SYSTEM_EXTENSIONS
-
AC_CHECK_PROG([has_file], file, yes, no)
if test x$has_file = xno ; then
AC_MSG_ERROR(["file" utility not found.])
@@ -91,7 +89,7 @@ if test x"$with_pppd_ext_tls_settings_support" != xyes; then
AS_VAR_SET([with_pppd_ext_tls_settings_support],[yes])
fi
fi
-if test x"$with_pppd_extended_tls_settings" == xyes; then
+if test x"$with_pppd_ext_tls_settings_support" == xyes; then
AC_DEFINE(USE_PPP_EXT_TLS_SETTINGS,1,[Define if pppd has support for extended tls-settings like pkcs12,
tls-verify-method, tls-verify-key-usage, max-tls-version])
else
AS_VAR_SET([with_pppd_ext_tls_settings_support],[no])
@@ -211,7 +209,7 @@ LIBNM_CFLAGS="$LIBNM_CFLAGS -DNM_VERSION_MAX_ALLOWED=NM_VERSION_1_8"
AC_ARG_WITH(system-ca-path,
AS_HELP_STRING([--with-system-ca-path=/path/to/ssl/certs], [path to system CA certificates]))
if test "x${with_system_ca_path}" = x; then
- SYSTEM_CA_PATH=/etc/ssl/certs
+ SYSTEM_CA_PATH="${sysconfdir}/ssl/certs"
else
SYSTEM_CA_PATH="$with_system_ca_path"
fi
@@ -253,9 +251,9 @@ echo " --with-dist-version=$ac_distver"
echo " --with-gnome=$with_gnome"
echo " --with-gtk4=$with_gtk4"
echo " --with-libnm-glib=$with_libnm_glib"
+echo " --with-system-ca-path=$SYSTEM_CA_PATH"
echo " --with-pppd-plugin-dir=$PPPD_PLUGIN_DIR"
echo " --with-pppd-auth-notify-support=$with_pppd_auth_notify_support"
-echo " --with-pppd-ext-tls-settings_support=$with_pppd_ext_tls_settings_support"
-echo " --with-system-ca-path=$SYSTEM_CA_PATH"
+echo " --with-pppd-ext-tls-settings-support=$with_pppd_ext_tls_settings_support"
echo " --enable-absolute-paths=$enable_absolute_paths"
echo " --enable-more-warnings=$set_more_warnings"
diff --git a/po/POTFILES.skip b/po/POTFILES.skip
new file mode 100644
index 0000000..7de5036
--- /dev/null
+++ b/po/POTFILES.skip
@@ -0,0 +1 @@
+gtk4/nm-sstp-dialog.ui
diff --git a/properties/advanced-dialog.c b/properties/advanced-dialog.c
index 2670a4e..c27eb59 100644
--- a/properties/advanced-dialog.c
+++ b/properties/advanced-dialog.c
@@ -47,6 +47,11 @@
#define TAG_MSCHAPV2 3
#define TAG_EAP 4
+#define PAGE_CONNECTION 0
+#define PAGE_POINT2POINT 1
+#define PAGE_TLS 2
+#define PAGE_PROXY 3
+
static const char *advanced_keys[] = {
NM_SSTP_KEY_REFUSE_EAP,
NM_SSTP_KEY_REFUSE_PAP,
@@ -459,7 +464,7 @@ auth_methods_setup (GtkBuilder *builder, GHashTable *hash)
static void
tls_page_setup(GtkBuilder *builder, GHashTable *hash, gboolean is_tls, gchar *subject)
{
- GtkWidget *widget;
+ GtkWidget *widget, *page;
GtkListStore *store;
GtkTreeIter iter;
const char *value;
@@ -580,9 +585,9 @@ tls_page_setup(GtkBuilder *builder, GHashTable *hash, gboolean is_tls, gchar *su
#endif
} else {
- // Desensitize the child widgets of alignment_tls if not TLS
- widget = GTK_WIDGET (gtk_builder_get_object (builder, "alignment_tls"));
- gtk_widget_set_sensitive(widget, is_tls);
+ widget = GTK_WIDGET (gtk_builder_get_object (builder, "adv_notebook"));
+ page = GTK_WIDGET (gtk_notebook_get_nth_page(GTK_NOTEBOOK(widget), PAGE_TLS));
+ gtk_widget_hide(page);
}
}
diff --git a/properties/nm-sstp-dialog.ui b/properties/nm-sstp-dialog.ui
index 247cec4..618fb2c 100644
--- a/properties/nm-sstp-dialog.ui
+++ b/properties/nm-sstp-dialog.ui
@@ -333,6 +333,9 @@ config: the first parameter of sstp</property>
</packing>
</child>
</object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
</child>
<child type="tab">
<object class="GtkLabel" id="label15">
@@ -418,6 +421,7 @@ config: the first parameter of sstp</property>
<property name="receives-default">False</property>
<property name="halign">end</property>
<property name="valign">end</property>
+ <property name="margin-top">32</property>
<child>
<object class="GtkBox" id="hbox2">
<property name="visible">True</property>
@@ -427,6 +431,7 @@ config: the first parameter of sstp</property>
<object class="GtkImage" id="image1">
<property name="visible">True</property>
<property name="can-focus">False</property>
+ <property name="icon-name">preferences-system-symbolic</property>
</object>
<packing>
<property name="expand">False</property>
@@ -495,6 +500,10 @@ config: the first parameter of sstp</property>
<property name="modal">True</property>
<property name="destroy-with-parent">True</property>
<property name="icon-name">stock-preferences</property>
+ <action-widgets>
+ <action-widget response="-6">cancel_button</action-widget>
+ <action-widget response="-5">apply_button</action-widget>
+ </action-widgets>
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox3">
<property name="visible">True</property>
@@ -502,7 +511,9 @@ config: the first parameter of sstp</property>
<property name="orientation">vertical</property>
<property name="spacing">16</property>
<child internal-child="action_area">
- <object class="GtkButtonBox" id="dialog-action_area1">
+ <object class="GtkBox" id="dialog-action_area1">
+ <property name="visible">True</property>
+ <property name="can-focus">False</property>
<child>
<placeholder/>
</child>
@@ -525,6 +536,10 @@ config: the first parameter of sstp</property>
<object class="GtkBox" id="ConnectionPage">
<property name="visible">True</property>
<property name="can-focus">False</property>
+ <property name="margin-start">6</property>
+ <property name="margin-end">6</property>
+ <property name="margin-top">6</property>
+ <property name="margin-bottom">6</property>
<property name="orientation">vertical</property>
<property name="spacing">18</property>
<child>
@@ -684,6 +699,10 @@ config: the first parameter of sstp</property>
<object class="GtkBox" id="PppPage">
<property name="visible">True</property>
<property name="can-focus">False</property>
+ <property name="margin-start">6</property>
+ <property name="margin-end">6</property>
+ <property name="margin-top">6</property>
+ <property name="margin-bottom">5</property>
<property name="orientation">vertical</property>
<property name="spacing">18</property>
<child>
@@ -1096,6 +1115,9 @@ config: unit <n></property>
</packing>
</child>
</object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
</child>
<child type="tab">
<object class="GtkLabel" id="adv_tab_label_ppp">
@@ -1112,6 +1134,10 @@ config: unit <n></property>
<object class="GtkBox" id="TlsPage">
<property name="visible">True</property>
<property name="can-focus">False</property>
+ <property name="margin-start">6</property>
+ <property name="margin-end">6</property>
+ <property name="margin-top">6</property>
+ <property name="margin-bottom">6</property>
<property name="orientation">vertical</property>
<property name="spacing">18</property>
<child>
@@ -1384,6 +1410,9 @@ or just the Common Name (CN field).
</packing>
</child>
</object>
+ <packing>
+ <property name="position">2</property>
+ </packing>
</child>
<child type="tab">
<object class="GtkLabel" id="adv_tab_label_authentication">
@@ -1400,6 +1429,10 @@ or just the Common Name (CN field).
<object class="GtkBox" id="ProxyPage">
<property name="visible">True</property>
<property name="can-focus">False</property>
+ <property name="margin-start">6</property>
+ <property name="margin-end">6</property>
+ <property name="margin-top">6</property>
+ <property name="margin-bottom">6</property>
<property name="orientation">vertical</property>
<property name="spacing">18</property>
<child>
@@ -1629,6 +1662,9 @@ or just the Common Name (CN field).
</packing>
</child>
</object>
+ <packing>
+ <property name="position">3</property>
+ </packing>
</child>
<child type="tab">
<object class="GtkLabel" id="adv_tab_label_proxy">
diff --git a/properties/nm-sstp-editor-plugin.c b/properties/nm-sstp-editor-plugin.c
index 05fe20f..b8025e9 100644
--- a/properties/nm-sstp-editor-plugin.c
+++ b/properties/nm-sstp-editor-plugin.c
@@ -155,6 +155,8 @@ get_editor (NMVpnEditorPlugin *iface, NMConnection *connection, GError **error)
gpointer gtk3_only_symbol;
GModule *self_module;
const char *editor;
+ GError *tmp_error = NULL;
+ NMVpnEditor *retval = NULL;
g_return_val_if_fail (SSTP_IS_PLUGIN_UI (iface), NULL);
g_return_val_if_fail (NM_IS_CONNECTION (connection), NULL);
@@ -171,16 +173,23 @@ get_editor (NMVpnEditorPlugin *iface, NMConnection *connection, GError **error)
}
#if ((NETWORKMANAGER_COMPILATION) & NM_NETWORKMANAGER_COMPILATION_WITH_LIBNM_UTIL)
- return nm_vpn_plugin_ui_widget_interface_new (connection, error);
+ retval = nm_vpn_plugin_ui_widget_interface_new (connection, error);
#else
- return nm_vpn_plugin_utils_load_editor (editor,
+ retval = nm_vpn_plugin_utils_load_editor (editor,
"nm_vpn_editor_factory_sstp",
_call_editor_factory,
iface,
connection,
NULL,
- error);
+ &tmp_error);
#endif
+ if (retval == NULL) {
+ if (tmp_error != NULL) {
+ g_info ("Could not load Vpn Editor Plugin \"%s\": %s", editor, tmp_error->message);
+ g_propagate_error (error, tmp_error);
+ }
+ }
+ return retval;
}
static void
diff --git a/properties/nm-sstp-editor.c b/properties/nm-sstp-editor.c
index 703a1ae..f750106 100644
--- a/properties/nm-sstp-editor.c
+++ b/properties/nm-sstp-editor.c
@@ -162,11 +162,9 @@ auth_combo_changed_cb (GtkWidget *combo, gpointer user_data)
GtkTreeModel *model;
GtkTreeIter iter;
int new_page;
- gboolean status;
model = gtk_combo_box_get_model (GTK_COMBO_BOX (combo));
- status = gtk_combo_box_get_active_iter (GTK_COMBO_BOX (combo), &iter);
- g_assert (status);
+ g_assert (gtk_combo_box_get_active_iter (GTK_COMBO_BOX (combo), &iter));
gtk_tree_model_get (model, &iter, COL_AUTH_PAGE, &new_page, -1);
priv->is_tls = new_page == 0;
@@ -568,6 +566,9 @@ init_plugin_ui (SstpPluginUiWidget *self, NMConnection *connection, GError **err
/* Authentication Combo */
widget = GTK_WIDGET (gtk_builder_get_object (priv->builder, "auth_combo"));
g_return_val_if_fail (widget != NULL, FALSE);
+
+ store = gtk_list_store_new (3, G_TYPE_STRING, G_TYPE_INT, G_TYPE_STRING);
+
if (s_vpn) {
contype = nm_setting_vpn_get_data_item (s_vpn, NM_SSTP_KEY_CONNECTION_TYPE);
if (!NM_IN_STRSET (contype, NM_SSTP_CONTYPE_TLS,
@@ -576,14 +577,16 @@ init_plugin_ui (SstpPluginUiWidget *self, NMConnection *connection, GError **err
}
/* Certificate (TLS) Tab */
- store = gtk_list_store_new (3, G_TYPE_STRING, G_TYPE_INT, G_TYPE_STRING);
+ tls_setup(self, s_vpn, stuff_changed_cb);
+
gtk_list_store_append (store, &iter);
gtk_list_store_set (store, &iter,
COL_AUTH_NAME, _("Certificates (TLS)"),
COL_AUTH_PAGE, 0,
COL_AUTH_TYPE, NM_SSTP_CONTYPE_TLS,
-1);
- tls_setup(self, s_vpn, stuff_changed_cb);
+
+ pw_setup(self, s_vpn, stuff_changed_cb);
/* Password Tab */
gtk_list_store_append (store, &iter);
@@ -592,7 +595,6 @@ init_plugin_ui (SstpPluginUiWidget *self, NMConnection *connection, GError **err
COL_AUTH_PAGE, 1,
COL_AUTH_TYPE, NM_SSTP_CONTYPE_PASSWORD,
-1);
- pw_setup(self, s_vpn, stuff_changed_cb);
if (active < 0
&& nm_streq (contype, NM_SSTP_CONTYPE_PASSWORD)) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]