Пример #1
0
 public ClientLoginForm(MainForm pMainForm)
 {
     InitializeComponent();
     mainForm = pMainForm;
     this.txtPassport.Text = LoginPrometers.Passport;
     this.txtPassword.Text = LoginPrometers.Password;
 }
Пример #2
0
 /// <summary>
 /// 展示获取到的微博状态
 /// </summary>
 /// <param name="MainForm"></param>
 /// <param name="JsonText"></param>
 public static void ShowStatus(MainForm MainForm, dynamic JsonText)
 {
     foreach (var status in JsonText.statuses)
        {
        if (status.IsDefined("user"))	//这里要判断下是不是有user这个项,一般微博被删除了就不会返回user,直接xxx.user要出错。
        {
            ucWeiBoInfo ucStatusInfo = new ucWeiBoInfo(MainForm,status);
            ucStatusInfo.Size= new System.Drawing.Size(MainForm.ControlsContainer.Size.Width,MainForm.ControlsContainer.Size.Height);//对每一条微博信息新建一个微博控件进行展示
            MainForm.ControlsContainer.Controls.Add(ucStatusInfo);
        }
        }
 }
Пример #3
0
        /// <summary>
        /// 将获取到的微博文件添加到ListBox中
        /// </summary>
        /// <param name="MainForm"></param>
        /// <param name="JsonText"></param>
        public static void JsonInfo(MainForm MainForm, dynamic JsonText)
        {
            foreach (var status in JsonText.statuses)
               {
               if (status.IsDefined("user"))	//这里要判断下是不是有user这个项,一般微博被删除了就不会返回user,直接xxx.user要出错。
               {

                   MainForm.lstMessage.Items.Insert(0, string.Format("{0} 说:{1}", status.user.screen_name, status.text)+DateTime.Now.ToString());//打印用户名和他说的内容

               }
               }
        }
Пример #4
0
        public ucWeiBoInfo(MainForm pMainForm, dynamic pStatus)
        {
            InitializeComponent();
            MainForm = pMainForm;
            status   = pStatus;

            //对微博信息控件各项赋值
            this.lblUserName.Text    = status.user.screen_name + ":";
            this.txtStatusInfo.Text  = status.text;

            //对转发的微博添加源博微博信息
            if (status.IsDefined("retweeted_status"))
            {
                //this.txtStatusInfo.Font = new System.Drawing.Font(this.Font,FontStyle.Bold );
                this.txtStatusInfo.AppendText("\n");
                this.txtStatusInfo.AppendText("\n");
                this.txtStatusInfo.AppendText("☞☞☞☞   转自-->    " + status.retweeted_status.user.screen_name + ":" +
                    status.retweeted_status.text);

            }

            this.pcUserFace.Load(status.user.profile_image_url);
        }
Пример #5
0
 public LoginForm(MainForm pMainForm)
 {
     InitializeComponent();
     mainForm = pMainForm;
 }
Пример #6
0
 public PublishForm(MainForm pMainForm,int i)
 {
     InitializeComponent();
     mainForm = pMainForm;
     funcNo = i;
 }