Beispiel #1
0
        private void setupControls()
        {
            this.SuspendLayout();

            this.AutoScaleMode = AutoScaleMode.None;

            Styles.SetDPI(this.CreateGraphics().DpiX);

            Controls.Add(normal);

            trackDisplay = new QuuxPlayer.TrackDisplay();
            this.Controls.Add(this.trackDisplay);

            progressBar = new QuuxPlayer.ProgressBar();
            this.Controls.Add(this.progressBar);

            controlPanel = new QuuxPlayer.ControlPanel();
            this.Controls.Add(this.controlPanel);

            equalizer         = new Equalizer();
            equalizer.Visible = false;
            this.Controls.Add(equalizer);
            views.Add(equalizer);

            albumDetails         = new AlbumDetails();
            albumDetails.Visible = false;
            this.Controls.Add(albumDetails);
            views.Add(albumDetails);

            spectrumView         = new QuuxPlayer.SpectrumView();
            spectrumView.Visible = false;
            this.Controls.Add(this.spectrumView);
            views.Add(spectrumView);

            tagCloud         = new TagCloud();
            tagCloud.Visible = false;
            this.Controls.Add(this.tagCloud);
            views.Add(tagCloud);

            radio         = new Radio();
            radio.Visible = false;
            this.Controls.Add(radio);
            views.Add(radio);

            podCastManager         = new PodcastManager();
            podCastManager.Visible = false;
            this.Controls.Add(podCastManager);
            views.Add(podCastManager);

            artwork         = new QuuxPlayer.Artwork();
            artwork.Visible = false;
            this.Controls.Add(this.artwork);
            views.Add(artwork);

            normal = new NormalView(this);
            this.Controls.Add(normal);
            views.Add(normal);

            this.ResumeLayout();
        }
Beispiel #2
0
        public NormalView(frmMain MainForm)
        {
            this.mainForm = MainForm;
            instance      = this;

            this.trackList       = new TrackList(this);
            this.filterValueList = new FilterValueList();
            this.filterBar       = new FilterBar();
            this.artwork         = new Artwork();

            this.splMain = new QSplitContainer();

            this.splMain.Panel1.Controls.Add(filterValueList);
            this.splMain.Panel2.Controls.Add(trackList);
            this.Controls.Add(splMain);
            this.Controls.Add(filterBar);

            splMain.Resize         += (s, e) => { arrangeSplitterControls(); };
            splMain.SplitterMoved  += (s, e) => { arrangeSplitterControls(); };
            splMain.VisibleChanged += (s, e) =>
            {
                if (splMain.Visible)
                {
                    splMain.SplitterDistance = Setting.SplitterDistance;
                }
            };

            this.artwork = Artwork;

            splMain.Panel1.Controls.Add(artwork);

            filterBar.FilterReleased     += filterBarFilterCleared;
            filterBar.FilterValueChanged += filterBarFilterValueChanged;

            filterValueList.FilterValueSelected += new FilterValueList.FilterValueSelect(filterValueChanged);
            filterValueList.ValueChanged        += (oldVal, newVal) => { changePlaylistName(oldVal, newVal); };

            arrangeSplitterControls();
            splMain.Panel1.Paint += new PaintEventHandler(Panel1_Paint);
            artwork.Click        += (s, e) => { controller.RequestAction(QActionType.FindPlayingTrack); };
        }
Beispiel #3
0
        private void refresh()
        {
            tracks[0].Selected = true;
            tracklist.EnsureVisible(tracks[0]);
            tracklist.Invalidate();
            NormalView.GetInstance().TempDisplayTrackInfo(tracks[0]);

            txtTitle.Text       = template.Title;
            txtArtist.Text      = template.Artist;
            txtAlbum.Text       = template.Album;
            txtAlbumArtist.Text = template.AlbumArtist;
            if (template.Compilation)
            {
                cboCompilation.Text = "Yes";
            }
            else
            {
                cboCompilation.Text = "No";
            }
            txtComposer.Text = template.Composer;
            cboGrouping.Text = template.Grouping;
            cboGenre.Text    = template.Genre;
            txtYear.Text     = template.YearString;
            txtTrackNum.Text = template.TrackNumString;
            txtDiskNum.Text  = template.DiskNumString;

            if (!isMultiple)
            {
                updateFilenames(0);
            }
            saveCurrentValues();
            this.Text = getTitle(tracks);

            setupArtwork();

            Dirty      = false;
            ImageDirty = false;
        }