Ejemplo n.º 1
0
        public Base(openHAB.Widget aWidget)
        {
            Widget = aWidget;
            Text = new SplitText
            {
                Text = aWidget.Label ?? string.Empty
            };

            Widget.Updated += OnUpdated;
        }
Ejemplo n.º 2
0
        public Base(openHAB.Widget aWidget)
        {
            Widget = aWidget;
            Text   = new SplitText
            {
                Text = aWidget.Label ?? string.Empty
            };

            Widget.Updated += OnUpdated;
        }
Ejemplo n.º 3
0
 public Text(openHAB.Widget aWidget)
     : base(aWidget)
 {
     if (aWidget.Item != null)
     {
         if (aWidget.Item.Type == openHAB.Item.ItemType.ContactItem)
         {
             Text = new SplitText(Colors.White, aWidget.Item.State == "OPEN" ? Colors.White : Color.FromArgb(255, 32, 32, 32))
             {
                 Text = aWidget.Label
             };
         }
     }
     ClickCommand = new Framework.DelegateCommand(OnClick);
 }
Ejemplo n.º 4
0
 public Text(openHAB.Widget aWidget)
     : base(aWidget)
 {
     if (aWidget.Item != null)
     {
         if (aWidget.Item.Type == openHAB.Item.ItemType.ContactItem)
         {
             Text = new SplitText(Colors.White, aWidget.Item.State == "OPEN" ? Colors.White : Color.FromArgb(255,32,32,32))
             {
                 Text = aWidget.Label
             };
         }
     }
     ClickCommand = new Framework.DelegateCommand(OnClick);
 }
Ejemplo n.º 5
0
        public override void OnItemChanged()
        {
            base.OnItemChanged();
            RaisePropertyChanged("ButtonVisibility");

            if (Widget.Item != null)
            {
                if (Widget.Item.Type == openHAB.Item.ItemType.ContactItem)
                {
                    Text = new SplitText(Colors.White, Widget.Item.State == "OPEN" ? Colors.White : Colors.Gray)
                    {
                        Text = Widget.Label
                    };

                    RaisePropertyChanged("Text");
                }
            }
        }
Ejemplo n.º 6
0
        public override void OnItemChanged()
        {
            base.OnItemChanged();
            RaisePropertyChanged("ButtonVisibility");

            if (Widget.Item != null)
            {
                if (Widget.Item.Type == openHAB.Item.ItemType.ContactItem)
                {
                    Text = new SplitText(Colors.White, Widget.Item.State == "OPEN" ? Colors.White : Colors.Gray)
                    {
                        Text = Widget.Label
                    };

                    RaisePropertyChanged("Text");
                }
            }
        }