コード例 #1
0
        public CameraControlViewController(UIViewController parentViewController)
            : base(parentViewController, Digitals.SubPageTechCameras, "Camera Control", TimeSpan.Zero)
        {
            var tabs = new UITabBar((UIControllerWithSmartObjects)parentViewController.UIController,
                                    Device.SmartObjects[Joins.SmartObjects.CamTrackingProcessorSelectTabs]);

            _processorSelectButtons = new ButtonCollection(tabs);
            _cameraButtons          = new ButtonCollection
            {
                { Digitals.CameraUp, new UIButton(this, Digitals.CameraUp) },
                { Digitals.CameraDown, new UIButton(this, Digitals.CameraDown) },
                { Digitals.CameraLeft, new UIButton(this, Digitals.CameraLeft) },
                { Digitals.CameraRight, new UIButton(this, Digitals.CameraRight) },
                { Digitals.CameraZoomIn, new UIButton(this, Digitals.CameraZoomIn) },
                { Digitals.CameraZoomOut, new UIButton(this, Digitals.CameraZoomOut) },
                { Digitals.CameraTrackingOff, new UIButton(this, Digitals.CameraTrackingOff) },
                { Digitals.CameraTrackingOn, new UIButton(this, Digitals.CameraTrackingOn) },
                { Digitals.CameraRecordBtn, new UIButton(this, Digitals.CameraRecordBtn) },
                { Digitals.CameraRecordStopBtn, new UIButton(this, Digitals.CameraRecordStopBtn) },
                { Digitals.CameraStreamBtn, new UIButton(this, Digitals.CameraStreamBtn) },
            };
            _layoutsList = new UIDynamicButtonList(
                (UIControllerWithSmartObjects)parentViewController.UIController,
                Device.SmartObjects[Joins.SmartObjects.CameraLayoutsList]);
            _layoutsListButtons = new ButtonCollection(_layoutsList);
            _roomConfigsList    = new UIDynamicButtonList(
                (UIControllerWithSmartObjects)parentViewController.UIController,
                Device.SmartObjects[Joins.SmartObjects.CameraRoomConfigsList]);
            _roomConfigsListButtons = new ButtonCollection(_roomConfigsList);
            _cameraSelectList       = new UIDynamicButtonList(
                (UIControllerWithSmartObjects)parentViewController.UIController,
                Device.SmartObjects[Joins.SmartObjects.CameraSelectList]);
            _cameraSelectListButtons = new ButtonCollection(_cameraSelectList);
            _autoSwitchEnableButton  = new UIButton(this, Digitals.CameraAutoTracking);
        }
コード例 #2
0
 public VCShareViewController(UIViewController parentViewController)
     : base(parentViewController, Digitals.SubPageVCShare)
 {
     var ui = parentViewController.UIController as UIControllerWithSmartObjects;
     _list = new UIDynamicButtonList(ui, ui.Device.SmartObjects[Joins.SmartObjects.VCShareSourceList]);
     _sourceButtons = new ButtonCollection(_list);
     _closeBtn = new UIButton(this, Digitals.VCDialViewCloseBtn);
 }
コード例 #3
0
        public UsbRoutingViewController(UIViewController parentViewController)
            : base(parentViewController, Digitals.SubPageTechUsb, string.Empty, TimeSpan.Zero)
        {
            try
            {
                var ui = parentViewController.UIController as UIControllerWithSmartObjects;
                _lists    = new Dictionary <uint, UIDynamicButtonList>();
                _buttons  = new Dictionary <uint, ButtonCollection>();
                _pcInputs = new Dictionary <uint, uint>
                {
                    { 1, 11 },
                    { 2, 12 },
                    { 3, 13 },
                    { 4, 14 },
                };
                for (uint i = 0; i < 4; i++)
                {
                    var list = new UIDynamicButtonList(ui,
                                                       ui.Device.SmartObjects[Joins.SmartObjects.UsbRoutingList1 + i]);
                    _lists[i + 1]   = list;
                    _buttons[i + 1] = new ButtonCollection(list);

                    for (uint j = 1; j <= 3; j++)
                    {
                        switch (j)
                        {
                        case 1:
                            list.AddItem("Aud 1 Lectern", new[] { 1U, 2U });
                            break;

                        case 2:
                            list.AddItem("Aud 2 Lectern", new[] { 3U, 4U });
                            break;

                        case 3:
                            list.AddItem("Control Room", new[] { 10U });
                            break;
                        }
                    }
                }
            }
            catch (Exception e)
            {
                CloudLog.Error("Error loading {0}, {1}", GetType().Name, e.Message);
            }
        }
コード例 #4
0
        public TVControlViewController(UIViewController parentViewController)
            : base(parentViewController, Digitals.SubPageTechTV, string.Empty, TimeSpan.Zero)
        {
            var ui     = parentViewController.UIController as UIControllerWithSmartObjects;
            var tabBar = new UITabBar(ui, ui.Device.SmartObjects[Joins.SmartObjects.TVReceiverSelectTabs]);

            _tabs           = new ButtonCollection(tabBar);
            _channelList    = new UIDynamicButtonList(ui, ui.Device.SmartObjects[Joins.SmartObjects.TVChannelList]);
            _channelButtons = new ButtonCollection(_channelList);
            if (parentViewController.UIController.System is AuditoriumSystem)
            {
                _receiverIds = new Dictionary <uint, uint>
                {
                    { 1, 7 },
                    { 2, 8 },
                    { 3, 5 },
                };
            }
            else if (parentViewController.UIController.System is ClassroomSystem)
            {
                _receiverIds = new Dictionary <uint, uint>
                {
                    { 1, 11 }
                };
            }
            else
            {
                _receiverIds = new Dictionary <uint, uint>();
                var count = 0U;
                foreach (var source in parentViewController.UIController.System.Sources.Where(s => s is TVSource).Cast <TVSource>())
                {
                    count++;
                    _receiverIds[count] = source.ClientId;
                }
            }
        }