preparation for new hildon (desktop and widgets) support
[simple-launcher] / gconf-wrapper.cc
index 37a573e..44bd35e 100644 (file)
@@ -94,12 +94,12 @@ void GConfOption::unsetGConfValue() {
   }
 }
 
-GConfStringValue::GConfStringValue(const GConfKey& key, const std::string& name, const std::string& defaultValue):
-  GConfOption(GCONF_VALUE_STRING, key, name),
+GConfStringOption::GConfStringOption(const GConfKey& key, const std::string& name, const std::string& defaultValue):
+  GConfOption(key, name),
   myDefaultValue(defaultValue) {
 }
 
-const std::string& GConfStringValue::value() const {
+const std::string& GConfStringOption::value() const {
   if (!myIsSynchronized) {
     GConfValue *value = getGConfValue();
 
@@ -117,7 +117,7 @@ const std::string& GConfStringValue::value() const {
   return myValue;
 }
 
-const std::string& GConfStringValue::setValue(const std::string& newValue) {
+const std::string& GConfStringOption::setValue(const std::string& newValue) {
   if (!myIsSynchronized || (myValue != newValue)) {
     myValue = newValue;
 
@@ -139,12 +139,13 @@ const std::string& GConfStringValue::setValue(const std::string& newValue) {
   return myValue;
 }
 
-GConfBooleanValue::GConfBooleanValue(const GConfKey& key, const std::string& name, bool defaultValue):
-  GConfOption(GCONF_VALUE_BOOL, key, name),
+GConfBooleanOption::GConfBooleanOption(const GConfKey& key, const std::string& name, bool defaultValue):
+  GConfOption(key, name),
+  myValue(defaultValue),
   myDefaultValue(defaultValue) {
 }
 
-bool GConfBooleanValue::value() const {
+bool GConfBooleanOption::value() const {
   if (!myIsSynchronized) {
     GConfValue *value = getGConfValue();
 
@@ -162,7 +163,7 @@ bool GConfBooleanValue::value() const {
   return myValue;
 }
 
-bool GConfBooleanValue::setValue(bool newValue) {
+bool GConfBooleanOption::setValue(bool newValue) {
   if (!myIsSynchronized || (myValue != newValue)) {
     myValue = newValue;
 
@@ -184,12 +185,13 @@ bool GConfBooleanValue::setValue(bool newValue) {
   return myValue;
 }
 
-GConfIntegerValue::GConfIntegerValue(const GConfKey& key, const std::string& name, int defaultValue):
-  GConfOption(GCONF_VALUE_INT, key, name),
+GConfIntegerOption::GConfIntegerOption(const GConfKey& key, const std::string& name, int defaultValue):
+  GConfOption(key, name),
+  myValue(defaultValue),
   myDefaultValue(defaultValue) {
 }
 
-int GConfIntegerValue::value() const {
+int GConfIntegerOption::value() const {
   if (!myIsSynchronized) {
     GConfValue *value = getGConfValue();
 
@@ -207,7 +209,7 @@ int GConfIntegerValue::value() const {
   return myValue;
 }
 
-int GConfIntegerValue::setValue(int newValue) {
+int GConfIntegerOption::setValue(int newValue) {
   if (!myIsSynchronized || (myValue != newValue)) {
     myValue = newValue;