From: mzn Date: Thu, 20 Mar 2014 06:36:15 +0000 (+0000) Subject: Move z levels sources. X-Git-Tag: BR_hydro_v1_0_1~44 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d07d7ebf5fa5f6a479971cf7d7e56034c6e31db3;p=modules%2Fhydro.git Move z levels sources. --- diff --git a/src/HYDROGUI/CMakeLists.txt b/src/HYDROGUI/CMakeLists.txt index 612e9be9..1aa750d2 100644 --- a/src/HYDROGUI/CMakeLists.txt +++ b/src/HYDROGUI/CMakeLists.txt @@ -86,6 +86,8 @@ set(PROJECT_HEADERS HYDROGUI_BathymetryBoundsOp.h HYDROGUI_TranslateObstacleDlg.h HYDROGUI_TranslateObstacleOp.h + HYDROGUI_ZLevelsModel.h + HYDROGUI_ZLevelsDlg.h ) QT4_WRAP_CPP(PROJECT_HEADERS_MOC ${PROJECT_HEADERS}) @@ -173,6 +175,8 @@ set(PROJECT_SOURCES HYDROGUI_BathymetryBoundsOp.cxx HYDROGUI_TranslateObstacleDlg.cxx HYDROGUI_TranslateObstacleOp.cxx + HYDROGUI_ZLevelsModel.cxx + HYDROGUI_ZLevelsDlg.cxx ) add_definitions( @@ -227,3 +231,21 @@ FILE(GLOB GUIXML_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.xml") SET(GUI_DATA ${GUIPNG_DATA} ${GUIXML_DATA}) INSTALL(FILES ${GUI_DATA} DESTINATION ${SALOME_HYDRO_INSTALL_RES_DATA}) +# tests +if(SALOME_BUILD_TESTS) + + set(TEST_HEADERS + test_HYDROGUI_ZLevelsModel.h + ) + + set(TEST_SOURCES + test_HYDROGUI_Main.cxx + test_HYDROGUI_ZLevelsModel.cxx + ) + + set(TEST_EXE test_HYDROGUI) + include(../../CMake/CPPUnitTests.cmake) + target_link_libraries(test_HYDROGUI ${CAS_OCAF} ${CAS_MODELER} ${QT_LIBRARIES} ${CPPUNIT_LIBRARIES} HYDROData HYDROGUI) + +endif(SALOME_BUILD_TESTS) + diff --git a/src/HYDROGUI/HYDROGUI_ZLevelsDlg.cxx b/src/HYDROGUI/HYDROGUI_ZLevelsDlg.cxx new file mode 100644 index 00000000..bb899965 --- /dev/null +++ b/src/HYDROGUI/HYDROGUI_ZLevelsDlg.cxx @@ -0,0 +1,146 @@ +// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + +#include "HYDROGUI_ZLevelsDlg.h" +#include "HYDROGUI_ZLevelsModel.h" + +#include +#include +#include +#include +#include +#include + + +HYDROGUI_ZLevelsDlg::HYDROGUI_ZLevelsDlg( QWidget* theParent ) +: QDialog( theParent ) +{ + QVBoxLayout* aMainLayout = new QVBoxLayout( this ); + aMainLayout->setMargin( 5 ); + + QHBoxLayout* aListLayout = new QHBoxLayout(); + + myList = new QListView( this ); + myList->setSelectionMode( QAbstractItemView::ExtendedSelection ); + myList->setDragEnabled( true ); + myList->setAcceptDrops( true ); + myList->viewport()->setAcceptDrops( true ); + myList->setDropIndicatorShown( true ); + myList->setDragDropMode( QAbstractItemView::InternalMove ); + + HYDROGUI_ZLevelsModel* aModel = new HYDROGUI_ZLevelsModel(); + QSortFilterProxyModel* aFilteredModel = new QSortFilterProxyModel(); + aFilteredModel->setSourceModel( aModel ); + aFilteredModel->setFilterKeyColumn( 0 ); + aFilteredModel->setFilterRole( HYDROGUI_VisibleRole ); + + myList->setModel( aFilteredModel ); + + myTop = new QPushButton( tr("TOP") ); + myUp = new QPushButton( tr("UP") ); + myDown = new QPushButton( tr("DOWN") ); + myBottom = new QPushButton( tr("BOTTOM") ); + QVBoxLayout* aListButtonsLayout = new QVBoxLayout(); + aListButtonsLayout->addWidget( myTop ); + aListButtonsLayout->addWidget( myUp ); + aListButtonsLayout->addWidget( myDown ); + aListButtonsLayout->addWidget( myBottom ); + aListButtonsLayout->addStretch(); + aListLayout->addWidget( myList ); + aListLayout->addLayout( aListButtonsLayout ); + aMainLayout->addLayout( aListLayout ); + + myAllObjects = new QCheckBox( tr( "ALL_OBJECTS" ) ); + aMainLayout->addWidget( myAllObjects ); + + QHBoxLayout* aDlgButtonsLayout = new QHBoxLayout(); + myApply = new QPushButton( tr("APPLY") ); + myClose = new QPushButton( tr("CLOSE") ); + aDlgButtonsLayout->addWidget( myApply ); + aDlgButtonsLayout->addWidget( myClose ); + aDlgButtonsLayout->addStretch(); + aMainLayout->addLayout( aDlgButtonsLayout ); + + QSignalMapper* aSignalMapper = new QSignalMapper( this ); + aSignalMapper->setMapping( myTop, HYDROGUI_ZLevelsModel::Top ); + aSignalMapper->setMapping( myUp, HYDROGUI_ZLevelsModel::Up ); + aSignalMapper->setMapping( myDown, HYDROGUI_ZLevelsModel::Down ); + aSignalMapper->setMapping( myBottom, HYDROGUI_ZLevelsModel::Bottom ); + connect( myTop, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); + connect( myUp, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); + connect( myDown, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); + connect( myBottom, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); + connect( aSignalMapper, SIGNAL( mapped( int ) ), this, SLOT( onMove( int ) ) ); + + connect( myAllObjects, SIGNAL( stateChanged( int ) ), this, SLOT( OnStateChanged() ) ); + + connect( myClose, SIGNAL( clicked() ), this, SLOT( close() ) ); + + OnStateChanged(); +} + +HYDROGUI_ZLevelsDlg::~HYDROGUI_ZLevelsDlg() +{ +} + +void HYDROGUI_ZLevelsDlg::setObjects( const QList& theObjects ) +{ + QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); + if( aFilterModel ) + { + HYDROGUI_ZLevelsModel* aModel = dynamic_cast( aFilterModel->sourceModel() ); + if( aModel ) { + // TODO: to be reimplemented + QList> anObjects; + for ( int i = 0; i < theObjects.count(); i++ ) { + anObjects << QPair( theObjects.at(i), i%2 == 0 ); + } + aModel->setObjects( anObjects ); + } + } +} + +void HYDROGUI_ZLevelsDlg::onMove( int theType ) +{ + QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); + if( aFilterModel ) { + HYDROGUI_ZLevelsModel* aModel = dynamic_cast( aFilterModel->sourceModel() ); + if( aModel ) { + QModelIndexList aSelectedIndexes = myList->selectionModel()->selectedIndexes(); + QModelIndexList aSelectedSourceIndexes; + foreach ( const QModelIndex& anIndex, aSelectedIndexes ) { + aSelectedSourceIndexes << aFilterModel->mapToSource( anIndex ); + } + QList aSelectedIds = aModel->getIds( aSelectedSourceIndexes ); + aModel->move( aSelectedIds, ( HYDROGUI_ZLevelsModel::OpType )theType, + !myAllObjects->isChecked() ); + } + } +} + +void HYDROGUI_ZLevelsDlg::OnStateChanged() +{ + QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); + bool isAll = myAllObjects->isChecked(); + QString anExpr = isAll ? "true|false" : "true"; + aFilterModel->setFilterRegExp( anExpr ); +} diff --git a/src/HYDROGUI/HYDROGUI_ZLevelsDlg.h b/src/HYDROGUI/HYDROGUI_ZLevelsDlg.h new file mode 100644 index 00000000..2ca17ef2 --- /dev/null +++ b/src/HYDROGUI/HYDROGUI_ZLevelsDlg.h @@ -0,0 +1,61 @@ +// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + +#ifndef HYDROGUI_ZLEVELSPANEL_H +#define HYDROGUI_ZLEVELSPANEL_H + +#include + +class QCheckBox; +class QListView; +class QPushButton; + +/** + * \class HYDROGUI_ZLevelsDlg + * \brief The class representing widget for managing Z levels + */ +class HYDROGUI_ZLevelsDlg : public QDialog +{ + Q_OBJECT + +public: + HYDROGUI_ZLevelsDlg( QWidget* theParent ); + virtual ~HYDROGUI_ZLevelsDlg(); + + void setObjects( const QList& theObjects ); + +private slots: + void onMove( int theType ); + void OnStateChanged(); + +private: + QListView* myList; + QPushButton* myTop; + QPushButton* myUp; + QPushButton* myDown; + QPushButton* myBottom; + QCheckBox* myAllObjects; + QPushButton* myApply; + QPushButton* myClose; +}; + +#endif diff --git a/src/HYDROGUI/HYDROGUI_ZLevelsModel.cxx b/src/HYDROGUI/HYDROGUI_ZLevelsModel.cxx new file mode 100644 index 00000000..f4ac8eae --- /dev/null +++ b/src/HYDROGUI/HYDROGUI_ZLevelsModel.cxx @@ -0,0 +1,294 @@ +// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + +#include "HYDROGUI_ZLevelsModel.h" +#include + +const QString OBJ_LIST_MIME_TYPE = "application/hydro.objects.list"; + +HYDROGUI_ZLevelsModel::HYDROGUI_ZLevelsModel( QObject* theParent ) + : QAbstractListModel( theParent ) +{ + myEmpty = QPixmap( 16, 16 ); + myEmpty.fill( Qt::white ); + myEye = QPixmap( "eye.png" );//TODO: loading from resources + setSupportedDragActions( Qt::MoveAction | Qt::CopyAction ); +} + +HYDROGUI_ZLevelsModel::~HYDROGUI_ZLevelsModel() +{ +} + +QVariant HYDROGUI_ZLevelsModel::data( const QModelIndex &theIndex, int theRole ) const +{ + QVariant aVariant; + + int aRow = theIndex.row(); + int aColumn = theIndex.column(); + + switch( theRole ) + { + case Qt::DisplayRole: + { + if( aColumn==0 && aRow >=0 && aRow < myObjects.count() ) + return myObjects.at( aRow ).first; + else + return QVariant(); + } + break; + + case Qt::DecorationRole: + { + if( aColumn==0 && aRow >=0 && aRow < myObjects.count() ) + { + bool isVisible = IsObjectVisible( aRow ); + if( isVisible ) + return myEye; + else + return myEmpty; + } + return QVariant(); + } + break; + + case HYDROGUI_VisibleRole: + { + bool isVisible = IsObjectVisible( aRow ); + return QVariant( isVisible ).toString(); + } + break; + } + + return aVariant; +} + +int HYDROGUI_ZLevelsModel::rowCount( const QModelIndex &theParent ) const +{ + return myObjects.count(); +} + +void HYDROGUI_ZLevelsModel::setObjects( const QList>& theObjects ) +{ + myObjects = theObjects; + + reset(); +} + +bool HYDROGUI_ZLevelsModel::IsObjectVisible( int theIndex ) const +{ + bool isVisible = false; + + if ( theIndex >= 0 && theIndex < myObjects.count() ) { + isVisible = myObjects.at( theIndex ).second; + } + + return isVisible; +} + +QVariant HYDROGUI_ZLevelsModel::headerData( int theSection, + Qt::Orientation theOrientation, + int theRole ) const +{ + if( theOrientation==Qt::Horizontal && theRole==Qt::DisplayRole ) + { + switch( theSection ) + { + case 0: + return tr( "VISIBLE" ); + case 1: + return tr( "OBJECT_NAME" ); + }; + } + return QVariant(); +} + +Qt::ItemFlags HYDROGUI_ZLevelsModel::flags( const QModelIndex& theIndex ) const +{ + Qt::ItemFlags aDefaultFlags = QAbstractListModel::flags( theIndex ); + if( theIndex.isValid() ) + return Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled | aDefaultFlags; + else + return Qt::ItemIsDropEnabled | aDefaultFlags; +} + +QMimeData* HYDROGUI_ZLevelsModel::mimeData( const QModelIndexList& theIndices ) const +{ + QMimeData* aMimeData = new QMimeData(); + QByteArray anEncodedData; + QDataStream aStream( &anEncodedData, QIODevice::WriteOnly ); + + QList anIdsList = getIds( theIndices ); + foreach( int anId, anIdsList ) + aStream << anId; + + aMimeData->setData( OBJ_LIST_MIME_TYPE, anEncodedData ); + return aMimeData; +} + +QStringList HYDROGUI_ZLevelsModel::mimeTypes() const +{ + QStringList aTypes; + aTypes << OBJ_LIST_MIME_TYPE; + return aTypes; +} + +bool HYDROGUI_ZLevelsModel::dropMimeData( const QMimeData* theData, Qt::DropAction theAction, + int theRow, int theColumn, const QModelIndex& theParent ) +{ + if( theAction == Qt::IgnoreAction) + return true; + + if( !theData->hasFormat( OBJ_LIST_MIME_TYPE )) + return false; + + if( theColumn > 0 ) + return false; + + int aDropItemId = theParent.row(); + + QByteArray anEncodedData = theData->data( OBJ_LIST_MIME_TYPE ); + QDataStream aStream( &anEncodedData, QIODevice::ReadOnly ); + QList anIdsList; + while( !aStream.atEnd() ) + { + int anId; + aStream >> anId; + anIdsList << anId; + } + move( anIdsList, DragAndDrop, aDropItemId ); + return true; +} + +Qt::DropActions HYDROGUI_ZLevelsModel::supportedDropActions() const +{ + return Qt::MoveAction | Qt::CopyAction; +} + +QList HYDROGUI_ZLevelsModel::getIds( const QModelIndexList& theIndexes, bool theIsToSort ) const +{ + QList anIds; + foreach( const QModelIndex& anIndex, theIndexes ) { + anIds << anIndex.row(); + } + + if ( theIsToSort ) { + qSort( anIds ); + } + + return anIds; +} + +bool HYDROGUI_ZLevelsModel::move( const int theItem, const OpType theType, + bool theIsVisibleOnly, const int theDropItem ) +{ + bool aRes = false; + if ( theItem < 0 || theItem >= myObjects.count() ) { + return aRes; + } + + int aDestinationIndex = -1; + + switch ( theType ) { + case Up: + if ( theItem > 0 ) { + aDestinationIndex = theItem - 1; + if ( theIsVisibleOnly ) { + while ( aDestinationIndex >= 0 && !IsObjectVisible( aDestinationIndex ) ) { + aDestinationIndex--; + } + } + } + break; + case Down: + if ( theItem < myObjects.count() - 1 ) { + aDestinationIndex = theItem + 1; + if ( theIsVisibleOnly ) { + while ( aDestinationIndex < myObjects.count() && !IsObjectVisible( aDestinationIndex ) ) { + aDestinationIndex++; + } + } + } + break; + case Top: + if ( theItem > 0 ) { + aDestinationIndex = 0; + } + break; + case Bottom: + if ( theItem < myObjects.count() - 1 ) { + aDestinationIndex = myObjects.count() - 1; + } + break; + } + + if ( aDestinationIndex >= 0 && aDestinationIndex < myObjects.count() ) { + int aDestinationRow = (theType == Up || theType == Top) ? aDestinationIndex : aDestinationIndex + 1; + if ( beginMoveRows( QModelIndex(), theItem, theItem, QModelIndex(), aDestinationRow ) ) { + myObjects.move( theItem, aDestinationIndex ); + endMoveRows(); + aRes = true; + } + } + + return aRes; +} + +bool HYDROGUI_ZLevelsModel::move( const QList& theItems, const OpType theType, + bool theIsVisibleOnly, const int theDropItem ) +{ + bool aRes = true; + + bool isReverse = theType == Top || theType == Down; + QListIterator anIt( theItems ); + int aShift = 0; + if ( isReverse ) { + anIt.toBack(); + while ( anIt.hasPrevious() ) { + int anId = anIt.previous(); + if ( theType == Top ) { + anId += aShift; + aShift++; + } + if ( !move( anId, theType, theIsVisibleOnly, theDropItem ) ) { + aRes = false; + break; + } + } + } else { + while ( anIt.hasNext() ) { + int anId = anIt.next(); + if ( theType == Bottom ) { + anId -= aShift; + aShift++; + } + if ( !move( anId, theType, theIsVisibleOnly, theDropItem ) ) { + aRes = false; + break; + } + } + } + + // reset(); //TODO dataChanged? + + return aRes; +} + diff --git a/src/HYDROGUI/HYDROGUI_ZLevelsModel.h b/src/HYDROGUI/HYDROGUI_ZLevelsModel.h new file mode 100644 index 00000000..62c5f1b9 --- /dev/null +++ b/src/HYDROGUI/HYDROGUI_ZLevelsModel.h @@ -0,0 +1,77 @@ +// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + +#ifndef HYDROGUI_ZLEVELSMODEL_H +#define HYDROGUI_ZLEVELSMODEL_H + +#include +#include + +const int HYDROGUI_VisibleRole = Qt::UserRole + 1; + +/** + * \class HYDROGUI_ZLevelsModel + * \brief The class representing custom list model for the Z levels + */ +class HYDROGUI_ZLevelsModel : public QAbstractListModel +{ + Q_OBJECT + +public: + enum OpType { Top, Up, Down, Bottom, DragAndDrop }; + +public: + HYDROGUI_ZLevelsModel( QObject* theParent = 0 ); + virtual ~HYDROGUI_ZLevelsModel(); + + virtual QVariant data( const QModelIndex &theIndex, int theRole = Qt::DisplayRole ) const; + + virtual int rowCount( const QModelIndex &theParent = QModelIndex() ) const; + + virtual QVariant headerData( int theSection, + Qt::Orientation theOrientation, + int theRole = Qt::DisplayRole ) const; + virtual Qt::ItemFlags flags( const QModelIndex& theIndex ) const; + virtual QMimeData* mimeData( const QModelIndexList& theIndices ) const; + virtual QStringList mimeTypes() const; + virtual bool dropMimeData( const QMimeData* theData, Qt::DropAction theAction, + int theRow, int theColumn, const QModelIndex& theParent ); + virtual Qt::DropActions supportedDropActions() const; + + QList getIds( const QModelIndexList& theIndexes, bool theIsToSort = true ) const; + + void setObjects( const QList>& theObjects ); + + bool move( const int theItem, const OpType theType, bool theIsVisibleOnly, + const int theDropItem = -1 ); + bool move( const QList& theItems, const OpType theType, bool theIsVisibleOnly, + const int theDropItem = -1 ); + +protected: + bool IsObjectVisible( int theIndex ) const; + +private: + QList> myObjects; + QPixmap myEmpty, myEye; +}; + +#endif \ No newline at end of file diff --git a/src/HYDROGUI/test_HYDROGUI_Main.cxx b/src/HYDROGUI/test_HYDROGUI_Main.cxx new file mode 100644 index 00000000..67971549 --- /dev/null +++ b/src/HYDROGUI/test_HYDROGUI_Main.cxx @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include +#include +#include + +int + main( int argc, char* 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; +} diff --git a/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.cxx b/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.cxx new file mode 100644 index 00000000..3bbc4b5c --- /dev/null +++ b/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.cxx @@ -0,0 +1,7 @@ +#include + + +void test_HYDROGUI_ZLevelsModel::testMoveUp() +{ + CPPUNIT_ASSERT(1 == 2); +} diff --git a/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.h b/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.h new file mode 100644 index 00000000..eb8d5efb --- /dev/null +++ b/src/HYDROGUI/test_HYDROGUI_ZLevelsModel.h @@ -0,0 +1,17 @@ +#include + +class test_HYDROGUI_ZLevelsModel : public CppUnit::TestFixture { + CPPUNIT_TEST_SUITE(test_HYDROGUI_ZLevelsModel); + CPPUNIT_TEST(testMoveUp); + CPPUNIT_TEST_SUITE_END(); + +private: + +public: + + // checks move up + void testMoveUp(); +}; + +CPPUNIT_TEST_SUITE_REGISTRATION(test_HYDROGUI_ZLevelsModel); +CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(test_HYDROGUI_ZLevelsModel, "HYDROGUI_ZLevelsModel"); diff --git a/src/ZLEVEL/HYDROGUI_ZLevelsDlg.cxx b/src/ZLEVEL/HYDROGUI_ZLevelsDlg.cxx deleted file mode 100644 index bb899965..00000000 --- a/src/ZLEVEL/HYDROGUI_ZLevelsDlg.cxx +++ /dev/null @@ -1,146 +0,0 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// - -#include "HYDROGUI_ZLevelsDlg.h" -#include "HYDROGUI_ZLevelsModel.h" - -#include -#include -#include -#include -#include -#include - - -HYDROGUI_ZLevelsDlg::HYDROGUI_ZLevelsDlg( QWidget* theParent ) -: QDialog( theParent ) -{ - QVBoxLayout* aMainLayout = new QVBoxLayout( this ); - aMainLayout->setMargin( 5 ); - - QHBoxLayout* aListLayout = new QHBoxLayout(); - - myList = new QListView( this ); - myList->setSelectionMode( QAbstractItemView::ExtendedSelection ); - myList->setDragEnabled( true ); - myList->setAcceptDrops( true ); - myList->viewport()->setAcceptDrops( true ); - myList->setDropIndicatorShown( true ); - myList->setDragDropMode( QAbstractItemView::InternalMove ); - - HYDROGUI_ZLevelsModel* aModel = new HYDROGUI_ZLevelsModel(); - QSortFilterProxyModel* aFilteredModel = new QSortFilterProxyModel(); - aFilteredModel->setSourceModel( aModel ); - aFilteredModel->setFilterKeyColumn( 0 ); - aFilteredModel->setFilterRole( HYDROGUI_VisibleRole ); - - myList->setModel( aFilteredModel ); - - myTop = new QPushButton( tr("TOP") ); - myUp = new QPushButton( tr("UP") ); - myDown = new QPushButton( tr("DOWN") ); - myBottom = new QPushButton( tr("BOTTOM") ); - QVBoxLayout* aListButtonsLayout = new QVBoxLayout(); - aListButtonsLayout->addWidget( myTop ); - aListButtonsLayout->addWidget( myUp ); - aListButtonsLayout->addWidget( myDown ); - aListButtonsLayout->addWidget( myBottom ); - aListButtonsLayout->addStretch(); - aListLayout->addWidget( myList ); - aListLayout->addLayout( aListButtonsLayout ); - aMainLayout->addLayout( aListLayout ); - - myAllObjects = new QCheckBox( tr( "ALL_OBJECTS" ) ); - aMainLayout->addWidget( myAllObjects ); - - QHBoxLayout* aDlgButtonsLayout = new QHBoxLayout(); - myApply = new QPushButton( tr("APPLY") ); - myClose = new QPushButton( tr("CLOSE") ); - aDlgButtonsLayout->addWidget( myApply ); - aDlgButtonsLayout->addWidget( myClose ); - aDlgButtonsLayout->addStretch(); - aMainLayout->addLayout( aDlgButtonsLayout ); - - QSignalMapper* aSignalMapper = new QSignalMapper( this ); - aSignalMapper->setMapping( myTop, HYDROGUI_ZLevelsModel::Top ); - aSignalMapper->setMapping( myUp, HYDROGUI_ZLevelsModel::Up ); - aSignalMapper->setMapping( myDown, HYDROGUI_ZLevelsModel::Down ); - aSignalMapper->setMapping( myBottom, HYDROGUI_ZLevelsModel::Bottom ); - connect( myTop, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); - connect( myUp, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); - connect( myDown, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); - connect( myBottom, SIGNAL( clicked() ), aSignalMapper, SLOT( map() ) ); - connect( aSignalMapper, SIGNAL( mapped( int ) ), this, SLOT( onMove( int ) ) ); - - connect( myAllObjects, SIGNAL( stateChanged( int ) ), this, SLOT( OnStateChanged() ) ); - - connect( myClose, SIGNAL( clicked() ), this, SLOT( close() ) ); - - OnStateChanged(); -} - -HYDROGUI_ZLevelsDlg::~HYDROGUI_ZLevelsDlg() -{ -} - -void HYDROGUI_ZLevelsDlg::setObjects( const QList& theObjects ) -{ - QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); - if( aFilterModel ) - { - HYDROGUI_ZLevelsModel* aModel = dynamic_cast( aFilterModel->sourceModel() ); - if( aModel ) { - // TODO: to be reimplemented - QList> anObjects; - for ( int i = 0; i < theObjects.count(); i++ ) { - anObjects << QPair( theObjects.at(i), i%2 == 0 ); - } - aModel->setObjects( anObjects ); - } - } -} - -void HYDROGUI_ZLevelsDlg::onMove( int theType ) -{ - QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); - if( aFilterModel ) { - HYDROGUI_ZLevelsModel* aModel = dynamic_cast( aFilterModel->sourceModel() ); - if( aModel ) { - QModelIndexList aSelectedIndexes = myList->selectionModel()->selectedIndexes(); - QModelIndexList aSelectedSourceIndexes; - foreach ( const QModelIndex& anIndex, aSelectedIndexes ) { - aSelectedSourceIndexes << aFilterModel->mapToSource( anIndex ); - } - QList aSelectedIds = aModel->getIds( aSelectedSourceIndexes ); - aModel->move( aSelectedIds, ( HYDROGUI_ZLevelsModel::OpType )theType, - !myAllObjects->isChecked() ); - } - } -} - -void HYDROGUI_ZLevelsDlg::OnStateChanged() -{ - QSortFilterProxyModel* aFilterModel = dynamic_cast( myList->model() ); - bool isAll = myAllObjects->isChecked(); - QString anExpr = isAll ? "true|false" : "true"; - aFilterModel->setFilterRegExp( anExpr ); -} diff --git a/src/ZLEVEL/HYDROGUI_ZLevelsDlg.h b/src/ZLEVEL/HYDROGUI_ZLevelsDlg.h deleted file mode 100644 index 2ca17ef2..00000000 --- a/src/ZLEVEL/HYDROGUI_ZLevelsDlg.h +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// - -#ifndef HYDROGUI_ZLEVELSPANEL_H -#define HYDROGUI_ZLEVELSPANEL_H - -#include - -class QCheckBox; -class QListView; -class QPushButton; - -/** - * \class HYDROGUI_ZLevelsDlg - * \brief The class representing widget for managing Z levels - */ -class HYDROGUI_ZLevelsDlg : public QDialog -{ - Q_OBJECT - -public: - HYDROGUI_ZLevelsDlg( QWidget* theParent ); - virtual ~HYDROGUI_ZLevelsDlg(); - - void setObjects( const QList& theObjects ); - -private slots: - void onMove( int theType ); - void OnStateChanged(); - -private: - QListView* myList; - QPushButton* myTop; - QPushButton* myUp; - QPushButton* myDown; - QPushButton* myBottom; - QCheckBox* myAllObjects; - QPushButton* myApply; - QPushButton* myClose; -}; - -#endif diff --git a/src/ZLEVEL/HYDROGUI_ZLevelsModel.cxx b/src/ZLEVEL/HYDROGUI_ZLevelsModel.cxx deleted file mode 100644 index f4ac8eae..00000000 --- a/src/ZLEVEL/HYDROGUI_ZLevelsModel.cxx +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// - -#include "HYDROGUI_ZLevelsModel.h" -#include - -const QString OBJ_LIST_MIME_TYPE = "application/hydro.objects.list"; - -HYDROGUI_ZLevelsModel::HYDROGUI_ZLevelsModel( QObject* theParent ) - : QAbstractListModel( theParent ) -{ - myEmpty = QPixmap( 16, 16 ); - myEmpty.fill( Qt::white ); - myEye = QPixmap( "eye.png" );//TODO: loading from resources - setSupportedDragActions( Qt::MoveAction | Qt::CopyAction ); -} - -HYDROGUI_ZLevelsModel::~HYDROGUI_ZLevelsModel() -{ -} - -QVariant HYDROGUI_ZLevelsModel::data( const QModelIndex &theIndex, int theRole ) const -{ - QVariant aVariant; - - int aRow = theIndex.row(); - int aColumn = theIndex.column(); - - switch( theRole ) - { - case Qt::DisplayRole: - { - if( aColumn==0 && aRow >=0 && aRow < myObjects.count() ) - return myObjects.at( aRow ).first; - else - return QVariant(); - } - break; - - case Qt::DecorationRole: - { - if( aColumn==0 && aRow >=0 && aRow < myObjects.count() ) - { - bool isVisible = IsObjectVisible( aRow ); - if( isVisible ) - return myEye; - else - return myEmpty; - } - return QVariant(); - } - break; - - case HYDROGUI_VisibleRole: - { - bool isVisible = IsObjectVisible( aRow ); - return QVariant( isVisible ).toString(); - } - break; - } - - return aVariant; -} - -int HYDROGUI_ZLevelsModel::rowCount( const QModelIndex &theParent ) const -{ - return myObjects.count(); -} - -void HYDROGUI_ZLevelsModel::setObjects( const QList>& theObjects ) -{ - myObjects = theObjects; - - reset(); -} - -bool HYDROGUI_ZLevelsModel::IsObjectVisible( int theIndex ) const -{ - bool isVisible = false; - - if ( theIndex >= 0 && theIndex < myObjects.count() ) { - isVisible = myObjects.at( theIndex ).second; - } - - return isVisible; -} - -QVariant HYDROGUI_ZLevelsModel::headerData( int theSection, - Qt::Orientation theOrientation, - int theRole ) const -{ - if( theOrientation==Qt::Horizontal && theRole==Qt::DisplayRole ) - { - switch( theSection ) - { - case 0: - return tr( "VISIBLE" ); - case 1: - return tr( "OBJECT_NAME" ); - }; - } - return QVariant(); -} - -Qt::ItemFlags HYDROGUI_ZLevelsModel::flags( const QModelIndex& theIndex ) const -{ - Qt::ItemFlags aDefaultFlags = QAbstractListModel::flags( theIndex ); - if( theIndex.isValid() ) - return Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled | aDefaultFlags; - else - return Qt::ItemIsDropEnabled | aDefaultFlags; -} - -QMimeData* HYDROGUI_ZLevelsModel::mimeData( const QModelIndexList& theIndices ) const -{ - QMimeData* aMimeData = new QMimeData(); - QByteArray anEncodedData; - QDataStream aStream( &anEncodedData, QIODevice::WriteOnly ); - - QList anIdsList = getIds( theIndices ); - foreach( int anId, anIdsList ) - aStream << anId; - - aMimeData->setData( OBJ_LIST_MIME_TYPE, anEncodedData ); - return aMimeData; -} - -QStringList HYDROGUI_ZLevelsModel::mimeTypes() const -{ - QStringList aTypes; - aTypes << OBJ_LIST_MIME_TYPE; - return aTypes; -} - -bool HYDROGUI_ZLevelsModel::dropMimeData( const QMimeData* theData, Qt::DropAction theAction, - int theRow, int theColumn, const QModelIndex& theParent ) -{ - if( theAction == Qt::IgnoreAction) - return true; - - if( !theData->hasFormat( OBJ_LIST_MIME_TYPE )) - return false; - - if( theColumn > 0 ) - return false; - - int aDropItemId = theParent.row(); - - QByteArray anEncodedData = theData->data( OBJ_LIST_MIME_TYPE ); - QDataStream aStream( &anEncodedData, QIODevice::ReadOnly ); - QList anIdsList; - while( !aStream.atEnd() ) - { - int anId; - aStream >> anId; - anIdsList << anId; - } - move( anIdsList, DragAndDrop, aDropItemId ); - return true; -} - -Qt::DropActions HYDROGUI_ZLevelsModel::supportedDropActions() const -{ - return Qt::MoveAction | Qt::CopyAction; -} - -QList HYDROGUI_ZLevelsModel::getIds( const QModelIndexList& theIndexes, bool theIsToSort ) const -{ - QList anIds; - foreach( const QModelIndex& anIndex, theIndexes ) { - anIds << anIndex.row(); - } - - if ( theIsToSort ) { - qSort( anIds ); - } - - return anIds; -} - -bool HYDROGUI_ZLevelsModel::move( const int theItem, const OpType theType, - bool theIsVisibleOnly, const int theDropItem ) -{ - bool aRes = false; - if ( theItem < 0 || theItem >= myObjects.count() ) { - return aRes; - } - - int aDestinationIndex = -1; - - switch ( theType ) { - case Up: - if ( theItem > 0 ) { - aDestinationIndex = theItem - 1; - if ( theIsVisibleOnly ) { - while ( aDestinationIndex >= 0 && !IsObjectVisible( aDestinationIndex ) ) { - aDestinationIndex--; - } - } - } - break; - case Down: - if ( theItem < myObjects.count() - 1 ) { - aDestinationIndex = theItem + 1; - if ( theIsVisibleOnly ) { - while ( aDestinationIndex < myObjects.count() && !IsObjectVisible( aDestinationIndex ) ) { - aDestinationIndex++; - } - } - } - break; - case Top: - if ( theItem > 0 ) { - aDestinationIndex = 0; - } - break; - case Bottom: - if ( theItem < myObjects.count() - 1 ) { - aDestinationIndex = myObjects.count() - 1; - } - break; - } - - if ( aDestinationIndex >= 0 && aDestinationIndex < myObjects.count() ) { - int aDestinationRow = (theType == Up || theType == Top) ? aDestinationIndex : aDestinationIndex + 1; - if ( beginMoveRows( QModelIndex(), theItem, theItem, QModelIndex(), aDestinationRow ) ) { - myObjects.move( theItem, aDestinationIndex ); - endMoveRows(); - aRes = true; - } - } - - return aRes; -} - -bool HYDROGUI_ZLevelsModel::move( const QList& theItems, const OpType theType, - bool theIsVisibleOnly, const int theDropItem ) -{ - bool aRes = true; - - bool isReverse = theType == Top || theType == Down; - QListIterator anIt( theItems ); - int aShift = 0; - if ( isReverse ) { - anIt.toBack(); - while ( anIt.hasPrevious() ) { - int anId = anIt.previous(); - if ( theType == Top ) { - anId += aShift; - aShift++; - } - if ( !move( anId, theType, theIsVisibleOnly, theDropItem ) ) { - aRes = false; - break; - } - } - } else { - while ( anIt.hasNext() ) { - int anId = anIt.next(); - if ( theType == Bottom ) { - anId -= aShift; - aShift++; - } - if ( !move( anId, theType, theIsVisibleOnly, theDropItem ) ) { - aRes = false; - break; - } - } - } - - // reset(); //TODO dataChanged? - - return aRes; -} - diff --git a/src/ZLEVEL/HYDROGUI_ZLevelsModel.h b/src/ZLEVEL/HYDROGUI_ZLevelsModel.h deleted file mode 100644 index 62c5f1b9..00000000 --- a/src/ZLEVEL/HYDROGUI_ZLevelsModel.h +++ /dev/null @@ -1,77 +0,0 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// - -#ifndef HYDROGUI_ZLEVELSMODEL_H -#define HYDROGUI_ZLEVELSMODEL_H - -#include -#include - -const int HYDROGUI_VisibleRole = Qt::UserRole + 1; - -/** - * \class HYDROGUI_ZLevelsModel - * \brief The class representing custom list model for the Z levels - */ -class HYDROGUI_ZLevelsModel : public QAbstractListModel -{ - Q_OBJECT - -public: - enum OpType { Top, Up, Down, Bottom, DragAndDrop }; - -public: - HYDROGUI_ZLevelsModel( QObject* theParent = 0 ); - virtual ~HYDROGUI_ZLevelsModel(); - - virtual QVariant data( const QModelIndex &theIndex, int theRole = Qt::DisplayRole ) const; - - virtual int rowCount( const QModelIndex &theParent = QModelIndex() ) const; - - virtual QVariant headerData( int theSection, - Qt::Orientation theOrientation, - int theRole = Qt::DisplayRole ) const; - virtual Qt::ItemFlags flags( const QModelIndex& theIndex ) const; - virtual QMimeData* mimeData( const QModelIndexList& theIndices ) const; - virtual QStringList mimeTypes() const; - virtual bool dropMimeData( const QMimeData* theData, Qt::DropAction theAction, - int theRow, int theColumn, const QModelIndex& theParent ); - virtual Qt::DropActions supportedDropActions() const; - - QList getIds( const QModelIndexList& theIndexes, bool theIsToSort = true ) const; - - void setObjects( const QList>& theObjects ); - - bool move( const int theItem, const OpType theType, bool theIsVisibleOnly, - const int theDropItem = -1 ); - bool move( const QList& theItems, const OpType theType, bool theIsVisibleOnly, - const int theDropItem = -1 ); - -protected: - bool IsObjectVisible( int theIndex ) const; - -private: - QList> myObjects; - QPixmap myEmpty, myEye; -}; - -#endif \ No newline at end of file diff --git a/src/ZLEVEL/eye.png b/src/ZLEVEL/eye.png deleted file mode 100644 index f30a8877..00000000 Binary files a/src/ZLEVEL/eye.png and /dev/null differ diff --git a/src/ZLEVEL/gen.bat b/src/ZLEVEL/gen.bat deleted file mode 100755 index 9cd2c72b..00000000 --- a/src/ZLEVEL/gen.bat +++ /dev/null @@ -1,9 +0,0 @@ -call "%VS90COMNTOOLS%..\..\VC\vcvarsall.bat" x86 -SET appendix="Visual Studio 9 2008" - -@SET PDIR=..\..\..\..\..\PRODUCTSD -call %PDIR%\env_compile.bat - -echo %PATH% - -qmake -tp vc -spec win32-msvc2008 zlevel.pro -r diff --git a/src/ZLEVEL/main.cpp b/src/ZLEVEL/main.cpp deleted file mode 100644 index 48b9828d..00000000 --- a/src/ZLEVEL/main.cpp +++ /dev/null @@ -1,15 +0,0 @@ -#include "HYDROGUI_ZLevelsDlg.h" - -#include - -int main( int argc, char** argv ){ - QApplication app(argc, argv); - - HYDROGUI_ZLevelsDlg* aDlg = new HYDROGUI_ZLevelsDlg( 0 ); - QList< QString > anObjects; - anObjects << "A" << "B" << "C" << "D" << "E" << "F" << "G" << "H"; - aDlg->setObjects( anObjects ); - aDlg->show(); - - return app.exec(); -} \ No newline at end of file diff --git a/src/ZLEVEL/zlevel.pro b/src/ZLEVEL/zlevel.pro deleted file mode 100644 index 3193122f..00000000 --- a/src/ZLEVEL/zlevel.pro +++ /dev/null @@ -1,6 +0,0 @@ -HEADERS = HYDROGUI_ZLevelsDlg.h HYDROGUI_ZLevelsModel.h - -SOURCES = main.cpp HYDROGUI_ZLevelsDlg.cxx HYDROGUI_ZLevelsModel.cxx -CONFIG += qt - -TEMPLATE = app