9373: Values not saved and bug in monitoredwidgets
This commit is contained in:
parent
b6bb8ccdcc
commit
6b38e74ecb
@ -186,6 +186,8 @@ class EditPlace(EditPrimary):
|
|||||||
self.latitude.set_text(value[:coma])
|
self.latitude.set_text(value[:coma])
|
||||||
self.top.get_object("lat_entry").validate(force=True)
|
self.top.get_object("lat_entry").validate(force=True)
|
||||||
self.top.get_object("lon_entry").validate(force=True)
|
self.top.get_object("lon_entry").validate(force=True)
|
||||||
|
self.obj.set_latitude(self.latitude.get_value())
|
||||||
|
self.obj.set_longitude(self.longitude.get_value())
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
@ -297,7 +299,6 @@ class EditPlace(EditPrimary):
|
|||||||
|
|
||||||
def save(self, *obj):
|
def save(self, *obj):
|
||||||
self.ok_button.set_sensitive(False)
|
self.ok_button.set_sensitive(False)
|
||||||
|
|
||||||
if self.obj.get_name().get_value().strip() == '':
|
if self.obj.get_name().get_value().strip() == '':
|
||||||
msg1 = _("Cannot save place. Name not entered.")
|
msg1 = _("Cannot save place. Name not entered.")
|
||||||
msg2 = _("You must enter a name before saving.")
|
msg2 = _("You must enter a name before saving.")
|
||||||
|
@ -179,6 +179,8 @@ class EditPlaceRef(EditReference):
|
|||||||
self.latitude.set_text(value[:coma])
|
self.latitude.set_text(value[:coma])
|
||||||
self.top.get_object("lat_entry").validate(force=True)
|
self.top.get_object("lat_entry").validate(force=True)
|
||||||
self.top.get_object("lon_entry").validate(force=True)
|
self.top.get_object("lon_entry").validate(force=True)
|
||||||
|
self.obj.set_latitude(self.latitude.get_value())
|
||||||
|
self.obj.set_longitude(self.longitude.get_value())
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
@ -144,7 +144,7 @@ class MonitoredEntry:
|
|||||||
def force_value(self, value):
|
def force_value(self, value):
|
||||||
self.obj.set_text(value)
|
self.obj.set_text(value)
|
||||||
|
|
||||||
def get_value(self, value):
|
def get_value(self):
|
||||||
return str(self.obj.get_text())
|
return str(self.obj.get_text())
|
||||||
|
|
||||||
def enable(self, value):
|
def enable(self, value):
|
||||||
|
Loading…
Reference in New Issue
Block a user