mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2025-07-18 14:06:07 -04:00
Updated reply dialog with some changes in add menu
This commit is contained in:
@@ -408,8 +408,8 @@ class BaseBuffer(base.Buffer):
|
||||
if len(users) > 0:
|
||||
config.app["app-settings"]["mention_all"] = message.message.mention_all.GetValue()
|
||||
config.app.write()
|
||||
tweet_data = dict(text=message.message.text.GetValue(), attachments=message.attachments)
|
||||
call_threaded(self.session.reply, in_reply_to_status_id=id, text=message.message.text.GetValue(), attachments=message.attachments, exclude_reply_user_ids=message.get_ids(), auto_populate_reply_metadata=True)
|
||||
tweet_data = dict(text=message.message.text.GetValue(), attachments=message.attachments, poll_options=message.poll_options, poll_period=message.poll_period)
|
||||
call_threaded(self.session.reply, in_reply_to_status_id=id, text=message.message.text.GetValue(), attachments=message.attachments, exclude_reply_user_ids=message.get_ids())
|
||||
if hasattr(message.message, "destroy"): message.message.destroy()
|
||||
self.session.settings.write()
|
||||
|
||||
|
@@ -92,8 +92,8 @@ class DirectMessagesBuffer(base.BaseBuffer):
|
||||
screen_name = self.session.get_user(tweet.message_create["sender_id"]).screen_name
|
||||
message = messages.reply(session=self.session, title=_("Mention"), caption=_("Mention to %s") % (screen_name,), text="@%s " % (screen_name,), thread_mode=False, users=[screen_name,])
|
||||
if message.message.ShowModal() == widgetUtils.OK:
|
||||
tweet_data = dict(text=message.message.text.GetValue(), attachments=message.attachments)
|
||||
call_threaded(self.session.send_tweet, *[tweet_data])
|
||||
tweet_data = message.get_tweet_data()
|
||||
call_threaded(self.session.send_tweet, tweet_data)
|
||||
if hasattr(message.message, "destroy"):
|
||||
message.message.destroy()
|
||||
|
||||
|
@@ -94,8 +94,8 @@ class PeopleBuffer(base.BaseBuffer):
|
||||
screen_name = tweet.screen_name
|
||||
message = messages.tweet(session=self.session, title=_("Mention"), caption=_("Mention to %s") % (screen_name,), text="@%s " % (screen_name,), thread_mode=False)
|
||||
if message.message.ShowModal() == widgetUtils.OK:
|
||||
tweet_data = dict(text=message.message.text.GetValue(), attachments=message.attachments)
|
||||
call_threaded(self.session.send_tweet, *[tweet_data])
|
||||
tweet_data = message.get_tweet_data()
|
||||
call_threaded(self.session.send_tweet, tweet_data)
|
||||
if hasattr(message.message, "destroy"):
|
||||
message.message.destroy()
|
||||
|
||||
|
@@ -131,21 +131,13 @@ class TrendsBuffer(base.Buffer):
|
||||
|
||||
def tweet_about_this_trend(self, *args, **kwargs):
|
||||
if self.buffer.list.get_count() == 0: return
|
||||
title = _(u"Tweet")
|
||||
caption = _(u"Write the tweet here")
|
||||
tweet = messages.tweet(self.session, title, caption, self.get_message()+ " ")
|
||||
tweet.message.set_cursor_at_end()
|
||||
if tweet.message.get_response() == widgetUtils.OK:
|
||||
text = tweet.message.get_text()
|
||||
if len(text) > 280 and tweet.message.get("long_tweet") == True:
|
||||
if tweet.image == None:
|
||||
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text)
|
||||
else:
|
||||
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text, 1)
|
||||
if tweet.image == None:
|
||||
call_threaded(self.session.api_call, call_name="update_status", status=text)
|
||||
else:
|
||||
call_threaded(self.session.api_call, call_name="update_status_with_media", status=text, media=tweet.image)
|
||||
title = _("Tweet")
|
||||
caption = _("Write the tweet here")
|
||||
tweet = messages.tweet(session=self.session, title=title, caption=caption, text=self.get_message()+ " ")
|
||||
tweet.message.SetInsertionPoint(len(tweet.message.GetValue()))
|
||||
if tweet.message.ShowModal() == widgetUtils.OK:
|
||||
tweet_data = tweet.get_tweet_data()
|
||||
call_threaded(self.session.send_tweet, *tweet_data)
|
||||
if hasattr(tweet.message, "destroy"): tweet.message.destroy()
|
||||
|
||||
def show_menu_by_key(self, ev):
|
||||
|
Reference in New Issue
Block a user