Began implementation of reply button
This commit is contained in:
parent
8021d05ade
commit
23573bc648
15
mytwitter.py
15
mytwitter.py
|
@ -85,7 +85,8 @@ class MyTwitter():
|
||||||
def update_status(self):
|
def update_status(self):
|
||||||
text = self.update_entry.get_text()
|
text = self.update_entry.get_text()
|
||||||
self.update_entry.set_text("")
|
self.update_entry.set_text("")
|
||||||
self.api.PostUpdate(text)
|
self.api.PostUpdate(text, in_reply_to_status_id=self.reply_id)
|
||||||
|
self.reply_id = None
|
||||||
self.update_window()
|
self.update_window()
|
||||||
|
|
||||||
|
|
||||||
|
@ -111,12 +112,16 @@ class MyTwitter():
|
||||||
self.update_window()
|
self.update_window()
|
||||||
|
|
||||||
|
|
||||||
# fixme: these are stubs
|
# fixme: this doesn't work; we're passing in the Button widget and not the
|
||||||
def on_reply(self, reply):
|
# TweetBox widget... certain I need to do something convoluted to fix
|
||||||
pass
|
# this
|
||||||
|
def on_reply(self, widget):
|
||||||
|
self.update_entry.set_text('@' + widget.screen_name + ' ')
|
||||||
|
self.reply_id = widget.id
|
||||||
|
|
||||||
|
|
||||||
def on_retweet(self, retweet):
|
# fixme: need to implement the retweet API in python-twitter to continue
|
||||||
|
def on_retweet(self, widget):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
### end class MyTwitter
|
### end class MyTwitter
|
||||||
|
|
Reference in New Issue
Block a user