support max 2014

This commit is contained in:
rdb 2013-10-07 19:59:39 +00:00
parent 91f6b9503e
commit 7720c482c7
2 changed files with 19 additions and 3 deletions

View File

@ -132,7 +132,11 @@ class MaxEggPlugin : public HelperObject
CreateMouseCallBack* GetCreateMouseCallBack(); CreateMouseCallBack* GetCreateMouseCallBack();
void BeginEditParams( IObjParam *ip, ULONG flags,Animatable *prev); void BeginEditParams( IObjParam *ip, ULONG flags,Animatable *prev);
void EndEditParams( IObjParam *ip, ULONG flags,Animatable *next); void EndEditParams( IObjParam *ip, ULONG flags,Animatable *next);
#if MAX_VERSION_MAJOR < 16
MCHAR *GetObjectName() { return GetString(IDS_LIBDESCRIPTION); } MCHAR *GetObjectName() { return GetString(IDS_LIBDESCRIPTION); }
#else
const MCHAR *GetObjectName() { return GetString(IDS_LIBDESCRIPTION); }
#endif
// From Object // From Object
ObjectState Eval(TimeValue time); ObjectState Eval(TimeValue time);

View File

@ -164,8 +164,14 @@ public:
AddNodeCB (MaxOptionsDialog *instance, HWND wnd) : AddNodeCB (MaxOptionsDialog *instance, HWND wnd) :
ph(instance), hWnd(wnd) {} ph(instance), hWnd(wnd) {}
#if MAX_VERSION_MAJOR < 16
virtual MCHAR *dialogTitle() {return _M("Objects to Export");} virtual MCHAR *dialogTitle() {return _M("Objects to Export");}
virtual MCHAR *buttonText() {return _M("Select");} virtual MCHAR *buttonText() {return _M("Select");}
#else
virtual const MCHAR *dialogTitle() {return _M("Objects to Export");}
virtual const MCHAR *buttonText() {return _M("Select");}
#endif
virtual int filter(INode *node); virtual int filter(INode *node);
virtual void proc(INodeTab &nodeTab); virtual void proc(INodeTab &nodeTab);
}; };
@ -217,8 +223,14 @@ public:
RemoveNodeCB (MaxOptionsDialog *instance, HWND wnd) : RemoveNodeCB (MaxOptionsDialog *instance, HWND wnd) :
ph(instance), hWnd(wnd) {} ph(instance), hWnd(wnd) {}
#if MAX_VERSION_MAJOR < 16
virtual MCHAR *dialogTitle() {return _M("Objects to Remove");} virtual MCHAR *dialogTitle() {return _M("Objects to Remove");}
virtual MCHAR *buttonText() {return _M("Remove");} virtual MCHAR *buttonText() {return _M("Remove");}
#else
virtual const MCHAR *dialogTitle() {return _M("Objects to Remove");}
virtual const MCHAR *buttonText() {return _M("Remove");}
#endif
virtual int filter(INode *node) {return (node && ph->FindNode(node->GetHandle()));} virtual int filter(INode *node) {return (node && ph->FindNode(node->GetHandle()));}
virtual void proc(INodeTab &nodeTab); virtual void proc(INodeTab &nodeTab);
}; };
@ -511,7 +523,7 @@ void MaxOptionsDialog::RefreshNodeList(HWND hWnd) {
SendMessage(nodeLB, LB_RESETCONTENT, 0, 0); SendMessage(nodeLB, LB_RESETCONTENT, 0, 0);
for (int i = 0; i < _node_list.size(); i++) { for (int i = 0; i < _node_list.size(); i++) {
INode *temp = _max_interface->GetINodeByHandle(_node_list[i]); INode *temp = _max_interface->GetINodeByHandle(_node_list[i]);
MCHAR *name = _M("Unknown Node"); const MCHAR *name = _M("Unknown Node");
if (temp) name = temp->GetName(); if (temp) name = temp->GetName();
SendMessage(nodeLB, LB_ADDSTRING, 0, (LPARAM)name); SendMessage(nodeLB, LB_ADDSTRING, 0, (LPARAM)name);
} }