DefaultActions.H

Go to the documentation of this file.
00001 //-----------------------------------------------------------------------------
00002 // ----------------
00003 // File ....: DefaultActions.h
00004 // ----------------
00005 // Author...: Larry Minton
00006 // Date ....: June 2003
00007 //
00008 // History .: June, 19 2003 - Started
00009 //
00010 //-----------------------------------------------------------------------------
00011         
00012 #pragma once
00013 #include "maxheap.h"
00014 #include <WTypes.h>
00015 #include "strclass.h"
00016 
00019 #define DEFAULTACTIONS_DEFAULT_MSG_LOG_MAXSIZE 500
00020 
00021 // Actions - set as bits in a DWORD
00028 #define DEFAULTACTIONS_LOGTOFILE        0x00000001 //!< Messages get logged to a file "<3dsMaxInstallPath>\network\Max.log"
00029 #define DEFAULTACTIONS_LOGMSG           0x00000002 //!< Messages get logged to the Default Action System and can be retrived via DefaultActionSys::GetMsgLogMsg
00030 #define DEFAULTACTIONS_ABORT            0x00000004 //!< The process that generated the event associated with this action is cancelled
00031 #define DEFAULTACTIONS_RESERVED_4       0x00000008
00032 #define DEFAULTACTIONS_RESERVED_5       0x00000010
00033 #define DEFAULTACTIONS_RESERVED_6       0x00000020
00034 #define DEFAULTACTIONS_RESERVED_7       0x00000040
00035 #define DEFAULTACTIONS_RESERVED_8       0x00000080
00036 
00037 
00038 
00046 #define TYPE_MISSING_EXTERNAL_FILES             1 //!< External assets cannot be found
00047 #define TYPE_MISSING_DLL_FILES                  2 //!< Plugin dlls cannot be found
00048 #define TYPE_MISSING_XREF_FILES                 3 //!< Xref assets (.max files) cannot be found
00049 #define TYPE_MISSING_UVWS                       4 //!< UVW coordinates cannot be found
00050 #define TYPE_UNSUPPORTED_RENDEREFFECT           5 //!< Unsupported render effects have been found
00051 #define TYPE_INVALID_XREF_FILES                 6 //!< Files not suitable for xrefing were detected
00052 #define DEFAULTACTIONS_MAX_DEFINED_ACTION       (TYPE_INVALID_XREF_FILES) //!< DEFAULTACTIONS_MAX_DEFINED_ACTION must contain the largest internally used value
00053 
00054 
00055 //-----------------------------------------------------------------------------
00056 //-----------------------------------------------------------------------------
00057 //
00058 
00060 
00066 class DefaultActionSys: public MaxHeapOperators {
00067 
00068  public:
00070 
00076     virtual BOOL    GetAction (DWORD eventID, DWORD &action) = 0;
00077 
00079 
00086     virtual BOOL    SetAction ( DWORD eventID, DWORD action, MCHAR* title = NULL, DWORD *oldAction = NULL) = 0;
00087 
00089 
00092     virtual BOOL    DeleteAction (DWORD eventID) = 0;
00093 
00095 
00097     virtual int     GetActionCount() = 0;
00098 
00100 
00103     virtual MSTR    GetActionTitle(DWORD eventID) = 0;
00104 
00106 
00109     virtual MSTR    GetActionTitleByIndex(int index) = 0;
00110 
00111     // Returns the indexed default action event's ID.
00113 
00116     virtual DWORD   GetActionIDByIndex(int index) = 0;
00117 
00119 
00124     virtual BOOL    LogEntry(DWORD eventID, MCHAR *message) = 0;
00125 
00127 
00130     virtual void    MsgLogClear(DWORD eventID) = 0;
00131 
00133 
00137     virtual int     GetMsgLogCount(DWORD eventID) = 0;
00138 
00140 
00144     virtual MSTR    GetMsgLogMsg(DWORD eventID, int index) = 0;
00145 
00147 
00150     virtual DWORD   GetMsgLogID(int index) = 0;
00151 
00153 
00156     virtual int     SetMsgLogMaxCount(int count) = 0;
00157 };
00158 
00159 
00160 //-- EOF: DefaultActions.h ---------------------------------------------------------------