[Phonehome-commits] r30 - trunk/frontend/src
pamadio at garage.maemo.org
pamadio at garage.maemo.org
Wed Oct 15 20:50:57 EEST 2008
Author: pamadio
Date: 2008-10-15 20:50:57 +0300 (Wed, 15 Oct 2008)
New Revision: 30
Modified:
trunk/frontend/src/phonehome-gui
Log:
filling the form
Modified: trunk/frontend/src/phonehome-gui
===================================================================
--- trunk/frontend/src/phonehome-gui 2008-10-15 17:23:10 UTC (rev 29)
+++ trunk/frontend/src/phonehome-gui 2008-10-15 17:50:57 UTC (rev 30)
@@ -33,7 +33,8 @@
self.hildon_window = hildon.Window()
self.osso_context = osso.Context("org.maemo.phonehomegui", "0.0.1", False)
self.osso_rpc=osso.Rpc(self.osso_context)
-
+ self.gconf_default=gconf.client_get_default()
+ self.gconf_root="/apps/osso/phonehome"
gladefile="/usr/share/phonehome-gui/data/phonehome-gui.glade"
self.hildon_window.connect("destroy",self.end_application)
@@ -52,6 +53,7 @@
self.server_label=self.main_xml.get_widget("server_label")
self.tid_entry=self.main_xml.get_widget("tabletid_entry")
self.password_entry=self.main_xml.get_widget("password_entry")
+ self.password_entry.set_visibility(False)
self.server_entry=self.main_xml.get_widget("server_entry")
self.ok_button.set_label(_("OK"))
@@ -59,7 +61,17 @@
self.password_label.set_label(_("Password"))
self.tid_label.set_label(_("Tablet id"))
self.server_label.set_label(_("Server"))
-
+
+ if(self.gconf_default.get_string(self.gconf_root+"/id")):
+ self.tid_entry.set_text(self.gconf_default.get_string(self.gconf_root+"/id"))
+
+ if(self.gconf_default.get_string(self.gconf_root+"/password")):
+ self.password_entry.set_text(self.gconf_default.get_string(self.gconf_root+"/password"))
+
+ if(self.gconf_default.get_string(self.gconf_root+"/id")):
+ self.server_entry.set_text(self.gconf_default.get_string(self.gconf_root+"/server"))
+
+
self.hildon_window.show_all()
gtk.main()
More information about the Phonehome-commits
mailing list