#ifndef MtxDestMimic_INCLUDED
	#define MtxDestMimic_INCLUDED

#include <bncs_script_helper.h>

#ifdef WIN32
	#ifdef DOEXPORT_SCRIPT
		#define EXPORT_SCRIPT __declspec(dllexport) 
	#else
		#define EXPORT_SCRIPT 
	#endif
#else 
	#define EXPORT_SCRIPT
#endif
 
class MtxDestMimic : public bncs_script_helper
{
public:
	MtxDestMimic( bncs_client_callback * parent, const char* path );
	virtual ~MtxDestMimic();

	void buttonCallback( buttonNotify *b );
	int revertiveCallback( revertiveNotify * r );
	void databaseCallback( revertiveNotify * r );
	bncs_string parentCallback( parentNotify *p );
	void timerCallback( int );
	
private:
	bncs_string m_instance;			// Holds the instance string for data from instances.xml
	bncs_string m_myMtxID;			// Holds the user provided matrix ID used when no instance exists.
	bncs_string m_myDestID;			// Holds the user selected destination id to monitor.
	bncs_string m_myStateSheet;		// Holds the name of any statesheet used to control the text appearance.
	
	int m_myMatrixID;				// Holds the numeric version of the matrix to monitor.
	int m_myDestination;			// Holds the numeric version of the matrix output to monitor.
	int m_mySourceDB;				// Holds the database number to be used for names
	int m_mySource;					// Holds the current source number routed to m_myDestination
	
	bool m_RevertRxd;				// Set true once a revertive has been received from the router.

	// Local Methods
	int checkAndActivate(int dev_id, int dest_id);
};


#endif // MtxDestMimic_INCLUDED