public FrmMain() { InitializeComponent(); //IsolatedStorageManager.GetManager().Store.DeleteFile(Literals.C_ACCOUNT_FILE); //assignments m_sbbSelected = sbbTimeline; //object creation m_ftTweetForm = new FrmTweet(this); m_fpPrefForm = new FrmPreferences(); //timeline event hookups tmlTimeline.StatusTextClicked += new Timeline.StatusTextClickedHandler(tmlTimeline_StatusTextClicked); tmlTimeline.RetweetClicked += new Timeline.StatusOptionClickedHandler(tmlTimeline_RetweetClicked); tmlTimeline.FavoriteClicked += new Timeline.StatusOptionClickedHandler(tmlTimeline_FavoriteClicked); tmlTimeline.QuoteTweetClicked += new Timeline.StatusOptionClickedHandler(tmlTimeline_QuoteTweetClicked); tmlTimeline.ReplyClicked += new Timeline.StatusOptionClickedHandler(tmlTimeline_ReplyClicked); //preference form event hookups m_fpPrefForm.CredentialsAdded += new FrmAddAccount.OAuthDanceHandler(m_fpPrefForm_CredentialsAdded); m_fpPrefForm.CredentialsRemoved += new FrmPreferences.CredentialsRemovedHandler(m_fpPrefForm_CredentialsRemoved); m_fpPrefForm.AccountList = TwitterController.GetController().Accounts; //form event hookups m_ftTweetForm.TweetClicked += new FrmTweet.TweetClickedEventHandler(m_ftTweetForm_TweetClicked); tsbTimelineScroller.Scroll += new ScrollEventHandler(tsbTimelineScroller_Scroll); tmlTimeline.ScrolledToTop = true; if (m_twController.Accounts.Count == 0) tmlTimeline.DisableLoadingAnimation(); //@TODO: do this for testing purposes only if (Literals.C_ENVIRONMENT == Env.Development) { UserTimeline utLine = new UserTimeline(JsonParser.GetParser().ParseFile("../../../../Documents/test/tweets/tweets2.json").Root.ToList()); for (int i = 0; i < utLine.Statuses.Count; i++) Account_UserStream_Receive(this, new JsonDocument(utLine.Statuses[i].Object), API.Streaming.UserStream.ReceiveType.Tweet); } }
private void sbbReplies_Click(object sender, EventArgs e) { m_sbbSelected.Selected = false; sbbReplies.Selected = true; m_sbbSelected = sbbReplies; m_sbeSelected = SidebarButtonEnum.Replies; SidebarChanged(); }
private void sbbSearch_Click(object sender, EventArgs e) { MessageBox.Show("Sorry! Search hasn't been implemented yet. Contribute to this project on Github (http://github.com/camertron/twitter-windows) and scrach your itch!", "Feature Not Implemented", MessageBoxButtons.OK, MessageBoxIcon.Information); return; m_sbbSelected.Selected = false; sbbSearch.Selected = true; m_sbbSelected = sbbSearch; m_sbeSelected = SidebarButtonEnum.Search; SidebarChanged(); }
private void sbbTimeline_Click(object sender, EventArgs e) { m_sbbSelected.Selected = false; sbbTimeline.Selected = true; m_sbbSelected = sbbTimeline; m_sbeSelected = SidebarButtonEnum.Timeline; SidebarChanged(); }