예제 #1
0
        public Form_AddPost(preposts prPost)
        {
            InitializeComponent();

            Program.statusBarGlobal.onChangeDescription += StatusBarGlobal_onChangeDescription;
            Program.statusBarGlobal.onChangeMessage     += StatusBarGlobal_onChangeMessage;
            Program.statusBarGlobal.onChangeProgress    += StatusBarGlobal_onChangeProgress;

            post = new Post(prPost);

            textBox_NamePost.Text = post.Name;

            textBox_TorrentFile.Text         = post.TorrentPath;
            openFileDialog1.InitialDirectory = Path.GetDirectoryName(post.TorrentPath);

            imgsSlider = new Slider <string>(post.Imgs.AllCollection);
            imgsSlider.onChangeSlide += ImgsSlider_onChangeImg;
            imgsSlider.Initialize();

            textBox_Description.Text = post.Description;

            spoilerSlider = new Slider <SpoilersItem>(post.Spoilers);
            spoilerSlider.onChangeSlide += SpoilerSlider_onChangeSlide;
            spoilerSlider.Initialize();

            searchStr = new SearchStr(post.Name);
            searchStr.onChangeName    += SearchStr_onChangeName;
            textBox_SearchProgram.Text = searchStr.ShortName;

            dataGridView_Search.DataSource         = SearchList.UpdateProgramsGrid(textBox_SearchProgram.Text);
            dataGridView_Search.Columns[0].Visible = false;
        }
예제 #2
0
 private void textBox_NamePost_TextChanged(object sender, EventArgs e)
 {
     searchStr = new SearchStr(textBox_NamePost.Text);
     textBox_SearchProgram.Text = searchStr.ShortName;
 }