diff --git a/src/app-configuration.defaults b/src/app-configuration.defaults index e7c04601..be0356b8 100644 --- a/src/app-configuration.defaults +++ b/src/app-configuration.defaults @@ -15,6 +15,7 @@ log_level = string(default="error") use_slow_audio_algo = boolean(default=False) load_keymap = string(default="default.keymap") use_Codeofdusk_audio_handlers=boolean(default=True) +view_reverse_geocode_on_secondary = boolean(default=False) [proxy] server = string(default="") port = string(default="") diff --git a/src/controller/mainController.py b/src/controller/mainController.py index d1c85069..279ff092 100644 --- a/src/controller/mainController.py +++ b/src/controller/mainController.py @@ -1042,6 +1042,7 @@ class Controller(object): def secondary_interact(self): buffer = self.get_current_buffer() + tweet=buffer.get_tweet() if utils.is_geocoded(tweet) and config.app['app-settings']['use_Codeofdusk_audio_handlers']: return self.view_reverse_geocode() elif config.app['app-settings']['use_Codeofdusk_audio_handlers']: diff --git a/src/controller/settings.py b/src/controller/settings.py index bbe7425b..a109dc7e 100644 --- a/src/controller/settings.py +++ b/src/controller/settings.py @@ -62,6 +62,7 @@ class globalSettingsController(object): self.dialog.set_value("general", "hide_gui", config.app["app-settings"]["hide_gui"]) self.dialog.set_value("general", "use_slow_audio_algo", config.app["app-settings"]["use_slow_audio_algo"]) self.dialog.set_value("general", "use_Codeofdusk_audio_handlers", config.app["app-settings"]["use_Codeofdusk_audio_handlers"]) + self.dialog.set_value("general", "view_reverse_geocode_on_secondary", config.app["app-settings"]["view_reverse_geocode_on_secondary"]) self.dialog.create_proxy() self.dialog.set_value("proxy", "server", config.app["proxy"]["server"]) self.dialog.set_value("proxy", "port", config.app["proxy"]["port"]) @@ -92,6 +93,8 @@ class globalSettingsController(object): #Todo: clean memmos. if config.app["app-settings"]["use_Codeofdusk_audio_handlers"] != self.dialog.get_value("general", "use_Codeofdusk_audio_handlers"): config.app["app-settings"]["use_Codeofdusk_audio_handlers"] = self.dialog.get_value("general", "use_Codeofdusk_audio_handlers") + if config.app["app-settings"]["view_reverse_geocode_on_secondary"] != self.dialog.get_value("general", "view_reverse_geocode_on_secondary"): + config.app["app-settings"]["view_reverse_geocode_on_secondary"] = self.dialog.get_value("general", "view_reverse_geocode_on_secondary") if config.app["proxy"]["server"] != self.dialog.get_value("proxy", "server") or config.app["proxy"]["port"] != self.dialog.get_value("proxy", "port") or config.app["proxy"]["user"] != self.dialog.get_value("proxy", "user") or config.app["proxy"]["password"] != self.dialog.get_value("proxy", "password"): if self.is_started == True: self.needs_restart = True diff --git a/src/wxUI/dialogs/configuration.py b/src/wxUI/dialogs/configuration.py index b62c0807..9fb2cd8c 100644 --- a/src/wxUI/dialogs/configuration.py +++ b/src/wxUI/dialogs/configuration.py @@ -38,6 +38,8 @@ class general(wx.Panel, baseDialog.BaseWXDialog): sizer.Add(kmbox, 0, wx.ALL, 5) self.use_slow_audio_algo= wx.CheckBox(self, -1, _(U"Use slow audio tweet detection algorithm (improves audio tweet detection accuracy at the cost of performance)")) sizer.Add(self.use_slow_audio_algo, 0, wx.ALL, 5) + self.view_reverse_geocode_on_secondary= wx.CheckBox(self, -1, _(U"Display geolocation information in a text box instead of opening URL as secondary action for geotweets")) + sizer.Add(self.view_reverse_geocode_on_secondary, 0, wx.ALL, 5) self.use_Codeofdusk_audio_handlers= wx.CheckBox(self, -1, _(U"Use Codeofdusk's tweet interaction handlers (intelegently handle audio tweets, may impact client performance on very slow connections)")) sizer.Add(self.use_Codeofdusk_audio_handlers, 0, wx.ALL, 5) self.SetSizer(sizer)