Example #1
0
 public bool Match(DetailColor detailColor)
 {
     if (Type == WallSettings.BlueSocket && detailColor == DetailColor.Blue) return true;
     if (Type == WallSettings.RedSocket && detailColor == DetailColor.Red) return true;
     if (Type == WallSettings.GreenSocket && detailColor == DetailColor.Green) return true;
     return false;
 }
Example #2
0
 Color DetailColor(DetailColor color)
 {
     switch (color)
     {
         case RoboMovies.DetailColor.Blue: return Color.Blue;
         case RoboMovies.DetailColor.Green: return Color.Green;
         case RoboMovies.DetailColor.Red: return Color.Red;
     }
     throw new ArgumentException();
 }
Example #3
0
 Color DetailColor(DetailColor color)
 {
     switch (color)
     {
         case RepairTheStarship.DetailColor.Blue: return Color.Blue;
         case RepairTheStarship.DetailColor.Green: return Color.Green;
         case RepairTheStarship.DetailColor.Red: return Color.Red;
     }
     throw new ArgumentException();
 }
Example #4
0
        public _TextCell()
        {
            Tapped += Bubble_Clicked;

            #region
            members = new Dictionary <string, Variable>
            {
                { "Text", new FVariable {
                      ongetvalue = () => new Gstring(Text.ToString()),
                      onsetvalue = (value) =>
                      {
                          Text = value.ToString();
                          return(0);
                      }
                  } },
                { "Detail", new FVariable {
                      ongetvalue = () => new Gstring(Detail.ToString()), onsetvalue = (value) =>
                      {
                          Detail = value.ToString();
                          return(0);
                      }
                  } },
                { "DetailColor", new FVariable
                  {
                      ongetvalue = () => new Gstring(DetailColor.ToString()),
                      onsetvalue = (value) =>
                      {
                          DetailColor = (Color) new ColorTypeConverter().ConvertFromInvariantString(value.ToString());
                          return(0);
                      }
                  } },
                { "Foreground", new FVariable {
                      ongetvalue = () => new Gstring(TextColor.ToString()),
                      onsetvalue = (value) =>
                      {
                          TextColor = (Color) new ColorTypeConverter().ConvertFromInvariantString(value.ToString());
                          return(0);
                      }
                  } },
                { "Clickevent", new FVariable
                  {
                      ongetvalue   = () => event_click as IOBJ
                      , onsetvalue = (value) =>
                      {
                          event_click = value;
                          return(0);
                      }
                  } }
            };
            parent = new Cell.Cell(this);
            #endregion
        }