Added chat buffer count in the preferences dialog
This commit is contained in:
parent
5b3a013766
commit
33ab63c1bc
@ -6,6 +6,7 @@
|
|||||||
|
|
||||||
* when selecting multiple audio files in audio buffers, multiple actions can be performed in all items, these actions are present in the contextual menu of the buffer (namely play, add/remove from the library and move to a different playlist). This means you can select all the audios you want and Socializer will perform the selected options in all items, making it a bit easier to operate with multiple songs.
|
* when selecting multiple audio files in audio buffers, multiple actions can be performed in all items, these actions are present in the contextual menu of the buffer (namely play, add/remove from the library and move to a different playlist). This means you can select all the audios you want and Socializer will perform the selected options in all items, making it a bit easier to operate with multiple songs.
|
||||||
* Now it is possible to like and see who liked a comment when displaying it individually. This applies to comments in wall posts and topics.
|
* Now it is possible to like and see who liked a comment when displaying it individually. This applies to comments in wall posts and topics.
|
||||||
|
* Now it is possible to choose how many items Socializer will load in conversation buffers, from the General tab in the preferences dialog. The default value is 50 items, and the maximum value is 200.
|
||||||
|
|
||||||
### bugfixes
|
### bugfixes
|
||||||
|
|
||||||
|
@ -416,7 +416,7 @@ class Controller(object):
|
|||||||
elif user_id > 2000000000:
|
elif user_id > 2000000000:
|
||||||
chat = self.session.vk.client.messages.getChat(chat_id=user_id-2000000000)
|
chat = self.session.vk.client.messages.getChat(chat_id=user_id-2000000000)
|
||||||
name = chat["title"]
|
name = chat["title"]
|
||||||
pub.sendMessage("create_buffer", buffer_type="chatBuffer", buffer_title=name, parent_tab="chats", get_items=True, kwargs=dict(parent=self.window.tb, name="{0}_messages".format(user_id,), composefunc="render_message", parent_endpoint="messages", endpoint="getHistory", session=self.session, unread=unread, count=200, peer_id=user_id, rev=0, extended=True, fields="id, user_id, date, read_state, out, body, attachments, deleted"))
|
pub.sendMessage("create_buffer", buffer_type="chatBuffer", buffer_title=name, parent_tab="chats", get_items=True, kwargs=dict(parent=self.window.tb, name="{0}_messages".format(user_id,), composefunc="render_message", parent_endpoint="messages", endpoint="getHistory", session=self.session, unread=unread, count=self.session.settings["buffers"]["count_for_chat_buffers"], peer_id=user_id, rev=0, extended=True, fields="id, user_id, date, read_state, out, body, attachments, deleted"))
|
||||||
# if setfocus:
|
# if setfocus:
|
||||||
# pos = self.window.search(buffer.name)
|
# pos = self.window.search(buffer.name)
|
||||||
# self.window.change_buffer(pos)
|
# self.window.change_buffer(pos)
|
||||||
|
@ -44,6 +44,7 @@ class configurationInteractor(base.baseInteractor):
|
|||||||
def on_save_settings(self, *args, **kwargs):
|
def on_save_settings(self, *args, **kwargs):
|
||||||
self.presenter.update_setting(section="buffers", setting="count_for_wall_buffers", value=self.view.get_value("general", "wall_buffer_count"))
|
self.presenter.update_setting(section="buffers", setting="count_for_wall_buffers", value=self.view.get_value("general", "wall_buffer_count"))
|
||||||
self.presenter.update_setting(section="buffers", setting="count_for_video_buffers", value=self.view.get_value("general", "video_buffers_count"))
|
self.presenter.update_setting(section="buffers", setting="count_for_video_buffers", value=self.view.get_value("general", "video_buffers_count"))
|
||||||
|
self.presenter.update_setting(section="buffers", setting="count_for_chat_buffers", value=self.view.get_value("general", "chat_buffers_count"))
|
||||||
self.presenter.update_setting(section="general", setting="load_images", value=self.view.get_value("general", "load_images"))
|
self.presenter.update_setting(section="general", setting="load_images", value=self.view.get_value("general", "load_images"))
|
||||||
update_channel = self.presenter.get_update_channel_type(self.view.get_value("general", "update_channel"))
|
update_channel = self.presenter.get_update_channel_type(self.view.get_value("general", "update_channel"))
|
||||||
if update_channel != self.presenter.session.settings["general"]["update_channel"]:
|
if update_channel != self.presenter.session.settings["general"]["update_channel"]:
|
||||||
|
@ -53,6 +53,7 @@ class configurationPresenter(base.basePresenter):
|
|||||||
self.send_message("set_language", language=id)
|
self.send_message("set_language", language=id)
|
||||||
self.send_message("set", tab="general", setting="wall_buffer_count", value=self.session.settings["buffers"]["count_for_wall_buffers"])
|
self.send_message("set", tab="general", setting="wall_buffer_count", value=self.session.settings["buffers"]["count_for_wall_buffers"])
|
||||||
self.send_message("set", tab="general", setting="video_buffers_count", value=self.session.settings["buffers"]["count_for_video_buffers"])
|
self.send_message("set", tab="general", setting="video_buffers_count", value=self.session.settings["buffers"]["count_for_video_buffers"])
|
||||||
|
self.send_message("set", tab="general", setting="chat_buffers_count", value=self.session.settings["buffers"]["count_for_chat_buffers"])
|
||||||
self.send_message("set", tab="general", setting="load_images", value=self.session.settings["general"]["load_images"])
|
self.send_message("set", tab="general", setting="load_images", value=self.session.settings["general"]["load_images"])
|
||||||
self.send_message("set", tab="general", setting="use_proxy", value=config.app["app-settings"]["use_proxy"])
|
self.send_message("set", tab="general", setting="use_proxy", value=config.app["app-settings"]["use_proxy"])
|
||||||
self.send_message("set", tab="general", setting="update_channel", value=self.get_update_channel_label(self.session.settings["general"]["update_channel"]))
|
self.send_message("set", tab="general", setting="update_channel", value=self.get_update_channel_label(self.session.settings["general"]["update_channel"]))
|
||||||
|
@ -13,9 +13,10 @@ load_images = boolean(default=True)
|
|||||||
update_channel = string(default="stable")
|
update_channel = string(default="stable")
|
||||||
|
|
||||||
[buffers]
|
[buffers]
|
||||||
count_for_wall_buffers = integer(default=100)
|
count_for_wall_buffers = integer(default=50)
|
||||||
count_for_video_buffers = integer(default=200)
|
count_for_video_buffers = integer(default=50)
|
||||||
count_for_audio_buffers = integer(default=1000)
|
count_for_audio_buffers = integer(default=1000)
|
||||||
|
count_for_chat_buffers = integer(default=50)
|
||||||
|
|
||||||
[chat]
|
[chat]
|
||||||
notify_online = boolean(default=True)
|
notify_online = boolean(default=True)
|
||||||
|
@ -26,6 +26,13 @@ class general(wx.Panel, widgetUtils.BaseDialog):
|
|||||||
box3.Add(lbl3, 0, wx.ALL, 5)
|
box3.Add(lbl3, 0, wx.ALL, 5)
|
||||||
box3.Add(self.video_buffers_count, 0, wx.ALL, 5)
|
box3.Add(self.video_buffers_count, 0, wx.ALL, 5)
|
||||||
sizer.Add(box3, 0, wx.ALL, 5)
|
sizer.Add(box3, 0, wx.ALL, 5)
|
||||||
|
lbl4 = wx.StaticText(self, wx.NewId(), _("Number of items to load in conversation buffers (maximun 200)"))
|
||||||
|
self.chat_buffers_count = wx.SpinCtrl(self, wx.NewId())
|
||||||
|
self.chat_buffers_count.SetRange(1, 200)
|
||||||
|
box4 = wx.BoxSizer(wx.HORIZONTAL)
|
||||||
|
box4.Add(lbl4, 0, wx.ALL, 5)
|
||||||
|
box4.Add(self.chat_buffers_count, 0, wx.ALL, 5)
|
||||||
|
sizer.Add(box4, 0, wx.ALL, 5)
|
||||||
self.load_images = wx.CheckBox(self, wx.NewId(), _("Load images in posts"))
|
self.load_images = wx.CheckBox(self, wx.NewId(), _("Load images in posts"))
|
||||||
sizer.Add(self.load_images, 0, wx.ALL, 5)
|
sizer.Add(self.load_images, 0, wx.ALL, 5)
|
||||||
self.use_proxy = wx.CheckBox(self, wx.NewId(), _("Use proxy"))
|
self.use_proxy = wx.CheckBox(self, wx.NewId(), _("Use proxy"))
|
||||||
|
Loading…
Reference in New Issue
Block a user