Beispiel #1
0
        private void AddViews()
        {
            UIButton buttonStandby    = CreateStandbyButton();
            UIButton buttonStandbyAll = CreateStandbyButton();

            iViewMaster.ViewWidgetSelectorRoom.Add(viewControllerRooms);
            iViewMaster.ViewWidgetSelectorRoom.Add(new ViewWidgetSelectorRoomNavigation(helper.Helper, navigationControllerRoomSource, scrollView, viewControllerSources, buttonRefresh, buttonStandby, buttonStandbyAll));

            iViewMaster.ViewWidgetSelectorSource.Add(viewControllerSources);

            viewInfo.TopAlign  = true;
            viewInfo.Alignment = UITextAlignment.Left;

            ViewWidgetTrackArtworkRetriever artworkRetriever = new ViewWidgetTrackArtworkRetriever();
            ViewWidgetTrackArtwork          artwork          = new ViewWidgetTrackArtwork(imageViewArtwork);

            artworkRetriever.AddReceiver(artwork);
            artworkRetriever.AddReceiver(new ImageReceiverButton(buttonArtwork));

            iViewMaster.ViewWidgetTrack.Add(artworkRetriever);
            iViewMaster.ViewWidgetTrack.Add(artwork);
            iViewMaster.ViewWidgetTrack.Add(new ViewWidgetTrackMetadata(viewInfo, helper.OptionExtendedTrackInfo));

            ViewWidgetTransportControl transportControl = new ViewWidgetTransportControl(buttonLeft, buttonCentre, buttonRight);

            iViewMaster.ViewWidgetTransportControlDiscPlayer.Add(transportControl);
            iViewMaster.ViewWidgetTransportControlMediaRenderer.Add(transportControl);
            iViewMaster.ViewWidgetTransportControlRadio.Add(transportControl);

            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeControl);
            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeRotary);
            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeButtons);

            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTime);
            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTimeRotary);
            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTimeButtons);

            iViewMaster.ViewWidgetPlayMode.Add(new ViewWidgetPlayMode(sourceToolbar, buttonShuffle, buttonRepeat));
            sourceToolbar.Initialise(buttonShuffle, buttonRepeat);

            iViewMaster.ViewWidgetPlaylist.Add(new ViewWidgetPlaylistMediaRenderer(tableViewSource, sourceToolbar, new UIButton(), iViewSaveSupport, helper.OptionGroupTracks));
            iViewMaster.ViewWidgetPlaylistRadio.Add(new ViewWidgetPlaylistRadio(tableViewSource, new UIButton(), iViewSaveSupport));

            ViewWidgetPlaylistReceiver playlistReceiver = new ViewWidgetPlaylistReceiver(tableViewSource, new UIButton(), imageViewPlaylistAux, iViewSaveSupport);

            iViewMaster.ViewWidgetPlaylistReceiver.Add(playlistReceiver);
            iViewMaster.ViewWidgetSelectorRoom.Add(playlistReceiver);

            iViewMaster.ViewWidgetPlaylistDiscPlayer.Add(new ViewWidgetPlaylistDiscPlayer(imageViewPlaylistAux));
            iViewMaster.ViewWidgetPlaylistAux.Add(new ViewWidgetPlaylistAux(imageViewPlaylistAux));

            ViewWidgetBrowserRoot viewBrowser = navigationController.TopViewController as ViewWidgetBrowserRoot;

            viewBrowser.Initialise(new Location(iLocator.Root), iPlaySupport, new ConfigControllerIphone(viewController, helper.Helper), helper.OptionInsertMode, helper.Helper.LastLocation);

            iViewMaster.ViewWidgetButtonStandby.Add(new ViewWidgetButtonStandby(buttonStandby));
            iViewMaster.ViewWidgetButtonWasteBin.Add(new ViewWidgetButtonWasteBin(sourceToolbar.BarButtonItemDelete));
            iViewMaster.ViewWidgetButtonSave.Add(new ViewWidgetButtonSave(sourceToolbar.BarButtonItemSave));
        }
Beispiel #2
0
        private void AddViews()
        {
            ViewWidgetSelectorRoom viewWidgetSelectorRoom            = new ViewWidgetSelectorRoom();
            ViewWidgetSelectorPopover <Linn.Kinsky.Room> popOverRoom = new ViewWidgetSelectorPopover <Room>(helper.Helper, viewWidgetSelectorRoom, viewWidgetSelectorRoom, navigationItemSource.LeftBarButtonItem, navigationItemSource.RightBarButtonItem);

            iViewMaster.ViewWidgetSelectorRoom.Add(viewWidgetSelectorRoom);
            iViewMaster.ViewWidgetSelectorRoom.Add(popOverRoom);

            ViewWidgetSelectorSource viewWidgetSelectorSource            = new ViewWidgetSelectorSource();
            ViewWidgetSelectorPopover <Linn.Kinsky.Source> popOverSource = new ViewWidgetSelectorPopover <Source>(helper.Helper, viewWidgetSelectorSource, viewWidgetSelectorSource, navigationItemSource.RightBarButtonItem, navigationItemSource.LeftBarButtonItem);

            iViewMaster.ViewWidgetSelectorSource.Add(viewWidgetSelectorSource);
            iViewMaster.ViewWidgetSelectorSource.Add(popOverSource);

            viewInfo.Alignment = UITextAlignment.Left;
            viewInfo.TopAlign  = true;

            viewOverlayInfo.Alignment = UITextAlignment.Center;
            viewOverlayInfo.TopAlign  = false;

            ViewWidgetTrackArtworkRetriever artworkRetriever = new ViewWidgetTrackArtworkRetriever();
            ViewWidgetTrackArtwork          artwork          = new ViewWidgetTrackArtwork(imageViewArtwork);

            artworkRetriever.AddReceiver(artwork);

            iViewMaster.ViewWidgetTrack.Add(artworkRetriever);
            iViewMaster.ViewWidgetTrack.Add(artwork);
            iViewMaster.ViewWidgetTrack.Add(new ViewWidgetTrackMetadata(viewInfo, helper.OptionExtendedTrackInfo));
            iViewMaster.ViewWidgetTrack.Add(new ViewWidgetTrackMetadata(viewOverlayInfo, helper.OptionExtendedTrackInfo));

            ViewWidgetTransportControl transportControl = new ViewWidgetTransportControl(buttonLeft, buttonCentre, buttonRight);

            iViewMaster.ViewWidgetTransportControlDiscPlayer.Add(transportControl);
            iViewMaster.ViewWidgetTransportControlMediaRenderer.Add(transportControl);
            iViewMaster.ViewWidgetTransportControlRadio.Add(transportControl);

            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeControl);
            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeButtons);
            iViewMaster.ViewWidgetVolumeControl.Add(iViewWidgetVolumeRotary);

            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTime);
            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTimeButtons);
            iViewMaster.ViewWidgetMediaTime.Add(iViewWidgetTimeRotary);

            iViewMaster.ViewWidgetPlayMode.Add(new ViewWidgetPlayMode(sourceToolbar, buttonShuffle, buttonRepeat));
            sourceToolbar.Initialise(buttonShuffle, buttonRepeat);

            iViewMaster.ViewWidgetPlaylist.Add(new ViewWidgetPlaylistMediaRenderer(tableViewSource, sourceToolbar, buttonViewInfo, iViewSaveSupport, helper.OptionGroupTracks));
            iViewMaster.ViewWidgetPlaylistRadio.Add(new ViewWidgetPlaylistRadio(tableViewSource, buttonViewInfo, iViewSaveSupport));

            ViewWidgetPlaylistReceiver playlistReceiver = new ViewWidgetPlaylistReceiver(tableViewSource, buttonViewInfo, imageViewPlaylistAux, iViewSaveSupport);

            iViewMaster.ViewWidgetPlaylistReceiver.Add(playlistReceiver);
            iViewMaster.ViewWidgetSelectorRoom.Add(playlistReceiver);

            iViewMaster.ViewWidgetPlaylistDiscPlayer.Add(new ViewWidgetPlaylistDiscPlayer(imageViewPlaylistAux));
            iViewMaster.ViewWidgetPlaylistAux.Add(new ViewWidgetPlaylistAux(imageViewPlaylistAux));

            ViewWidgetBrowserRoot viewBrowser = navigationController.TopViewController as ViewWidgetBrowserRoot;

            viewBrowser.Initialise(new Location(iLocator.Root), iPlaySupport, iConfigController, helper.OptionInsertMode, helper.Helper.LastLocation);

            iViewMaster.ViewWidgetButtonWasteBin.Add(new ViewWidgetButtonWasteBin(sourceToolbar.BarButtonItemDelete));
            iViewMaster.ViewWidgetButtonSave.Add(new ViewWidgetButtonSave(sourceToolbar.BarButtonItemSave));
        }