From 72348008a2011e487e939421023f5507c6d76c3f Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Mon, 3 Sep 2018 08:33:05 -0500 Subject: [PATCH] More WX Python 4 changes --- src/controller/buffers.py | 4 ++-- src/controller/posts.py | 2 +- src/wxUI/dialogs/postDialogs.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/controller/buffers.py b/src/controller/buffers.py index 937b341..20b057f 100644 --- a/src/controller/buffers.py +++ b/src/controller/buffers.py @@ -301,7 +301,7 @@ class baseBuffer(object): post = self.get_post() original_date = arrow.get(post["date"]) created_at = original_date.humanize(locale=languageHandler.getLanguage()) - self.tab.list.list.SetStringItem(self.tab.list.get_selected(), 2, created_at) + self.tab.list.list.SetItem(self.tab.list.get_selected(), 2, created_at) class feedBuffer(baseBuffer): """ This buffer represents an user's wall. It may be used either for the current user or someone else.""" @@ -760,7 +760,7 @@ class peopleBuffer(feedBuffer): if post.has_key("last_seen") == False: return original_date = arrow.get(post["last_seen"]["time"]) created_at = original_date.humanize(locale=languageHandler.getLanguage()) - self.tab.list.list.SetStringItem(self.tab.list.get_selected(), 1, created_at) + self.tab.list.list.SetItem(self.tab.list.get_selected(), 1, created_at) def open_timeline(self, *args, **kwargs): pass diff --git a/src/controller/posts.py b/src/controller/posts.py index 7b19512..eb887aa 100644 --- a/src/controller/posts.py +++ b/src/controller/posts.py @@ -29,7 +29,7 @@ def get_user(id, profiles): for i in profiles: if i["id"] == id: return u"{0} {1}".format(i["first_name"], i["last_name"]) - # Translators: This string is user when socializer can't find the right user information. + # Translators: This string is used when socializer can't find the right user information. return _(u"Unknown username") def get_message(status): diff --git a/src/wxUI/dialogs/postDialogs.py b/src/wxUI/dialogs/postDialogs.py index 1d3df00..ca0ba55 100644 --- a/src/wxUI/dialogs/postDialogs.py +++ b/src/wxUI/dialogs/postDialogs.py @@ -37,7 +37,7 @@ class basicPost(widgetUtils.BaseDialog): return box def create_photo_viewer(self): - self.image = wx.StaticBitmap(self.panel, bitmap=wx.EmptyBitmap(1280, 860), size=(604, 604)) + self.image = wx.StaticBitmap(self.panel, bitmap=wx.Bitmap(1280, 860), size=(604, 604)) self.sizer.Add(self.image, 1, wx.ALL, 10) self.previous_photo = wx.Button(self.panel, wx.NewId(), _(u"Previous photo")) self.view_photo = wx.Button(self.panel, wx.NewId(), _(u"View in full screen"))