From 50fc8f3a329723409327734ba4696f7638a71232 Mon Sep 17 00:00:00 2001 From: Thomas Kroes Date: Wed, 5 Feb 2025 11:47:45 +0100 Subject: [PATCH 1/3] Add example notifications --- ExampleAnalysis/src/ExampleAnalysisPlugin.cpp | 13 +++++++++++++ ExampleData/src/ExampleDataPlugin.cpp | 12 ++++++++++++ .../src/ExampleDependenciesPlugin.cpp | 13 +++++++++++++ ExampleLoader/src/ExampleLoaderPlugin.cpp | 13 ++++++++++++- .../src/ExampleTransformationPlugin.cpp | 12 ++++++++++++ ExampleView/src/ExampleViewPlugin.cpp | 13 +++++++++++++ ExampleViewJS/src/ExampleViewJSPlugin.cpp | 13 +++++++++++++ ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp | 12 ++++++++++++ ExampleWriter/src/ExampleWriterPlugin.cpp | 13 ++++++++++++- 9 files changed, 112 insertions(+), 2 deletions(-) diff --git a/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp b/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp index b2be2d0..46aa420 100644 --- a/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp +++ b/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp @@ -160,6 +160,19 @@ void ExampleAnalysisPlugin::init() _eventListener.addSupportedEventType(static_cast(EventType::DatasetDataSelectionChanged)); _eventListener.registerDataEventByType(PointType, std::bind(&ExampleAnalysisPlugin::onDataEvent, this, std::placeholders::_1)); + + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleAnalysisPlugin::onDataEvent(mv::DatasetEvent* dataEvent) diff --git a/ExampleData/src/ExampleDataPlugin.cpp b/ExampleData/src/ExampleDataPlugin.cpp index 6163262..145d014 100644 --- a/ExampleData/src/ExampleDataPlugin.cpp +++ b/ExampleData/src/ExampleDataPlugin.cpp @@ -17,6 +17,18 @@ ExampleDataPlugin::~ExampleDataPlugin(void) void ExampleDataPlugin::init() { + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } /** diff --git a/ExampleDependencies/src/ExampleDependenciesPlugin.cpp b/ExampleDependencies/src/ExampleDependenciesPlugin.cpp index 234a38c..9f869fc 100644 --- a/ExampleDependencies/src/ExampleDependenciesPlugin.cpp +++ b/ExampleDependencies/src/ExampleDependenciesPlugin.cpp @@ -50,6 +50,19 @@ void ExampleDependenciesPlugin::init() // Start the analysis when the user clicks the start analysis push button connect(&_settingsAction.getStartAnalysisAction(), &mv::gui::TriggerAction::triggered, this, &ExampleDependenciesPlugin::compute); + + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleDependenciesPlugin::compute() diff --git a/ExampleLoader/src/ExampleLoaderPlugin.cpp b/ExampleLoader/src/ExampleLoaderPlugin.cpp index 795f593..1370867 100644 --- a/ExampleLoader/src/ExampleLoaderPlugin.cpp +++ b/ExampleLoader/src/ExampleLoaderPlugin.cpp @@ -35,7 +35,18 @@ ExampleLoaderPlugin::~ExampleLoaderPlugin(void) */ void ExampleLoaderPlugin::init() { - + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } /** diff --git a/ExampleTransformation/src/ExampleTransformationPlugin.cpp b/ExampleTransformation/src/ExampleTransformationPlugin.cpp index ce76d30..db800b1 100644 --- a/ExampleTransformation/src/ExampleTransformationPlugin.cpp +++ b/ExampleTransformation/src/ExampleTransformationPlugin.cpp @@ -22,6 +22,18 @@ ExampleTransformationPlugin::ExampleTransformationPlugin(const PluginFactory* fa TransformationPlugin(factory), _type(Type::Abs) { + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleTransformationPlugin::transform() diff --git a/ExampleView/src/ExampleViewPlugin.cpp b/ExampleView/src/ExampleViewPlugin.cpp index 4e22ea1..c7946a0 100644 --- a/ExampleView/src/ExampleViewPlugin.cpp +++ b/ExampleView/src/ExampleViewPlugin.cpp @@ -114,6 +114,19 @@ void ExampleViewPlugin::init() _eventListener.addSupportedEventType(static_cast(EventType::DatasetRemoved)); _eventListener.addSupportedEventType(static_cast(EventType::DatasetDataSelectionChanged)); _eventListener.registerDataEventByType(PointType, std::bind(&ExampleViewPlugin::onDataEvent, this, std::placeholders::_1)); + + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleViewPlugin::onDataEvent(mv::DatasetEvent* dataEvent) diff --git a/ExampleViewJS/src/ExampleViewJSPlugin.cpp b/ExampleViewJS/src/ExampleViewJSPlugin.cpp index fe51627..7279ab6 100644 --- a/ExampleViewJS/src/ExampleViewJSPlugin.cpp +++ b/ExampleViewJS/src/ExampleViewJSPlugin.cpp @@ -100,6 +100,19 @@ void ExampleViewJSPlugin::init() // Create data so that we do not need to load any in this example createData(); + + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleViewJSPlugin::loadData(const mv::Datasets& datasets) diff --git a/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp b/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp index e8351dc..4b1b557 100644 --- a/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp +++ b/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp @@ -132,6 +132,18 @@ void ExampleViewGLPlugin::init() // Update the data when the scatter plot widget is initialized connect(_exampleGLWidget, &ExampleGLWidget::initialized, this, []() { qDebug() << "ExampleGLWidget is initialized."; } ); + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } void ExampleViewGLPlugin::updatePlot() diff --git a/ExampleWriter/src/ExampleWriterPlugin.cpp b/ExampleWriter/src/ExampleWriterPlugin.cpp index 528797d..da18a6a 100644 --- a/ExampleWriter/src/ExampleWriterPlugin.cpp +++ b/ExampleWriter/src/ExampleWriterPlugin.cpp @@ -33,7 +33,18 @@ ExampleWriterPlugin::~ExampleWriterPlugin(void) */ void ExampleWriterPlugin::init() { - + addNotification("ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" + ); } /** From 3c7ed146bb93668e27792f20a92008df8a79be89 Mon Sep 17 00:00:00 2001 From: Thomas Kroes Date: Wed, 5 Feb 2025 18:01:15 +0100 Subject: [PATCH 2/3] Add shared common sources --- CMakeLists.txt | 2 ++ Common/CMakeLists.txt | 17 +++++++++++++++++ Common/common.cpp | 0 Common/common.h | 0 ExampleAnalysis/CMakeLists.txt | 5 +++-- ExampleData/CMakeLists.txt | 5 +++-- ExampleDependencies/CMakeLists.txt | 5 +++-- ExampleLoader/CMakeLists.txt | 5 +++-- ExampleTransformation/CMakeLists.txt | 5 +++-- ExampleView/CMakeLists.txt | 5 +++-- ExampleViewJS/CMakeLists.txt | 9 +++++---- ExampleViewOpenGL/CMakeLists.txt | 9 +++++---- ExampleWriter/CMakeLists.txt | 5 +++-- 13 files changed, 50 insertions(+), 22 deletions(-) create mode 100644 Common/CMakeLists.txt create mode 100644 Common/common.cpp create mode 100644 Common/common.h diff --git a/CMakeLists.txt b/CMakeLists.txt index fb6a55d..e0bc47c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,6 +12,8 @@ endif() set(PROJECT "ExamplePlugins") PROJECT(${PROJECT}) +add_subdirectory(Common) + add_subdirectory(ExampleView) add_subdirectory(ExampleViewJS) add_subdirectory(ExampleViewOpenGL) diff --git a/Common/CMakeLists.txt b/Common/CMakeLists.txt new file mode 100644 index 0000000..960a680 --- /dev/null +++ b/Common/CMakeLists.txt @@ -0,0 +1,17 @@ +set(DIR ${CMAKE_CURRENT_SOURCE_DIR}) + +set(COMMON_HEADERS + ${DIR}/common.h + PARENT_SCOPE +) + +set(COMMON_SOURCES + ${DIR}/common.cpp + PARENT_SCOPE +) + +set(COMMON_FILES + ${COMMON_HEADERS} + ${COMMON_SOURCES} + PARENT_SCOPE +) diff --git a/Common/common.cpp b/Common/common.cpp new file mode 100644 index 0000000..e69de29 diff --git a/Common/common.h b/Common/common.h new file mode 100644 index 0000000..e69de29 diff --git a/ExampleAnalysis/CMakeLists.txt b/ExampleAnalysis/CMakeLists.txt index 00da83e..b5316ec 100644 --- a/ExampleAnalysis/CMakeLists.txt +++ b/ExampleAnalysis/CMakeLists.txt @@ -40,13 +40,14 @@ set(PLUGIN_SOURCES src/ExampleAnalysisPlugin.json ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleData/CMakeLists.txt b/ExampleData/CMakeLists.txt index f03a81c..80ffe24 100644 --- a/ExampleData/CMakeLists.txt +++ b/ExampleData/CMakeLists.txt @@ -45,13 +45,14 @@ set(PLUGIN_HEADERS src/ExampleDataPlugin.h ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) target_sources(${PROJECT_NAME} PRIVATE ${PLUGIN_SOURCES} diff --git a/ExampleDependencies/CMakeLists.txt b/ExampleDependencies/CMakeLists.txt index 8d3807a..69ab509 100644 --- a/ExampleDependencies/CMakeLists.txt +++ b/ExampleDependencies/CMakeLists.txt @@ -59,13 +59,14 @@ set(PLUGIN_SOURCES src/ExampleDependenciesPlugin.json ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleLoader/CMakeLists.txt b/ExampleLoader/CMakeLists.txt index 0dd8b4c..eacbc5e 100644 --- a/ExampleLoader/CMakeLists.txt +++ b/ExampleLoader/CMakeLists.txt @@ -38,13 +38,14 @@ set(PLUGIN_SOURCES src/ExampleLoaderPlugin.json ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleTransformation/CMakeLists.txt b/ExampleTransformation/CMakeLists.txt index 4332be7..793c504 100644 --- a/ExampleTransformation/CMakeLists.txt +++ b/ExampleTransformation/CMakeLists.txt @@ -38,13 +38,14 @@ set(PLUGIN_SOURCES src/ExampleTransformationPlugin.json ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleView/CMakeLists.txt b/ExampleView/CMakeLists.txt index dab7ce3..fa1954e 100644 --- a/ExampleView/CMakeLists.txt +++ b/ExampleView/CMakeLists.txt @@ -42,13 +42,14 @@ set(PLUGIN_MOC_HEADERS src/ExampleViewPlugin.h ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleViewJS/CMakeLists.txt b/ExampleViewJS/CMakeLists.txt index 76bbb98..df9246a 100644 --- a/ExampleViewJS/CMakeLists.txt +++ b/ExampleViewJS/CMakeLists.txt @@ -55,15 +55,16 @@ set(AUX qt6_add_resources(RESOURCE_FILES res/example_chart.qrc) -source_group( Plugin FILES ${PLUGIN_SOURCES}) -source_group( Web FILES ${WEB}) -source_group( Aux FILES ${AUX}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Web FILES ${WEB}) +source_group(Aux FILES ${AUX}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${AUX} ${WEB} ${RESOURCE_FILES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${AUX} ${WEB} ${RESOURCE_FILES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleViewOpenGL/CMakeLists.txt b/ExampleViewOpenGL/CMakeLists.txt index 3aa20cf..bc99e3f 100644 --- a/ExampleViewOpenGL/CMakeLists.txt +++ b/ExampleViewOpenGL/CMakeLists.txt @@ -50,15 +50,16 @@ set(PLUGIN_ACTIONS src/GlobalSettingsAction.cpp ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) -source_group( Widget FILES ${PLUGIN_WIDGETS}) -source_group( Actions FILES ${PLUGIN_ACTIONS}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Widget FILES ${PLUGIN_WIDGETS}) +source_group(Actions FILES ${PLUGIN_ACTIONS}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${PLUGIN_WIDGETS} ${PLUGIN_ACTIONS}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${PLUGIN_WIDGETS} ${PLUGIN_ACTIONS} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories diff --git a/ExampleWriter/CMakeLists.txt b/ExampleWriter/CMakeLists.txt index 197ab8f..465bfc4 100644 --- a/ExampleWriter/CMakeLists.txt +++ b/ExampleWriter/CMakeLists.txt @@ -38,13 +38,14 @@ set(PLUGIN_SOURCES src/ExampleWriterPlugin.json ) -source_group( Plugin FILES ${PLUGIN_SOURCES}) +source_group(Plugin FILES ${PLUGIN_SOURCES}) +source_group(Common FILES ${COMMON_FILES}) # ----------------------------------------------------------------------------- # CMake Target # ----------------------------------------------------------------------------- # Create dynamic library for the plugin -add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES}) +add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Target include directories From 58780cffb654a42e065134ba59880c1ed567c322 Mon Sep 17 00:00:00 2001 From: Thomas Kroes Date: Wed, 5 Feb 2025 18:39:22 +0100 Subject: [PATCH 3/3] Use notification string from common --- Common/CMakeLists.txt | 4 ++-- Common/common.cpp | 16 ++++++++++++++++ Common/common.h | 5 +++++ ExampleAnalysis/CMakeLists.txt | 6 ++++++ ExampleAnalysis/src/ExampleAnalysisPlugin.cpp | 15 +++------------ ExampleData/CMakeLists.txt | 5 +++++ ExampleData/src/ExampleDataPlugin.cpp | 15 +++------------ ExampleDependencies/CMakeLists.txt | 5 +++++ .../src/ExampleDependenciesPlugin.cpp | 15 +++------------ ExampleLoader/CMakeLists.txt | 5 +++++ ExampleLoader/src/ExampleLoaderPlugin.cpp | 15 +++------------ ExampleTransformation/CMakeLists.txt | 5 +++++ .../src/ExampleTransformationPlugin.cpp | 15 +++------------ ExampleView/CMakeLists.txt | 5 +++++ ExampleView/src/ExampleViewPlugin.cpp | 15 +++------------ ExampleViewJS/CMakeLists.txt | 5 +++++ ExampleViewJS/src/ExampleViewJSPlugin.cpp | 15 +++------------ ExampleViewOpenGL/CMakeLists.txt | 5 +++++ ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp | 15 +++------------ ExampleWriter/CMakeLists.txt | 5 +++++ ExampleWriter/src/ExampleWriterPlugin.cpp | 15 +++------------ 21 files changed, 96 insertions(+), 110 deletions(-) diff --git a/Common/CMakeLists.txt b/Common/CMakeLists.txt index 960a680..36abc53 100644 --- a/Common/CMakeLists.txt +++ b/Common/CMakeLists.txt @@ -1,12 +1,12 @@ set(DIR ${CMAKE_CURRENT_SOURCE_DIR}) set(COMMON_HEADERS - ${DIR}/common.h + ${DIR}/Common.h PARENT_SCOPE ) set(COMMON_SOURCES - ${DIR}/common.cpp + ${DIR}/Common.cpp PARENT_SCOPE ) diff --git a/Common/common.cpp b/Common/common.cpp index e69de29..e1fa704 100644 --- a/Common/common.cpp +++ b/Common/common.cpp @@ -0,0 +1,16 @@ +#include "Common.h" + +QString getExampleNotificationMessage() +{ + return { "ManiVault Studio features a notification system that can be triggered from:
" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" }; +} diff --git a/Common/common.h b/Common/common.h index e69de29..db147c0 100644 --- a/Common/common.h +++ b/Common/common.h @@ -0,0 +1,5 @@ +#pragma once + +#include + +QString getExampleNotificationMessage(); diff --git a/ExampleAnalysis/CMakeLists.txt b/ExampleAnalysis/CMakeLists.txt index b5316ec..8fb697b 100644 --- a/ExampleAnalysis/CMakeLists.txt +++ b/ExampleAnalysis/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- @@ -54,6 +59,7 @@ add_library(${PROJECT_NAME} SHARED ${PLUGIN_SOURCES} ${COMMON_FILES}) # ----------------------------------------------------------------------------- # Include ManiVault headers, including system data plugins target_include_directories(${PROJECT_NAME} PRIVATE "${ManiVault_INCLUDE_DIR}") +target_include_directories(${PROJECT_NAME} PRIVATE Common) # ----------------------------------------------------------------------------- # Target properties diff --git a/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp b/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp index 46aa420..6180b5f 100644 --- a/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp +++ b/ExampleAnalysis/src/ExampleAnalysisPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleAnalysisPlugin.h" +#include "../Common/Common.h" + #include "PointData/PointData.h" #include @@ -161,18 +163,7 @@ void ExampleAnalysisPlugin::init() _eventListener.registerDataEventByType(PointType, std::bind(&ExampleAnalysisPlugin::onDataEvent, this, std::placeholders::_1)); - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleAnalysisPlugin::onDataEvent(mv::DatasetEvent* dataEvent) diff --git a/ExampleData/CMakeLists.txt b/ExampleData/CMakeLists.txt index 80ffe24..b3ca337 100644 --- a/ExampleData/CMakeLists.txt +++ b/ExampleData/CMakeLists.txt @@ -31,6 +31,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleData/src/ExampleDataPlugin.cpp b/ExampleData/src/ExampleDataPlugin.cpp index 145d014..81c96ee 100644 --- a/ExampleData/src/ExampleDataPlugin.cpp +++ b/ExampleData/src/ExampleDataPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleDataPlugin.h" +#include "../Common/Common.h" + #include "Application.h" #include @@ -17,18 +19,7 @@ ExampleDataPlugin::~ExampleDataPlugin(void) void ExampleDataPlugin::init() { - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } /** diff --git a/ExampleDependencies/CMakeLists.txt b/ExampleDependencies/CMakeLists.txt index 69ab509..b2828e0 100644 --- a/ExampleDependencies/CMakeLists.txt +++ b/ExampleDependencies/CMakeLists.txt @@ -47,6 +47,11 @@ if(${MV_EXAMPLES_USE_VCPKG}) endif() endif() +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleDependencies/src/ExampleDependenciesPlugin.cpp b/ExampleDependencies/src/ExampleDependenciesPlugin.cpp index 9f869fc..a2fec98 100644 --- a/ExampleDependencies/src/ExampleDependenciesPlugin.cpp +++ b/ExampleDependencies/src/ExampleDependenciesPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleDependenciesPlugin.h" +#include "../Common/Common.h" + #include #include @@ -51,18 +53,7 @@ void ExampleDependenciesPlugin::init() // Start the analysis when the user clicks the start analysis push button connect(&_settingsAction.getStartAnalysisAction(), &mv::gui::TriggerAction::triggered, this, &ExampleDependenciesPlugin::compute); - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleDependenciesPlugin::compute() diff --git a/ExampleLoader/CMakeLists.txt b/ExampleLoader/CMakeLists.txt index eacbc5e..569e0cd 100644 --- a/ExampleLoader/CMakeLists.txt +++ b/ExampleLoader/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleLoader/src/ExampleLoaderPlugin.cpp b/ExampleLoader/src/ExampleLoaderPlugin.cpp index 1370867..0ef67be 100644 --- a/ExampleLoader/src/ExampleLoaderPlugin.cpp +++ b/ExampleLoader/src/ExampleLoaderPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleLoaderPlugin.h" +#include "../Common/Common.h" + #include "PointData/PointData.h" #include "Set.h" @@ -35,18 +37,7 @@ ExampleLoaderPlugin::~ExampleLoaderPlugin(void) */ void ExampleLoaderPlugin::init() { - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } /** diff --git a/ExampleTransformation/CMakeLists.txt b/ExampleTransformation/CMakeLists.txt index 793c504..3501bd0 100644 --- a/ExampleTransformation/CMakeLists.txt +++ b/ExampleTransformation/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleTransformation/src/ExampleTransformationPlugin.cpp b/ExampleTransformation/src/ExampleTransformationPlugin.cpp index db800b1..5c01d5c 100644 --- a/ExampleTransformation/src/ExampleTransformationPlugin.cpp +++ b/ExampleTransformation/src/ExampleTransformationPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleTransformationPlugin.h" +#include "../Common/Common.h" + #include #include @@ -22,18 +24,7 @@ ExampleTransformationPlugin::ExampleTransformationPlugin(const PluginFactory* fa TransformationPlugin(factory), _type(Type::Abs) { - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleTransformationPlugin::transform() diff --git a/ExampleView/CMakeLists.txt b/ExampleView/CMakeLists.txt index fa1954e..693e433 100644 --- a/ExampleView/CMakeLists.txt +++ b/ExampleView/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleView/src/ExampleViewPlugin.cpp b/ExampleView/src/ExampleViewPlugin.cpp index c7946a0..c6f3c63 100644 --- a/ExampleView/src/ExampleViewPlugin.cpp +++ b/ExampleView/src/ExampleViewPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleViewPlugin.h" +#include "../Common/Common.h" + #include #include @@ -115,18 +117,7 @@ void ExampleViewPlugin::init() _eventListener.addSupportedEventType(static_cast(EventType::DatasetDataSelectionChanged)); _eventListener.registerDataEventByType(PointType, std::bind(&ExampleViewPlugin::onDataEvent, this, std::placeholders::_1)); - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleViewPlugin::onDataEvent(mv::DatasetEvent* dataEvent) diff --git a/ExampleViewJS/CMakeLists.txt b/ExampleViewJS/CMakeLists.txt index df9246a..61f206d 100644 --- a/ExampleViewJS/CMakeLists.txt +++ b/ExampleViewJS/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleViewJS/src/ExampleViewJSPlugin.cpp b/ExampleViewJS/src/ExampleViewJSPlugin.cpp index 7279ab6..115d87b 100644 --- a/ExampleViewJS/src/ExampleViewJSPlugin.cpp +++ b/ExampleViewJS/src/ExampleViewJSPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleViewJSPlugin.h" +#include "../Common/Common.h" + #include "ChartWidget.h" #include @@ -101,18 +103,7 @@ void ExampleViewJSPlugin::init() // Create data so that we do not need to load any in this example createData(); - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleViewJSPlugin::loadData(const mv::Datasets& datasets) diff --git a/ExampleViewOpenGL/CMakeLists.txt b/ExampleViewOpenGL/CMakeLists.txt index bc99e3f..e42f0d0 100644 --- a/ExampleViewOpenGL/CMakeLists.txt +++ b/ExampleViewOpenGL/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets OpenGL OpenGLWidgets REQUIR find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp b/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp index 4b1b557..cfd8874 100644 --- a/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp +++ b/ExampleViewOpenGL/src/ExampleViewGLPlugin.cpp @@ -1,6 +1,8 @@ #include "ExampleViewGLPlugin.h" #include "ExampleGLWidget.h" +#include "../Common/Common.h" + #include "GlobalSettingsAction.h" #include @@ -132,18 +134,7 @@ void ExampleViewGLPlugin::init() // Update the data when the scatter plot widget is initialized connect(_exampleGLWidget, &ExampleGLWidget::initialized, this, []() { qDebug() << "ExampleGLWidget is initialized."; } ); - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } void ExampleViewGLPlugin::updatePlot() diff --git a/ExampleWriter/CMakeLists.txt b/ExampleWriter/CMakeLists.txt index 465bfc4..dcbf1ae 100644 --- a/ExampleWriter/CMakeLists.txt +++ b/ExampleWriter/CMakeLists.txt @@ -28,6 +28,11 @@ find_package(Qt6 COMPONENTS Widgets WebEngineWidgets REQUIRED) find_package(ManiVault COMPONENTS Core PointData CONFIG QUIET) +# ----------------------------------------------------------------------------- +# Include Common directory +# ----------------------------------------------------------------------------- +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common) + # ----------------------------------------------------------------------------- # Source files # ----------------------------------------------------------------------------- diff --git a/ExampleWriter/src/ExampleWriterPlugin.cpp b/ExampleWriter/src/ExampleWriterPlugin.cpp index da18a6a..070fc70 100644 --- a/ExampleWriter/src/ExampleWriterPlugin.cpp +++ b/ExampleWriter/src/ExampleWriterPlugin.cpp @@ -1,5 +1,7 @@ #include "ExampleWriterPlugin.h" +#include "../Common/Common.h" + #include "PointData/PointData.h" #include @@ -33,18 +35,7 @@ ExampleWriterPlugin::~ExampleWriterPlugin(void) */ void ExampleWriterPlugin::init() { - addNotification("ManiVault Studio features a notification system that can be triggered from:
" - "" - "" - "" - "" - "" - "" - "" - "" - "" - "
Within a plugin: addNotification(...)
The help manager: mv::help().addNotification(...)
" - ); + addNotification(getExampleNotificationMessage()); } /**