Changeset 9d5531 for src/UIElements/Qt4/Query
- Timestamp:
- Jul 18, 2012, 2:02:13 PM (13 years ago)
- Branches:
- Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
- Children:
- b3a54d
- Parents:
- 30cd0d
- git-author:
- Michael Ankele <ankele@…> (07/04/12 13:49:18)
- git-committer:
- Michael Ankele <ankele@…> (07/18/12 14:02:13)
- Location:
- src/UIElements/Qt4/Query
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
src/UIElements/Qt4/Query/AtomQtQuery.cpp
r30cd0d r9d5531 30 30 #include "World.hpp" 31 31 32 QtDialog::AtomQtQuery::AtomQtQuery(Parameter<const atom *> & param, std::string _title,QBoxLayout *_parent,QtDialog *_dialog) :33 Dialog::AtomQuery( param, _title),32 QtDialog::AtomQtQuery::AtomQtQuery(Parameter<const atom *> &_param, std::string _title,QBoxLayout *_parent,QtDialog *_dialog) : 33 Dialog::AtomQuery(_param, _title), 34 34 parent(_parent) 35 35 { … … 46 46 thisLayout->addWidget(inputBox); 47 47 48 pipe = new AtomQtQueryPipe(t mp,_dialog, inputBox);48 pipe = new AtomQtQueryPipe(temp,_dialog, inputBox); 49 49 pipe->update(inputBox->currentIndex()); 50 50 connect(inputBox,SIGNAL(currentIndexChanged(int)),pipe,SLOT(update(int))); … … 57 57 58 58 bool QtDialog::AtomQtQuery::handle() { 59 return true; 59 if (param.isValid(temp)){ 60 param.set(temp); 61 return true; 62 } 63 return false; 60 64 } 61 65 -
src/UIElements/Qt4/Query/AtomsQtQuery.cpp
r30cd0d r9d5531 33 33 34 34 35 QtDialog::AtomsQtQuery::AtomsQtQuery(Parameter<std::vector<const atom *> > & param, std::string _title,QBoxLayout *_parent,QtDialog *_dialog) :36 Dialog::AtomsQuery( param, _title),35 QtDialog::AtomsQtQuery::AtomsQtQuery(Parameter<std::vector<const atom *> > &_param, std::string _title,QBoxLayout *_parent,QtDialog *_dialog) : 36 Dialog::AtomsQuery(_param, _title), 37 37 parent(_parent) 38 38 { … … 67 67 thisHLayout->addLayout(thisV2Layout); 68 68 69 pipe = new AtomsQtQueryPipe(t mp,_dialog,inputList);69 pipe = new AtomsQtQueryPipe(temp,_dialog,inputList); 70 70 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(IntegerSelected())); 71 71 connect(AddButton,SIGNAL(Clicked()),pipe,SLOT(add())); … … 79 79 80 80 bool QtDialog::AtomsQtQuery::handle() { 81 return true; 81 if (param.isValid(temp)){ 82 param.set(temp); 83 return true; 84 } 85 return false; 82 86 } 83 87 -
src/UIElements/Qt4/Query/BooleanQtQuery.cpp
r30cd0d r9d5531 28 28 29 29 30 QtDialog::BooleanQtQuery::BooleanQtQuery(Parameter<bool> & param, std::string _title, QBoxLayout *_parent, QtDialog *_dialog) :31 Dialog::BooleanQuery( param, _title),30 QtDialog::BooleanQtQuery::BooleanQtQuery(Parameter<bool> &_param, std::string _title, QBoxLayout *_parent, QtDialog *_dialog) : 31 Dialog::BooleanQuery(_param, _title), 32 32 parent(_parent) 33 33 { … … 43 43 thisLayout->addWidget(booleanCheckBox); 44 44 45 pipe = new BooleanQtQueryPipe(t mp,_dialog,booleanCheckBox);45 pipe = new BooleanQtQueryPipe(temp,_dialog,booleanCheckBox); 46 46 connect(booleanCheckBox, SIGNAL(stateChanged(int)), pipe, SLOT(update(int))); 47 47 } … … 53 53 54 54 bool QtDialog::BooleanQtQuery::handle(){ 55 return true; 55 if (param.isValid(temp)){ 56 param.set(temp); 57 return true; 58 } 59 return false; 56 60 } 57 61 -
src/UIElements/Qt4/Query/DoubleQtQuery.cpp
r30cd0d r9d5531 28 28 29 29 30 QtDialog::DoubleQtQuery::DoubleQtQuery(Parameter<double> & param, std::string title,QBoxLayout *_parent,QtDialog *_dialog) :31 Dialog::DoubleQuery( param, title),30 QtDialog::DoubleQtQuery::DoubleQtQuery(Parameter<double> &_param, std::string title,QBoxLayout *_parent,QtDialog *_dialog) : 31 Dialog::DoubleQuery(_param, title), 32 32 parent(_parent) 33 33 { … … 44 44 thisLayout->addWidget(inputBox); 45 45 46 pipe = new DoubleQtQueryPipe(t mp,_dialog);46 pipe = new DoubleQtQueryPipe(temp,_dialog); 47 47 pipe->update(inputBox->value()); 48 48 connect(inputBox,SIGNAL(valueChanged(double)),pipe,SLOT(update(double))); … … 55 55 56 56 bool QtDialog::DoubleQtQuery::handle() { 57 return true; 57 if (param.isValid(temp)){ 58 param.set(temp); 59 return true; 60 } 61 return false; 58 62 } 59 63 -
src/UIElements/Qt4/Query/DoublesQtQuery.cpp
r30cd0d r9d5531 60 60 thisHLayout->addLayout(thisV2Layout); 61 61 62 pipe = new QtQueryListPipe<double>(t mp,_dialog,inputBox,inputList,AddButton,RemoveButton);62 pipe = new QtQueryListPipe<double>(temp,_dialog,inputBox,inputList,AddButton,RemoveButton); 63 63 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(IntegerEntered(const QString&))); 64 64 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(IntegerSelected())); … … 72 72 73 73 bool QtDialog::DoublesQtQuery::handle() { 74 return true; 74 if (param.isValid(temp)){ 75 param.set(temp); 76 return true; 77 } 78 return false; 75 79 } 76 80 -
src/UIElements/Qt4/Query/ElementQtQuery.cpp
r30cd0d r9d5531 51 51 thisLayout->addWidget(inputBox); 52 52 53 pipe = new ElementQtQueryPipe(t mp,_dialog,inputBox);53 pipe = new ElementQtQueryPipe(temp,_dialog,inputBox); 54 54 pipe->update(inputBox->currentIndex()); 55 55 connect(inputBox,SIGNAL(currentIndexChanged(int)),pipe,SLOT(update(int))); … … 62 62 63 63 bool QtDialog::ElementQtQuery::handle(){ 64 return true; 64 if (param.isValid(temp)){ 65 param.set(temp); 66 return true; 67 } 68 return false; 65 69 } 66 70 -
src/UIElements/Qt4/Query/ElementsQtQuery.cpp
r30cd0d r9d5531 52 52 thisLayout->addWidget(inputBox); 53 53 54 pipe = new ElementsQtQueryPipe(t mp,_dialog,inputBox);54 pipe = new ElementsQtQueryPipe(temp,_dialog,inputBox); 55 55 pipe->update(inputBox->currentIndex()); 56 56 connect(inputBox,SIGNAL(currentIndexChanged(int)),pipe,SLOT(update(int))); … … 63 63 64 64 bool QtDialog::ElementsQtQuery::handle(){ 65 return true; 65 if (param.isValid(temp)){ 66 param.set(temp); 67 return true; 68 } 69 return false; 66 70 } 67 71 -
src/UIElements/Qt4/Query/FileQtQuery.cpp
r30cd0d r9d5531 43 43 filedialogButton = new QPushButton("&Choose", _dialog); 44 44 45 pipe = new FileQtQueryPipe(t mp,_dialog,filenameLineEdit,filedialogButton);45 pipe = new FileQtQueryPipe(temp,_dialog,filenameLineEdit,filedialogButton); 46 46 47 47 thisLayout = new QHBoxLayout(); … … 60 60 61 61 bool QtDialog::FileQtQuery::handle(){ 62 return true; 62 if (param.isValid(temp)){ 63 param.set(temp); 64 return true; 65 } 66 return false; 63 67 } 64 68 -
src/UIElements/Qt4/Query/FilesQtQuery.cpp
r30cd0d r9d5531 62 62 thisHLayout->addLayout(thisV2Layout); 63 63 64 pipe = new QtQueryListPipe<boost::filesystem::path>(t mp,_dialog,inputBox,inputList,AddButton,RemoveButton);64 pipe = new QtQueryListPipe<boost::filesystem::path>(temp,_dialog,inputBox,inputList,AddButton,RemoveButton); 65 65 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(IntegerEntered(const QString&))); 66 66 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(IntegerSelected())); … … 75 75 76 76 bool QtDialog::FilesQtQuery::handle(){ 77 if (param.isValid(temp)){ 78 param.set(temp); 79 return true; 80 } 77 81 return true; 78 82 } -
src/UIElements/Qt4/Query/IntQtQuery.cpp
r30cd0d r9d5531 42 42 thisLayout->addWidget(inputBox); 43 43 44 pipe = new IntQtQueryPipe(t mp,_dialog);44 pipe = new IntQtQueryPipe(temp,_dialog); 45 45 pipe->update(inputBox->value()); 46 46 connect(inputBox,SIGNAL(valueChanged(int)),pipe,SLOT(update(int))); … … 53 53 54 54 bool QtDialog::IntQtQuery::handle() { 55 return true; 55 if (param.isValid(temp)){ 56 param.set(temp); 57 return true; 58 } 59 return false; 56 60 } 57 61 -
src/UIElements/Qt4/Query/IntsQtQuery.cpp
r30cd0d r9d5531 60 60 thisHLayout->addLayout(thisV2Layout); 61 61 62 pipe = new QtQueryListPipe<int>(t mp,_dialog,inputBox,inputList,AddButton,RemoveButton);62 pipe = new QtQueryListPipe<int>(temp,_dialog,inputBox,inputList,AddButton,RemoveButton); 63 63 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(IntegerEntered(const QString&))); 64 64 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(IntegerSelected())); … … 73 73 74 74 bool QtDialog::IntsQtQuery::handle() { 75 return true; 75 if (param.isValid(temp)){ 76 param.set(temp); 77 return true; 78 } 79 return false; 76 80 } 77 81 -
src/UIElements/Qt4/Query/MoleculeQtQuery.cpp
r30cd0d r9d5531 51 51 thisLayout->addWidget(inputBox); 52 52 53 pipe = new MoleculeQtQueryPipe(t mp,_dialog,inputBox);53 pipe = new MoleculeQtQueryPipe(temp,_dialog,inputBox); 54 54 pipe->update(inputBox->currentIndex()); 55 55 connect(inputBox,SIGNAL(currentIndexChanged(int)),pipe,SLOT(update(int))); … … 64 64 bool QtDialog::MoleculeQtQuery::handle() 65 65 { 66 return true; 66 if (param.isValid(temp)){ 67 param.set(temp); 68 return true; 69 } 70 return false; 67 71 } 68 72 -
src/UIElements/Qt4/Query/MoleculesQtQuery.cpp
r30cd0d r9d5531 51 51 thisLayout->addWidget(inputBox); 52 52 53 pipe = new MoleculesQtQueryPipe(t mp,_dialog,inputBox);53 pipe = new MoleculesQtQueryPipe(temp,_dialog,inputBox); 54 54 pipe->update(inputBox->currentIndex()); 55 55 connect(inputBox,SIGNAL(currentIndexChanged(int)),pipe,SLOT(update(int))); … … 64 64 bool QtDialog::MoleculesQtQuery::handle() 65 65 { 66 return true; 66 if (param.isValid(temp)){ 67 param.set(temp); 68 return true; 69 } 70 return false; 67 71 } 68 72 -
src/UIElements/Qt4/Query/QtQuery.hpp
r30cd0d r9d5531 199 199 class QtDialog::FilesQtQuery : public Dialog::FilesQuery { 200 200 public: 201 FilesQtQuery(Parameter<std::vector< boost::filesystem::path> > & param, std::string _title, QBoxLayout *_parent, QtDialog *_dialog);201 FilesQtQuery(Parameter<std::vector< boost::filesystem::path> > &, std::string _title, QBoxLayout *_parent, QtDialog *_dialog); 202 202 virtual ~FilesQtQuery(); 203 203 virtual bool handle(); … … 335 335 class QtDialog::VectorQtQuery : public Dialog::VectorQuery { 336 336 public: 337 VectorQtQuery(Parameter<Vector> &, std::string title, bool _check,QBoxLayout *,QtDialog *);337 VectorQtQuery(Parameter<Vector> &, std::string title,QBoxLayout *,QtDialog *); 338 338 virtual ~VectorQtQuery(); 339 339 virtual bool handle(); … … 354 354 class QtDialog::VectorsQtQuery : public Dialog::VectorsQuery { 355 355 public: 356 VectorsQtQuery(Parameter<std::vector<Vector> > &, std::string title, bool _check,QBoxLayout *,QtDialog *);356 VectorsQtQuery(Parameter<std::vector<Vector> > &, std::string title,QBoxLayout *,QtDialog *); 357 357 virtual ~VectorsQtQuery(); 358 358 virtual bool handle(); -
src/UIElements/Qt4/Query/RandomNumberDistribution_ParametersQtQuery.cpp
r30cd0d r9d5531 50 50 okButton = new QPushButton(tr("Ok")); 51 51 52 pipe = new RandomNumberDistribution_ParametersQtQueryPipe(t mp,_dialog, inputBox);52 pipe = new RandomNumberDistribution_ParametersQtQueryPipe(temp,_dialog, inputBox); 53 53 connect(okButton,SIGNAL(clicked()),pipe,SLOT(update())); 54 54 } … … 60 60 61 61 bool QtDialog::RandomNumberDistribution_ParametersQtQuery::handle() { 62 return true; 62 if (param.isValid(temp)){ 63 param.set(temp); 64 return true; 65 } 66 return false; 63 67 } 64 68 -
src/UIElements/Qt4/Query/RealSpaceMatrixQtQuery.cpp
r30cd0d r9d5531 44 44 inputTable->setVerticalHeaderLabels(CoordinateList); 45 45 46 pipe = new RealSpaceMatrixQtQueryPipe(t mp,_dialog, inputTable);46 pipe = new RealSpaceMatrixQtQueryPipe(temp,_dialog, inputTable); 47 47 48 48 // fill the box with current matrix … … 68 68 69 69 bool QtDialog::RealSpaceMatrixQtQuery::handle() { 70 return true; 70 if (param.isValid(temp)){ 71 param.set(temp); 72 return true; 73 } 74 return false; 71 75 } 72 76 -
src/UIElements/Qt4/Query/StringQtQuery.cpp
r30cd0d r9d5531 41 41 thisLayout->addWidget(inputBox); 42 42 43 pipe = new StringQtQueryPipe(t mp,_dialog);43 pipe = new StringQtQueryPipe(temp,_dialog); 44 44 pipe->update(inputBox->text()); 45 45 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(update(const QString&))); … … 54 54 bool QtDialog::StringQtQuery::handle() 55 55 { 56 return tmp.get() != ""; 56 //return tmp.get() != ""; 57 if (param.isValid(temp)){ 58 param.set(temp); 59 return true; 60 } 61 return false; 57 62 } 58 63 -
src/UIElements/Qt4/Query/StringsQtQuery.cpp
r30cd0d r9d5531 60 60 thisHLayout->addLayout(thisV2Layout); 61 61 62 pipe = new StringsQtQueryPipe(t mp,_dialog,inputBox,inputList,AddButton,RemoveButton);62 pipe = new StringsQtQueryPipe(temp,_dialog,inputBox,inputList,AddButton,RemoveButton); 63 63 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(elementEntered(const QString&))); 64 64 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(elementSelected())); … … 88 88 89 89 return temp!="";*/ 90 return true; 90 if (param.isValid(temp)){ 91 param.set(temp); 92 return true; 93 } 94 return false; 91 95 } 92 96 -
src/UIElements/Qt4/Query/UnsignedIntQtQuery.cpp
r30cd0d r9d5531 42 42 thisLayout->addWidget(inputBox); 43 43 44 pipe = new UnsignedIntQtQueryPipe(t mp,_dialog);44 pipe = new UnsignedIntQtQueryPipe(temp,_dialog); 45 45 pipe->update(inputBox->value()); 46 46 connect(inputBox,SIGNAL(valueChanged(unsigned int)),pipe,SLOT(update(unsigned int))); … … 53 53 54 54 bool QtDialog::UnsignedIntQtQuery::handle() { 55 return true; 55 if (param.isValid(temp)){ 56 param.set(temp); 57 return true; 58 } 59 return false; 56 60 } 57 61 -
src/UIElements/Qt4/Query/UnsignedIntsQtQuery.cpp
r30cd0d r9d5531 60 60 thisHLayout->addLayout(thisV2Layout); 61 61 62 pipe = new QtQueryListPipe<unsigned int>(t mp,_dialog,inputBox,inputList,AddButton,RemoveButton);62 pipe = new QtQueryListPipe<unsigned int>(temp,_dialog,inputBox,inputList,AddButton,RemoveButton); 63 63 connect(inputBox,SIGNAL(textChanged(const QString&)),pipe,SLOT(IntegerEntered(const QString&))); 64 64 connect(inputList,SIGNAL(itemSelectionChanged()),pipe,SLOT(IntegerSelected())); … … 73 73 74 74 bool QtDialog::UnsignedIntsQtQuery::handle() { 75 return true; 75 if (param.isValid(temp)){ 76 param.set(temp); 77 return true; 78 } 79 return false; 76 80 } 77 81 -
src/UIElements/Qt4/Query/VectorQtQuery.cpp
r30cd0d r9d5531 29 29 30 30 31 QtDialog::VectorQtQuery::VectorQtQuery(Parameter<Vector> ¶m, std::string title, bool _check,QBoxLayout *_parent,QtDialog *_dialog) :32 Dialog::VectorQuery(param, title ,_check),31 QtDialog::VectorQtQuery::VectorQtQuery(Parameter<Vector> ¶m, std::string title, QBoxLayout *_parent,QtDialog *_dialog) : 32 Dialog::VectorQuery(param, title), 33 33 parent(_parent) 34 34 { … … 63 63 coordInputZ->setDecimals(3); 64 64 coordLayout->addWidget(coordInputZ); 65 pipe = new VectorQtQueryPipe(t mp,_dialog,inputBox);65 pipe = new VectorQtQueryPipe(temp,_dialog,inputBox); 66 66 //pipe->update(coordInput->value()); 67 67 connect(coordInputX,SIGNAL(valueChanged(double)),pipe,SLOT(updateX(double))); … … 75 75 76 76 bool QtDialog::VectorQtQuery::handle() { 77 return true; 77 if (param.isValid(temp)){ 78 param.set(temp); 79 return true; 80 } 81 return false; 78 82 } 79 83 -
src/UIElements/Qt4/Query/VectorsQtQuery.cpp
r30cd0d r9d5531 29 29 30 30 31 QtDialog::VectorsQtQuery::VectorsQtQuery(Parameter<std::vector<Vector> > ¶m, std::string title, bool _check,QBoxLayout *_parent,QtDialog *_dialog) :32 Dialog::VectorsQuery(param, title ,_check),31 QtDialog::VectorsQtQuery::VectorsQtQuery(Parameter<std::vector<Vector> > ¶m, std::string title, QBoxLayout *_parent,QtDialog *_dialog) : 32 Dialog::VectorsQuery(param, title), 33 33 parent(_parent) 34 34 { … … 47 47 coordInput->setDecimals(3); 48 48 coordLayout->addWidget(coordInput); 49 pipe = new VectorsQtQueryPipe(t mp,_dialog,inputBox);49 pipe = new VectorsQtQueryPipe(temp,_dialog,inputBox); 50 50 //pipe->update(coordInput->value()); 51 51 connect(coordInput,SIGNAL(valueChanged(double)),pipe,SLOT(update(double))); … … 57 57 58 58 bool QtDialog::VectorsQtQuery::handle() { 59 return true; 59 if (param.isValid(temp)){ 60 param.set(temp); 61 return true; 62 } 63 return false; 60 64 } 61 65
Note:
See TracChangeset
for help on using the changeset viewer.