Added actions in community buffers from context menu in the treebook

This commit is contained in:
2019-01-30 15:32:46 -06:00
parent a6565aae53
commit 150f9d6c08
5 changed files with 131 additions and 10 deletions

View File

@@ -57,4 +57,7 @@ def post_deleted():
return wx.MessageDialog(None, _("This post has been removed."), _("Error"), wx.ICON_ERROR).ShowModal()
def restart_program():
return wx.MessageDialog(None, _("In order to apply the changes you requested, you must restart the program. Do you want to restart Socializer now?"), _("Attention"), style=wx.ICON_QUESTION|wx.YES_NO).ShowModal()
return wx.MessageDialog(None, _("In order to apply the changes you requested, you must restart the program. Do you want to restart Socializer now?"), _("Attention"), style=wx.ICON_QUESTION|wx.YES_NO).ShowModal()
def community_no_items():
return wx.MessageDialog(None, _("There are 0 items for this community."), _("Error"), wx.ICON_ERROR).ShowModal()

View File

@@ -100,4 +100,15 @@ class attachMenu(wx.Menu):
self.upload = wx.MenuItem(self, wx.NewId(), _("Upload from computer"))
self.Append(self.upload)
self.add = wx.MenuItem(self, wx.NewId(), _("Add from VK"))
self.Append(self.add)
self.Append(self.add)
class communityBufferMenu(wx.Menu):
def __init__(self):
super(communityBufferMenu, self).__init__()
load = wx.Menu()
self.load_posts = load.Append(wx.NewId(), _("Load posts"))
self.load_topics = load.Append(wx.NewId(), _("Load topics"))
self.load_topics.Enable(False)
self.load_audios = load.Append(wx.NewId(), _("Load audios"))
self.load_videos = load.Append(wx.NewId(), _("Load videos"))
self.Append(wx.NewId(), _("Load"), load)