Esempio n. 1
0
        public void selectFilesTab(CButtonLib.CButton cbtn)
        {
            Color selectedRGB    = Color.FromArgb(42, 42, 42);
            Color nonSelectedRGB = Color.Transparent;

            titleFilesAll.ColorFillSolid       = nonSelectedRGB;
            titleFilesAll.BorderColor          = nonSelectedRGB;
            titleFilesVideo.ColorFillSolid     = nonSelectedRGB;
            titleFilesVideo.BorderColor        = nonSelectedRGB;
            titleFilesAudio.ColorFillSolid     = nonSelectedRGB;
            titleFilesAudio.BorderColor        = nonSelectedRGB;
            titleFilesEbooks.ColorFillSolid    = nonSelectedRGB;
            titleFilesEbooks.BorderColor       = nonSelectedRGB;
            titleFilesSubtitles.ColorFillSolid = nonSelectedRGB;
            titleFilesSubtitles.BorderColor    = nonSelectedRGB;
            titleFilesTorrents.ColorFillSolid  = nonSelectedRGB;
            titleFilesTorrents.BorderColor     = nonSelectedRGB;
            titleFilesMobile.ColorFillSolid    = nonSelectedRGB;
            titleFilesMobile.BorderColor       = nonSelectedRGB;
            titleFilesArchives.ColorFillSolid  = nonSelectedRGB;
            titleFilesArchives.BorderColor     = nonSelectedRGB;
            titleFilesOther.ColorFillSolid     = nonSelectedRGB;
            titleFilesOther.BorderColor        = nonSelectedRGB;
            titleFilesLocal.ColorFillSolid     = nonSelectedRGB;
            titleFilesLocal.BorderColor        = nonSelectedRGB;
            titleFilesSaved.ColorFillSolid     = nonSelectedRGB;
            titleFilesSaved.BorderColor        = nonSelectedRGB;

            cbtn.ColorFillSolid = selectedRGB;
            cbtn.BorderColor    = selectedRGB;
        }
Esempio n. 2
0
        public void addTopSearchTag(string text, int count)
        {
            CButtonLib.CButton a = new CButtonLib.CButton
            {
                Text           = text,
                TextAlign      = ContentAlignment.MiddleCenter,
                Font           = new Font(btnHomeFileType.Font.Name, 9.25F, FontStyle.Regular),
                Size           = new Size(70, 24),
                BackColor      = Color.Transparent,
                ForeColor      = Color.Black,
                TextMargin     = new Padding(0, 2, 0, 2),
                BorderColor    = Color.FromArgb(230, 230, 230),
                ColorFillSolid = Color.FromArgb(230, 230, 230),
                FillType       = CButtonLib.CButton.eFillType.Solid,
                TextShadowShow = false,
                ShowFocus      = CButtonLib.CButton.eFocus.None,
                Margin         = new Padding(0, 3, 6, 3),
                BorderShow     = true,
                DimFactorHover = 0,
                DimFactorClick = 0,
                Cursor         = Cursors.Hand,
                Name           = "tagItem" + count
            };

            a.Corners.All = 2;

            Font  myFont = new Font(a.Font.FontFamily, a.Font.Size);
            SizeF mySize = a.CreateGraphics().MeasureString(a.Text, myFont);

            a.Width            = (((int)(Math.Round(mySize.Width, 0))) + 10);
            a.ClickButtonArea += btnTopSearchesTag_ClickButtonArea;
            panelTopSearches.Controls.Add(a);
        }
Esempio n. 3
0
        public void selectedTabLine(CButtonLib.CButton cbtn)
        {
            titleLineHome.Visible     = false;
            titleLineMovies.Visible   = false;
            titleLineFiles.Visible    = false;
            titleLineDiscover.Visible = false;
            titleLineSubmit.Visible   = false;
            titleLineSettings.Visible = false;
            titleLineAbout.Visible    = false;

            cbtn.Visible = true;
        }
Esempio n. 4
0
 private void btnTag4_Click(object sender, EventArgs e)
 {
     CButtonLib.CButton ctrlTag = sender as CButtonLib.CButton;
     if (txtSearchBox.Text == "")
     {
         txtSearchBox.Text += ctrlTag.Text + ", ";
     }
     else if (txtSearchBox.Text.EndsWith(", "))
     {
         txtSearchBox.Text += ctrlTag.Text + ", ";
     }
     else
     {
         txtSearchBox.Text += ", " + ctrlTag.Text + ", ";
     }
 }
Esempio n. 5
0
 private void btnTag4_Click(object sender, EventArgs e)
 {
     CButtonLib.CButton ctrlTag = sender as CButtonLib.CButton;
     txtSearchBox.Text += ctrlTag.Text;
 }
Esempio n. 6
0
 private void btnTopSearchesTag_ClickButtonArea(object Sender, MouseEventArgs e)
 {
     CButtonLib.CButton tagItem = Sender as CButtonLib.CButton;
     txtSearchFilesHome.Text = tagItem.Text;
     btnSearchFilesHome.PerformClick();
 }