[network-manager-applet/dcbw/dcb: 2/4] editor: re-add ce_spin_output_with_default()
- From: Dan Williams <dcbw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet/dcbw/dcb: 2/4] editor: re-add ce_spin_output_with_default()
- Date: Fri, 20 Dec 2013 15:57:59 +0000 (UTC)
commit 364cfeb0b6c54aabe5a2ba26e1f8e35b46e74f25
Author: Dan Williams <dcbw redhat com>
Date: Thu Oct 10 11:28:54 2013 -0500
editor: re-add ce_spin_output_with_default()
This time, it prints "default" in the spin button instead of "automatic"
when the spin holds the default value.
src/connection-editor/ce-page.c | 8 ++++++++
src/connection-editor/ce-page.h | 2 ++
2 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/src/connection-editor/ce-page.c b/src/connection-editor/ce-page.c
index 0e01023..c63a752 100644
--- a/src/connection-editor/ce-page.c
+++ b/src/connection-editor/ce-page.c
@@ -84,6 +84,14 @@ ce_spin_output_with_automatic (GtkSpinButton *spin, gpointer user_data)
_("automatic"));
}
+gboolean
+ce_spin_output_with_default (GtkSpinButton *spin, gpointer user_data)
+{
+ return spin_output_with_default_string (spin,
+ GPOINTER_TO_INT (user_data),
+ _("default"));
+}
+
int
ce_get_property_default (NMSetting *setting, const char *property_name)
{
diff --git a/src/connection-editor/ce-page.h b/src/connection-editor/ce-page.h
index 794d20d..9d53320 100644
--- a/src/connection-editor/ce-page.h
+++ b/src/connection-editor/ce-page.h
@@ -120,6 +120,8 @@ GByteArray *ce_page_entry_to_mac (GtkEntry *entry, int type, gboolean *invalid);
gboolean ce_spin_output_with_automatic (GtkSpinButton *spin, gpointer user_data);
+gboolean ce_spin_output_with_default (GtkSpinButton *spin, gpointer user_data);
+
int ce_get_property_default (NMSetting *setting, const char *property_name);
void ce_page_complete_init (CEPage *self,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]