AnyCAD C++ API  2018
 全部  命名空间 文件 函数 变量 类型定义 枚举 枚举值 友元 宏定义 
APIEventListener.h
浏览该文件的文档.
1 //Public API. Powered by AnyCAD.
2 
3 #ifndef _APIEventListener_H_
4 #define _APIEventListener_H_
5 
6 #include "APIObjectDef.h"
7 
8 namespace AnyCAD{ namespace API
9 {
10  class DocumentChangeArgs;
11  class View;
12  class SelectionChangeArgs;
21  {
23  public:
28  virtual void OnDocumentModified (const DocumentChangeArgs& args) ;
33  virtual void OnSelectionChanged (const SelectionChangeArgs& args) ;
38  virtual void OnDebugWarning (const String& msg) ;
45  virtual Path OnGetOpenFileName (const String& caption, const String& filter) ;
53  virtual Path OnGetSaveFileName (const String& caption, const String& defaultName, const String& filter) ;
58  virtual int OnGotExistingElement (const String& docId, const ElementId& newId, const ElementIdSet& exitingIds) ;
64  virtual void OnTraceEditor (const String& commandId, int status) ;
70  virtual void OnChangeCursor (const String& commandId, const String& cursorHint) ;
75  virtual void OnMousePositionChanged (const Vector3& worldPos) ;
81  virtual int OnExecuteEventLoop (long loopId) ;
87  virtual void OnExitLoopEvent (long loopId, int code) ;
96  virtual String OnGetInput (const String& desciption, int valueType, const String& defaultValue, long id) ;
102  virtual void OnShowCommandContextUI (bool bShow, const View& pView) ;
103  };//EventListener;
104 }}//API
105 
106 #endif //_APIEventListener_H_
#define AnyPlatformAPI_API
Definition: AnyPlatformAPI.h:8
Arguments for selection change event.
Definition: APISelectionChangeArgs.h:20
std::string String
Definition: APIString.h:10
The document change arguments.
Definition: APIDocumentChangeArgs.h:18
Present the view.
Definition: APIView.h:24
The id.
Definition: APIElementId.h:16
事件接收器
Definition: APIEventListener.h:20
TODO:
Definition: APIPath.h:16
std::set< ElementId > ElementIdSet
Definition: APIElementId.h:53
#define DECLARE_APIOBJECT(className)
Definition: APIObjectDef.h:10
Point or vector.
Definition: APIMath.h:37