KbtterWPF.MainWindow.SetStatusBarWithSendTweet C# (CSharp) Method

SetStatusBarWithSendTweet() public method

public SetStatusBarWithSendTweet ( TweetSharp.TwitterResponse res, TwitterStatus st ) : void
res TweetSharp.TwitterResponse
st TwitterStatus
return void
        public void SetStatusBarWithSendTweet(TwitterResponse res, TwitterStatus st)
        {
            if (res == null)
            {
                return;
            }
            var text = "";
            if (res.Error != null)
            {
                //エラー
                var omsg = res.Error.Message;
                var mn = res.Error.Code.ToString();
                var msg = LanguageSetting["Kbtter.Status.Error." + mn].StringValue;
                if (msg == "")
                {
                    msg = omsg;
                }
                text = msg;
            }
            else
            {
                text = LanguageSetting["Kbtter.Status.SendTweetSucceeded"].StringValue;
                text = String.Format(text, st.TextDecoded);
            }
            UpdateStatus(text);
        }