16namespace ot {
class WidgetView; };
17namespace ot {
class TextEditor; };
19class __declspec(dllexport) FrontendAPI {
21 static void setInstance(FrontendAPI* _api);
22 static FrontendAPI* instance(
void);
25 virtual ~FrontendAPI() {};
27 virtual void createTree(
void) {};
28 virtual void clearTree(
void) {};
29 virtual ot::UID addTreeItem(
const std::string& treePath,
bool editable,
bool selectChildren) {
return 0; };
30 virtual void removeTreeItems(std::list<ot::UID> treeItemIDList) {};
31 virtual void selectTreeItem(
ot::UID treeItemID) {};
32 virtual void selectSingleTreeItem(
ot::UID treeItemID) {};
33 virtual void expandSingleTreeItem(
ot::UID treeItemID) {};
34 virtual bool isTreeItemExpanded(
ot::UID treeItemID) {
return false; };
35 virtual void toggleTreeItemSelection(
ot::UID treeItemID,
bool considerChilds) {};
36 virtual void clearTreeSelection(
void) {};
37 virtual void setTreeItemIcon(
ot::UID treeItemID,
int iconSize,
const std::string& iconName) {};
38 virtual void setTreeItemText(
ot::UID treeItemID,
const std::string& text) {};
39 virtual void refreshSelection(
void) {};
40 virtual void addKeyShortcut(
const std::string& keySequence) {};
42 virtual void setDoublePropertyValue(
const std::string& _groupName,
const std::string& _itemName,
double value) {};
43 virtual double getDoublePropertyValue(
const std::string& _groupName,
const std::string& _itemName) {
return 0.0; };
44 virtual void lockSelectionAndModification(
bool flag) {};
45 virtual void removeViewer(
ot::UID viewerID) {};
49 virtual unsigned long long addMenuPage(
const std::string& pageName) {
return 0; };
50 virtual unsigned long long addMenuGroup(
unsigned long long menuPageID,
const std::string& groupName) {
return 0; };
51 virtual unsigned long long addMenuSubGroup(
unsigned long long _menuGroupID,
const std::string& _subGroupName) {
return 0; };
52 virtual unsigned long long addMenuPushButton(
unsigned long long menuGroupID,
const std::string& buttonName,
const std::string& iconName) {
return 0; };
53 virtual unsigned long long addMenuPushButton(
unsigned long long menuGroupID,
const std::string& buttonName,
const std::string& iconName,
const std::string& keySequence) {
return 0; };
54 virtual void setMenuPushButtonToolTip(
unsigned long long _buttonID,
const std::string& _toolTip) {};
56 virtual void setCurrentMenuPage(
const std::string& _pageName) {};
57 virtual std::string getCurrentMenuPage(
void) {
return std::string(); };
59 virtual void removeUIElements(std::list<unsigned long long>& itemIDList) {};
60 virtual void removeGraphicsElements(
ot::UID _modelID) {};
62 virtual void displayText(
const std::string& text) {};
66 virtual bool getCurrentViewIsModified(
void) {
return false; };
69 virtual void setCurrentVisualizationTabFromTitle(
const std::string& _tabTitle) {};
70 virtual std::string getCurrentVisualizationTabTitle(
void) {
return ""; };
72 virtual void requestSaveForCurrentVisualizationTab(
void) {};
74 virtual void enableDisableControls(
const ot::UIDList& _enabledControls,
const ot::UIDList& _disabledControls) {};
76 virtual void entitiesSelected(
ot::serviceID_t replyTo,
const std::string& selectionAction,
const std::string& selectionInfo, std::list<std::string>& optionNames, std::list<std::string>& optionValues) {};
78 virtual void fatalError(
const std::string& message) {};
80 virtual void rubberbandFinished(
ot::serviceID_t creatorId,
const std::string& note,
const std::string& pointJson,
const std::vector<double>& transform) {}
88 virtual void updateVTKEntity(
unsigned long long modelEntityID) {};
90 virtual void messageModelService(
const std::string& _message) {};
92 virtual std::string getOpenFileName(
const std::string& _title,
const std::string& _path,
const std::string& _filters) {
return std::string(); };
93 virtual std::string getSaveFileName(
const std::string& _title,
const std::string& _path,
const std::string& _filters) {
return std::string(); };
96 static FrontendAPI*& getInstance(
void);
unsigned short serviceID_t
ID type used to identify a service (16 bit unsigned integer).
Definition CoreTypes.h:14