include/ax/ax_validator.h

Go to the documentation of this file.
00001 
00002 // Name:        ax_validator.h
00003 // Purpose:     Validator/Data transfer classes
00004 // Author:      Julian Smart
00005 // Modified by:
00006 // Created:     2009-03-20
00007 // RCS-ID:
00008 // Copyright:   (c) Julian Smart
00009 // Licence:     New BSD License
00011 
00012 #ifndef _AX_VALIDATOR_H_
00013 #define _AX_VALIDATOR_H_
00014 
00015 class AxMenuItem;
00016  
00021 class AxValidator: public wxEvtHandler
00022 {
00023     DECLARE_CLASS( AxValidator )
00024 
00025 public:
00026 // Constructors
00027 
00028     AxValidator() { Init(); }
00029     ~AxValidator() {}
00030 
00031 // Operations
00032 
00033     void Init()
00034     {
00035         m_item = NULL;
00036     }
00037 
00038     void Copy(const AxValidator& validator) { m_item = validator.m_item; }
00039 
00041     virtual bool TransferDataFromMenu() { return false; }
00042 
00044     virtual bool TransferDataToMenu() { return false; }
00045 
00047     virtual AxValidator* Clone() const = 0;
00048 
00049     AxMenuItem* GetMenuItem() const { return m_item; }
00050 
00051     void SetMenuItem(AxMenuItem* item) { m_item = item; }
00052 
00053 protected:
00054 
00055     AxMenuItem* m_item;
00056 };
00057 
00058 #endif
00059     // _AX_VALIDATOR_H_

Generated on Wed May 6 19:20:18 2009 for AxTk by  doxygen 1.5.1