2016-02-13 17:06:36 -06:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
import wx
|
|
|
|
|
|
|
|
class postMenu(wx.Menu):
|
|
|
|
def __init__(self, *args, **kwargs):
|
|
|
|
super(postMenu, self).__init__(*args, **kwargs)
|
|
|
|
self.open = wx.MenuItem(self, wx.NewId(), _(u"Open"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.open)
|
2016-02-13 17:06:36 -06:00
|
|
|
self.like = wx.MenuItem(self, wx.NewId(), _(u"Like"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.like)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.dislike = wx.MenuItem(self, wx.NewId(), _(u"Dislike"))
|
|
|
|
self.dislike.Enable(False)
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.dislike)
|
2016-02-13 17:06:36 -06:00
|
|
|
self.comment = wx.MenuItem(self, wx.NewId(), _(u"Add comment"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.comment)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.post_in_wall = wx.MenuItem(self, wx.NewId(), _(u"Post to this profile"))
|
2016-02-13 17:06:36 -06:00
|
|
|
self.post_in_wall.Enable(False)
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.post_in_wall)
|
2016-09-20 10:33:20 -05:00
|
|
|
self.view_profile = wx.MenuItem(self, wx.NewId(), _(u"View user profile"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.view_profile)
|
2016-02-13 17:06:36 -06:00
|
|
|
|
|
|
|
def create_specific_post_options(self):
|
|
|
|
self.update = wx.MenuItem(self, wx.NewId(), _(u"Update"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.update)
|
2016-02-13 17:06:36 -06:00
|
|
|
self.delete = wx.MenuItem(self, wx.NewId(), _(u"Delete"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.delete)
|
2016-02-13 17:06:36 -06:00
|
|
|
|
2016-06-08 05:45:03 -05:00
|
|
|
class audioMenu(wx.Menu):
|
|
|
|
|
|
|
|
def __init__(self, *args, **kwargs):
|
|
|
|
super(audioMenu, self).__init__(*args, **kwargs)
|
|
|
|
self.open = wx.MenuItem(self, wx.NewId(), _(u"&Open"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.open)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.play = wx.MenuItem(self, wx.NewId(), _(u"&Play"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.play)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.library = wx.MenuItem(self, wx.NewId(), _(u"&Add to library"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.library)
|
2016-06-19 12:54:38 -05:00
|
|
|
self.move = wx.MenuItem(self, wx.NewId(), _(u"Move to album"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.move)
|
2016-06-08 05:45:03 -05:00
|
|
|
|
|
|
|
class peopleMenu(wx.Menu):
|
2018-12-10 17:35:36 -06:00
|
|
|
def __init__(self, is_request=False, *args, **kwargs):
|
2016-06-08 05:45:03 -05:00
|
|
|
super(peopleMenu, self).__init__(*args, **kwargs)
|
2018-12-10 17:35:36 -06:00
|
|
|
if is_request:
|
|
|
|
self.create_extra_items()
|
2016-06-08 05:45:03 -05:00
|
|
|
self.view_profile = wx.MenuItem(self, wx.NewId(), _(u"View profile"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.view_profile)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.message = wx.MenuItem(self, wx.NewId(), _(u"Send a message"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.message)
|
2016-06-08 05:45:03 -05:00
|
|
|
self.timeline = wx.MenuItem(self, wx.NewId(), _(u"Open timeline"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.timeline)
|
2018-12-10 17:35:36 -06:00
|
|
|
self.common_friends = wx.MenuItem(self, wx.NewId(), _(u"View friends in common"))
|
|
|
|
self.Append(self.common_friends)
|
|
|
|
|
|
|
|
def create_extra_items(self):
|
|
|
|
self.accept = wx.MenuItem(self, wx.NewId(), _(u"Accept"))
|
|
|
|
self.Append(self.accept)
|
|
|
|
self.decline = wx.MenuItem(self, wx.NewId(), _(u"Decline"))
|
|
|
|
self.Append(self.decline)
|
2016-06-08 05:45:03 -05:00
|
|
|
|
2016-02-13 17:06:36 -06:00
|
|
|
class commentMenu(wx.Menu):
|
|
|
|
def __init__(self, *args, **kwargs):
|
|
|
|
super(commentMenu, self).__init__(*args, **kwargs)
|
|
|
|
self.open = wx.MenuItem(self, wx.NewId(), _(u"Open"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.open)
|
2016-02-13 17:06:36 -06:00
|
|
|
self.like = wx.MenuItem(self, wx.NewId(), _(u"Like"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.like)
|
2016-02-13 17:06:36 -06:00
|
|
|
self.unlike = wx.MenuItem(self, -1, _(u"Unlike"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.unlike)
|
2016-02-13 17:06:36 -06:00
|
|
|
|
|
|
|
def create_specific_comment_options(self):
|
|
|
|
self.delete = wx.MenuItem(self, wx.NewId(), _(u"Delete"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.delete)
|
2016-02-13 17:06:36 -06:00
|
|
|
|
|
|
|
class notificationsMenu(wx.Menu):
|
|
|
|
def __init__(self):
|
|
|
|
super(notificationsMenu, self).__init__()
|
|
|
|
self.mark_as_read = wx.MenuItem(self, wx.NewId(), _(u"Mark as read"))
|
2018-09-03 13:22:54 -05:00
|
|
|
self.Append(self.mark_as_read)
|