public static bool Action( MacroAction a ) { if ( m_Current != null ) return m_Current.Action( a ); else return false; }
public override bool CheckMatch(MacroAction a) { if (!(a is WaitForTargetAction)) return false; Target(); return true; }
public MacroInsertIf( MacroAction a ) { m_Action = a; // // Required for Windows Form Designer support // InitializeComponent(); foreach ( Counter c in Counter.List ) varList.Items.Add( c.Name ); }
public MacroInsertWait( MacroAction a ) { m_Action = a; // // Required for Windows Form Designer support // InitializeComponent(); // // TODO: Add any constructor code after InitializeComponent call // }
// returns true if the were waiting for this action public bool Action( MacroAction action ) { if ( m_Recording ) { action.Parent = this; m_Actions.Insert( m_CurrentAction, action ); if ( m_ListBox != null ) m_ListBox.Items.Insert( m_CurrentAction, action ); m_CurrentAction++; return false; } else if ( m_Playing && m_Wait != null && m_Wait.CheckMatch( action ) ) { m_Wait = null; ExecNext(); return true; } return false; }
public override bool CheckMatch( MacroAction a ) { return (a is WaitForTargetAction); }
public override bool CheckMatch(MacroAction a) { if ( a is WaitForMenuAction ) { if ( m_MenuID == 0 || ((WaitForMenuAction)a).m_MenuID == m_MenuID ) return true; } return false; }
public virtual bool CheckMatch( MacroAction a ) { return false; // a.GetType() == this.GetType(); }
public void Insert( int idx, MacroAction a ) { a.Parent = this; if ( idx < 0 || idx > m_Actions.Count ) idx = m_Actions.Count; m_Actions.Insert( idx, a ); }
public void Convert( MacroAction old, MacroAction newAct ) { for (int i=0;i<m_Actions.Count;i++) { if ( m_Actions[i] == old ) { m_Actions[i] = newAct; newAct.Parent = this; Update(); break; } } }