Ejemplo n.º 1
0
 public GActionMenu(GMacroEditorPanel panel, Macro macro, Action action) : base(action.Handler.Name)
 {
     this.m_Panel  = panel;
     this.m_Macro  = macro;
     this.m_Action = action;
     base.Tooltip  = new Tooltip("Click here to edit this action", true);
 }
Ejemplo n.º 2
0
 public GActionMenu(GMacroEditorPanel panel, Macro macro, Action action)
     : base(action.Handler.Name)
 {
     this.m_Panel = panel;
     this.m_Macro = macro;
     this.m_Action = action;
     base.Tooltip = new Tooltip("Click here to edit this action", true);
 }
Ejemplo n.º 3
0
 public GMacroKeyButton(Keys key, string name, bool bold, int x, int y, int w, int h) : base(x, y, w, h, GumpPaint.Blend(Color.WhiteSmoke, SystemColors.Control, (float) 0.5f), SystemColors.ControlText, name, bold ? Engine.GetUniFont(1) : Engine.GetUniFont(2))
 {
     this.m_Key       = key;
     base.Tooltip     = new Tooltip(string.Format("{0}\nClick to create", GMacroEditorPanel.GetKeyName(this.m_Key)), true);
     base.FillAlpha   = 1f;
     base.m_QuickDrag = false;
     base.m_CanDrag   = true;
     base.OnClick     = new OnClick(this.Clicked);
 }
Ejemplo n.º 4
0
 public GEditAction(GMacroEditorPanel p, Macro macro, Action action) : base(0, 0, 0x67, 0x56)
 {
     this.m_Panel  = p;
     this.m_Macro  = macro;
     this.m_Action = action;
     Gumps.Modal   = this;
     Gumps.Focus   = this;
     base.Text     = "Edit";
     base.m_NonRestrictivePicking = true;
     this.AddButton("↑", 6, 7, 0x18, 0x18, new OnClick(this.Up_OnClick)).Tooltip           = new Tooltip("Moves the instruction up", true);
     this.AddButton("↓", 6, 30, 0x18, 0x18, new OnClick(this.Down_OnClick)).Tooltip        = new Tooltip("Moves the instruction down", true);
     this.AddButton("Delete", 0x27, 7, 50, 0x18, new OnClick(this.Delete_OnClick)).Tooltip = new Tooltip("Removes the instruction", true);
     this.Center();
 }
Ejemplo n.º 5
0
 public GEditAction(GMacroEditorPanel p, Macro macro, Action action)
     : base(0, 0, 0x67, 0x56)
 {
     this.m_Panel = p;
     this.m_Macro = macro;
     this.m_Action = action;
     Gumps.Modal = this;
     Gumps.Focus = this;
     base.Text = "Edit";
     base.m_NonRestrictivePicking = true;
     this.AddButton("↑", 6, 7, 0x18, 0x18, new OnClick(this.Up_OnClick)).Tooltip = new Tooltip("Moves the instruction up", true);
     this.AddButton("↓", 6, 30, 0x18, 0x18, new OnClick(this.Down_OnClick)).Tooltip = new Tooltip("Moves the instruction down", true);
     this.AddButton("Delete", 0x27, 7, 50, 0x18, new OnClick(this.Delete_OnClick)).Tooltip = new Tooltip("Removes the instruction", true);
     this.Center();
 }
Ejemplo n.º 6
0
 public GNewActionMenu(GMacroEditorPanel panel, Macro macro, ActionHandler action) : base(action.Name)
 {
     this.m_Panel  = panel;
     this.m_Macro  = macro;
     this.m_Action = action;
     if ((this.m_Action.Params != null) && (this.m_Action.Params.Length > 0))
     {
         base.Tooltip = new Tooltip("Choose a parameter from the menu to the right, or just click here to add the instruction with a default parameter.", false, 200);
     }
     else
     {
         base.Tooltip = new Tooltip("Click here to add this instruction.", false, 200);
     }
     base.Tooltip.Delay = 2f;
 }
Ejemplo n.º 7
0
 public void Finish(Keys key, Keys mods)
 {
     if (this.m_Recording)
     {
         this.m_Recording = false;
         base.String      = GMacroEditorPanel.GetKeyName(key);
         GMacroEditorPanel parent = base.m_Parent as GMacroEditorPanel;
         if (parent != null)
         {
             parent.Macro.Key  = key;
             parent.Macro.Mods = mods;
             parent.UpdateModifiers();
             parent.NotifyParent();
         }
     }
 }
Ejemplo n.º 8
0
 public GNewActionMenu(GMacroEditorPanel panel, Macro macro, ActionHandler action)
     : base(action.Name)
 {
     this.m_Panel = panel;
     this.m_Macro = macro;
     this.m_Action = action;
     if ((this.m_Action.Params != null) && (this.m_Action.Params.Length > 0))
     {
         base.Tooltip = new Tooltip("Choose a parameter from the menu to the right, or just click here to add the instruction with a default parameter.", false, 200);
     }
     else
     {
         base.Tooltip = new Tooltip("Click here to add this instruction.", false, 200);
     }
     base.Tooltip.Delay = 2f;
 }