[glibmm] Revert changes that I did not mean to commit yet.



commit 05860f7e98cf4a7a7255c8a0b76a5e35269d45dc
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu Jul 22 22:15:36 2010 +0200

    Revert changes that I did not mean to commit yet.

 examples/settings/settings.cc |    9 +--------
 gio/src/settings.ccg          |   10 ----------
 gio/src/settings.hg           |    6 +-----
 3 files changed, 2 insertions(+), 23 deletions(-)
---
diff --git a/examples/settings/settings.cc b/examples/settings/settings.cc
index b7d6228..7bda8e2 100644
--- a/examples/settings/settings.cc
+++ b/examples/settings/settings.cc
@@ -32,14 +32,7 @@ static void on_key_changed(const Glib::ustring& key, const Glib::RefPtr<Gio::Set
   {
     Glib::ustring str = settings->get_string(key);
     std::cout << Glib::ustring::compose("New value of '%1': '%2'\n",
-                      key, str);
-                      
-    //Or:
-    Glib::Variant<Glib::ustring> variant = settings->get_value(key);
-    str = variant.get();
-    std::cout << Glib::ustring::compose("New value, via Variant, of '%1': '%2'\n",
-                      key, str);
-    
+                      key, str);    
   }
   else if (key.raw() == INT_KEY)
   {
diff --git a/gio/src/settings.ccg b/gio/src/settings.ccg
index de32cd9..342b70f 100644
--- a/gio/src/settings.ccg
+++ b/gio/src/settings.ccg
@@ -3,16 +3,6 @@
 namespace Gio
 {
 
-void Settings::get_value(const Glib::ustring& key, Glib::VariantBase& value)
-{
-  GVariant* const g_value = g_settings_get_value(gobj(), key.c_str());
-  if(!g_value)
-    return;
-  
-  g_value_copy(
-  value.init(g_value);
-}
-
 void Settings::bind(const Glib::ustring& key,
                     const Glib::PropertyProxy_Base& property_proxy,
                     SettingsBindFlags flags)
diff --git a/gio/src/settings.hg b/gio/src/settings.hg
index d06b55a..9b3e457 100644
--- a/gio/src/settings.hg
+++ b/gio/src/settings.hg
@@ -53,11 +53,7 @@ public:
   // FIXME: implement the GVariant stuff
 
   _WRAP_METHOD(bool set_value(const Glib::ustring& key, const Glib::VariantBase& value),  g_settings_set_value)
-  
-  /** TODO: Documentation.
-   */
-  void get_value(const Glib::ustring& key, Glib::VariantBase& value);
-  _IGNORE(g_settings_get_value);
+  _WRAP_METHOD(Glib::VariantBase get_value(const Glib::ustring& key), g_settings_get_value)
 
   _WRAP_METHOD(int get_int(const Glib::ustring& key) const, g_settings_get_int)
   _WRAP_METHOD(void set_int(const Glib::ustring& key, int value), g_settings_set_int)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]