From 31be23eddb92088fa3e40b00ae90bccf75b8be65 Mon Sep 17 00:00:00 2001 From: adv Date: Tue, 10 Sep 2013 05:31:56 +0000 Subject: [PATCH] HYDROData package gas been mergrd eith HYDROOperations. --- CMakeLists.txt | 1 - HYDRO.sln | 10 - src/HYDROData/CMakeLists.txt | 14 +- src/HYDROData/HYDROData.vcproj | 24 +++ .../HYDROOperations_BSpline.cxx | 0 .../HYDROOperations_BSpline.h | 4 +- .../HYDROOperations_Factory.cxx | 0 .../HYDROOperations_Factory.h | 12 +- .../test_HYDROOperations_BSpline.cxx | 0 .../test_HYDROOperations_BSpline.h | 0 .../test_HYDROOperations_Factory.cxx | 0 .../test_HYDROOperations_Factory.h | 0 src/HYDROGUI/HYDROGUI.vcproj | 8 +- src/HYDROOperations/CMakeLists.txt | 53 ------ src/HYDROOperations/HYDROOperations.h | 18 -- src/HYDROOperations/HYDROOperations.vcproj | 174 ------------------ .../test_HYDROOperations_Main.cxx | 54 ------ 17 files changed, 48 insertions(+), 324 deletions(-) rename src/{HYDROOperations => HYDROData}/HYDROOperations_BSpline.cxx (100%) rename src/{HYDROOperations => HYDROData}/HYDROOperations_BSpline.h (93%) rename src/{HYDROOperations => HYDROData}/HYDROOperations_Factory.cxx (100%) rename src/{HYDROOperations => HYDROData}/HYDROOperations_Factory.h (91%) rename src/{HYDROOperations => HYDROData}/test_HYDROOperations_BSpline.cxx (100%) rename src/{HYDROOperations => HYDROData}/test_HYDROOperations_BSpline.h (100%) rename src/{HYDROOperations => HYDROData}/test_HYDROOperations_Factory.cxx (100%) rename src/{HYDROOperations => HYDROData}/test_HYDROOperations_Factory.h (100%) delete mode 100644 src/HYDROOperations/CMakeLists.txt delete mode 100644 src/HYDROOperations/HYDROOperations.h delete mode 100644 src/HYDROOperations/HYDROOperations.vcproj delete mode 100644 src/HYDROOperations/test_HYDROOperations_Main.cxx diff --git a/CMakeLists.txt b/CMakeLists.txt index 8396e2a4..ffb6e673 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,7 +35,6 @@ find_package(SalomeCPPUNIT) set(HYDRO_salomeres_DATA share/salome/resources/hydro) add_subdirectory (src/HYDROData) -add_subdirectory (src/HYDROOperations) add_subdirectory (src/HYDROGUI) add_subdirectory (src/HYDROPy) diff --git a/HYDRO.sln b/HYDRO.sln index 52d0869c..c37bebb2 100644 --- a/HYDRO.sln +++ b/HYDRO.sln @@ -3,16 +3,10 @@ Microsoft Visual Studio Solution File, Format Version 10.00 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HYDROGUI", "src\HYDROGUI\HYDROGUI.vcproj", "{D11F0AD0-D002-4A22-A8E6-3F906379206F}" ProjectSection(ProjectDependencies) = postProject {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C} = {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C} - {6F9309FA-A798-4F2A-A04B-133EA58E50A9} = {6F9309FA-A798-4F2A-A04B-133EA58E50A9} EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HYDROData", "src\HYDROData\HYDROData.vcproj", "{EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HYDROOperations", "src\HYDROOperations\HYDROOperations.vcproj", "{6F9309FA-A798-4F2A-A04B-133EA58E50A9}" - ProjectSection(ProjectDependencies) = postProject - {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C} = {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C} - EndProjectSection -EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HYDROPy", "src\HYDROPy\HYDROPy.vcproj", "{72DE2E1A-BDE1-4BBE-8225-3D3DB2CC6C93}" EndProject Global @@ -29,10 +23,6 @@ Global {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C}.Debug|Win32.Build.0 = Debug|Win32 {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C}.Release|Win32.ActiveCfg = Debug|Win32 {EB7B7816-4EA0-4E7D-A88A-1417DEB0FC1C}.Release|Win32.Build.0 = Debug|Win32 - {6F9309FA-A798-4F2A-A04B-133EA58E50A9}.Debug|Win32.ActiveCfg = Debug|Win32 - {6F9309FA-A798-4F2A-A04B-133EA58E50A9}.Debug|Win32.Build.0 = Debug|Win32 - {6F9309FA-A798-4F2A-A04B-133EA58E50A9}.Release|Win32.ActiveCfg = Debug|Win32 - {6F9309FA-A798-4F2A-A04B-133EA58E50A9}.Release|Win32.Build.0 = Debug|Win32 {72DE2E1A-BDE1-4BBE-8225-3D3DB2CC6C93}.Debug|Win32.ActiveCfg = Debug|Win32 {72DE2E1A-BDE1-4BBE-8225-3D3DB2CC6C93}.Debug|Win32.Build.0 = Debug|Win32 {72DE2E1A-BDE1-4BBE-8225-3D3DB2CC6C93}.Release|Win32.ActiveCfg = Release|Win32 diff --git a/src/HYDROData/CMakeLists.txt b/src/HYDROData/CMakeLists.txt index ba4f85aa..3c169ed6 100644 --- a/src/HYDROData/CMakeLists.txt +++ b/src/HYDROData/CMakeLists.txt @@ -12,6 +12,9 @@ set(PROJECT_HEADERS HYDROData_Polyline.h HYDROData_VisualState.h HYDROData_Tool.h + HYDROOperations.h + HYDROOperations_Factory.h + HYDROOperations_BSpline.h ) set(PROJECT_SOURCES @@ -25,12 +28,15 @@ set(PROJECT_SOURCES HYDROData_Polyline.cxx HYDROData_VisualState.cxx HYDROData_Tool.cxx + HYDROOperations_Factory.cxx + HYDROOperations_BSpline.cxx ) add_definitions( -DHYDRODATA_EXPORTS ${CAS_DEFINITIONS} ${QT_DEFINITIONS} + ${GUI_CXXFLAGS} ) include_directories( @@ -40,7 +46,7 @@ include_directories( ) add_library(HYDROData SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS}) -target_link_libraries(HYDROData ${CAS_OCAF} ${QT_LIBRARIES}) +target_link_libraries(HYDROData ${CAS_OCAF} ${QT_LIBRARIES} ${CAS_TKG3d} ${CAS_TKGeomBase} ${CAS_TKGeomAlgo} ${ImageComposer}) set(PROJECT_LIBRARIES HYDROData) @@ -53,6 +59,8 @@ if(CPPUNIT_IS_OK) test_HYDROData_Iterator.h test_HYDROData_Image.h test_HYDROData_Polyline.h + test_HYDROOperations_BSpline.h + test_HYDROOperations_Factory.h ) set(TEST_SOURCES @@ -62,11 +70,13 @@ if(CPPUNIT_IS_OK) test_HYDROData_Iterator.cxx test_HYDROData_Image.cxx test_HYDROData_Polyline.cxx + test_HYDROOperations_BSpline.cxx + test_HYDROOperations_Factory.cxx ) set(TEST_EXE test_HYDROData) include(../../CMake/CPPUnitTests.cmake) - target_link_libraries(test_HYDROData ${CAS_OCAF} ${QT_LIBRARIES} ${CPPUNIT_LIBS} HYDROData) + target_link_libraries(test_HYDROData ${CAS_OCAF} ${CAS_MODELER} ${QT_LIBRARIES} ${CPPUNIT_LIBS} HYDROData) endif(CPPUNIT_IS_OK) diff --git a/src/HYDROData/HYDROData.vcproj b/src/HYDROData/HYDROData.vcproj index 9310c556..3b659e3f 100644 --- a/src/HYDROData/HYDROData.vcproj +++ b/src/HYDROData/HYDROData.vcproj @@ -177,6 +177,18 @@ > + + + + + + + + + + + + diff --git a/src/HYDROOperations/HYDROOperations_BSpline.cxx b/src/HYDROData/HYDROOperations_BSpline.cxx similarity index 100% rename from src/HYDROOperations/HYDROOperations_BSpline.cxx rename to src/HYDROData/HYDROOperations_BSpline.cxx diff --git a/src/HYDROOperations/HYDROOperations_BSpline.h b/src/HYDROData/HYDROOperations_BSpline.h similarity index 93% rename from src/HYDROOperations/HYDROOperations_BSpline.h rename to src/HYDROData/HYDROOperations_BSpline.h index 0fb9134f..47c3f305 100644 --- a/src/HYDROOperations/HYDROOperations_BSpline.h +++ b/src/HYDROData/HYDROOperations_BSpline.h @@ -1,7 +1,7 @@ #ifndef HYDROOperations_BSpline_HeaderFile #define HYDROOperations_BSpline_HeaderFile -#include +#include #include #include #include @@ -14,7 +14,7 @@ * manipulation and conversion. */ -class HYDROOPERATIONS_EXPORT HYDROOperations_BSpline +class HYDRODATA_EXPORT HYDROOperations_BSpline { public: diff --git a/src/HYDROOperations/HYDROOperations_Factory.cxx b/src/HYDROData/HYDROOperations_Factory.cxx similarity index 100% rename from src/HYDROOperations/HYDROOperations_Factory.cxx rename to src/HYDROData/HYDROOperations_Factory.cxx diff --git a/src/HYDROOperations/HYDROOperations_Factory.h b/src/HYDROData/HYDROOperations_Factory.h similarity index 91% rename from src/HYDROOperations/HYDROOperations_Factory.h rename to src/HYDROData/HYDROOperations_Factory.h index 0416e3b6..7ef2c0e0 100644 --- a/src/HYDROOperations/HYDROOperations_Factory.h +++ b/src/HYDROData/HYDROOperations_Factory.h @@ -1,7 +1,7 @@ #ifndef HYDROOperations_Factory_HeaderFile #define HYDROOperations_Factory_HeaderFile -#include +#include #include #include @@ -25,14 +25,14 @@ class HYDROOperations_Factory public: //! Returns the global factory - HYDROOPERATIONS_EXPORT static HYDROOperations_Factory* Factory(); + HYDRODATA_EXPORT static HYDROOperations_Factory* Factory(); /** * Registers the operator by the name, used by REGISTER_HYDRO_OPERATION macro * \param theOperator new instance of the operator that will be used for * processing of operation with such kind */ - HYDROOPERATIONS_EXPORT static void Register( + HYDRODATA_EXPORT static void Register( ImageComposer_Operator* theOperator); /** @@ -41,7 +41,7 @@ public: * \param theOperator base operator for this Image: will be used in "Update" to recompute the image * \returns created object related to the data structure */ - HYDROOPERATIONS_EXPORT Handle(HYDROData_Image) CreateImage( + HYDRODATA_EXPORT Handle(HYDROData_Image) CreateImage( Handle_HYDROData_Document theDoc, const ImageComposer_Operator* theOperator); /** @@ -50,7 +50,7 @@ public: * \param theDoc document of this image (needed to update other images flags) * \param theImage the updated image */ - HYDROOPERATIONS_EXPORT void UpdateImage( + HYDRODATA_EXPORT void UpdateImage( Handle_HYDROData_Document theDoc, Handle(HYDROData_Image) theImage); /** @@ -59,7 +59,7 @@ public: * required for creation of operation * \returns NULL if operator type is unknown */ - HYDROOPERATIONS_EXPORT ImageComposer_Operator* Operator( + HYDRODATA_EXPORT ImageComposer_Operator* Operator( Handle(HYDROData_Image) theImage) const; diff --git a/src/HYDROOperations/test_HYDROOperations_BSpline.cxx b/src/HYDROData/test_HYDROOperations_BSpline.cxx similarity index 100% rename from src/HYDROOperations/test_HYDROOperations_BSpline.cxx rename to src/HYDROData/test_HYDROOperations_BSpline.cxx diff --git a/src/HYDROOperations/test_HYDROOperations_BSpline.h b/src/HYDROData/test_HYDROOperations_BSpline.h similarity index 100% rename from src/HYDROOperations/test_HYDROOperations_BSpline.h rename to src/HYDROData/test_HYDROOperations_BSpline.h diff --git a/src/HYDROOperations/test_HYDROOperations_Factory.cxx b/src/HYDROData/test_HYDROOperations_Factory.cxx similarity index 100% rename from src/HYDROOperations/test_HYDROOperations_Factory.cxx rename to src/HYDROData/test_HYDROOperations_Factory.cxx diff --git a/src/HYDROOperations/test_HYDROOperations_Factory.h b/src/HYDROData/test_HYDROOperations_Factory.h similarity index 100% rename from src/HYDROOperations/test_HYDROOperations_Factory.h rename to src/HYDROData/test_HYDROOperations_Factory.h diff --git a/src/HYDROGUI/HYDROGUI.vcproj b/src/HYDROGUI/HYDROGUI.vcproj index 36723c6e..6394a14c 100644 --- a/src/HYDROGUI/HYDROGUI.vcproj +++ b/src/HYDROGUI/HYDROGUI.vcproj @@ -1,7 +1,7 @@ diff --git a/src/HYDROOperations/CMakeLists.txt b/src/HYDROOperations/CMakeLists.txt deleted file mode 100644 index 8dda9f0f..00000000 --- a/src/HYDROOperations/CMakeLists.txt +++ /dev/null @@ -1,53 +0,0 @@ -include(../../CMake/Common.cmake) - -set(PROJECT_HEADERS - HYDROOperations.h - HYDROOperations_Factory.h - HYDROOperations_BSpline.h -) - -set(PROJECT_SOURCES - HYDROOperations_Factory.cxx - HYDROOperations_BSpline.cxx -) - -add_definitions( - -DHYDROOPERATIONS_EXPORTS - ${CAS_DEFINITIONS} - ${QT_DEFINITIONS} - ${GUI_CXXFLAGS} -) - -include_directories( - ${CAS_INCLUDE_DIRS} - ${QT_INCLUDES} - ${CMAKE_CURRENT_SOURCE_DIR} - ${CMAKE_CURRENT_SOURCE_DIR}/../HYDROData -) - -add_library(HYDROOperations SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS}) -target_link_libraries(HYDROOperations ${CAS_TKG3d} ${CAS_TKGeomBase} ${CAS_TKGeomAlgo} ${ImageComposer} HYDROData) - -set(PROJECT_LIBRARIES HYDROOperations) - -# tests -if(CPPUNIT_IS_OK) - - set(TEST_HEADERS - test_HYDROOperations_BSpline.h - test_HYDROOperations_Factory.h - ) - - set(TEST_SOURCES - test_HYDROOperations_Main.cxx - test_HYDROOperations_BSpline.cxx - test_HYDROOperations_Factory.cxx - ) - - set(TEST_EXE test_HYDROOperations) - include(../../CMake/CPPUnitTests.cmake) - target_link_libraries(test_HYDROOperations ${CAS_MODELER} ${QT_LIBRARIES} ${CPPUNIT_LIBS} HYDROOperations) - -endif(CPPUNIT_IS_OK) - -include(../../CMake/CommonInstall.cmake) diff --git a/src/HYDROOperations/HYDROOperations.h b/src/HYDROOperations/HYDROOperations.h deleted file mode 100644 index feeaec5a..00000000 --- a/src/HYDROOperations/HYDROOperations.h +++ /dev/null @@ -1,18 +0,0 @@ -#ifndef HYDROOPERATIONS_H -#define HYDROOPERATIONS_H - -#if defined HYDROOPERATIONS_EXPORTS -#if defined WIN32 -#define HYDROOPERATIONS_EXPORT __declspec( dllexport ) -#else -#define HYDROOPERATIONS_EXPORT -#endif -#else -#if defined WIN32 -#define HYDROOPERATIONS_EXPORT __declspec( dllimport ) -#else -#define HYDROOPERATIONS_EXPORT -#endif -#endif - -#endif diff --git a/src/HYDROOperations/HYDROOperations.vcproj b/src/HYDROOperations/HYDROOperations.vcproj deleted file mode 100644 index ac2828d7..00000000 --- a/src/HYDROOperations/HYDROOperations.vcproj +++ /dev/null @@ -1,174 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/HYDROOperations/test_HYDROOperations_Main.cxx b/src/HYDROOperations/test_HYDROOperations_Main.cxx deleted file mode 100644 index 95900832..00000000 --- a/src/HYDROOperations/test_HYDROOperations_Main.cxx +++ /dev/null @@ -1,54 +0,0 @@ -#include -#include -#include -#include -#include -#include -#include -#include - -int - main( int argc, char* argv[] ) -{ - // to perform "drawing" qt tests - QApplication app(argc, argv); - - std::string testPath = (argc > 1) ? std::string(argv[1]) : ""; - - // Create the event manager and test controller - CppUnit::TestResult controller; - - // Add a listener that colllects test result - CppUnit::TestResultCollector result; - controller.addListener( &result ); - - // Add a listener that print dots as test run. - CppUnit::TextTestProgressListener progress; - controller.addListener( &progress ); - - CppUnit::TestFactoryRegistry& registry = - CppUnit::TestFactoryRegistry::getRegistry(); - // Add the top suite to the test runner - CppUnit::TestRunner runner; - runner.addTest( registry.makeTest() ); - try - { - std::cout << "Running " << testPath; - runner.run( controller, testPath ); - - std::cerr << std::endl; - - // Print test in a compiler compatible format. - CppUnit::CompilerOutputter outputter( &result, std::cerr ); - outputter.write(); - } - catch ( std::invalid_argument &e ) // Test path not resolved - { - std::cerr << std::endl - << "ERROR: " << e.what() - << std::endl; - return 0; - } - - return result.wasSuccessful() ? 0 : 1; -} -- 2.39.2