Changeset 852ea3 for src/UIElements/Qt4/Query
- Timestamp:
- Aug 27, 2012, 11:36:59 AM (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:
- 7e6a1b
- Parents:
- 1c55b8
- git-author:
- Michael Ankele <ankele@…> (08/16/12 15:38:10)
- git-committer:
- Michael Ankele <ankele@…> (08/27/12 11:36:59)
- Location:
- src/UIElements/Qt4/Query
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
src/UIElements/Qt4/Query/AtomQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::AtomQtQuery::AtomQtQuery(Parameter<const atom *> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 32 Dialog::TQuery<const atom *>(_param, _title),32 QtQuery<const atom *>(_param, _title), 33 33 parent(_parent), 34 34 dialog(_dialog) … … 61 61 } 62 62 63 bool QtDialog::AtomQtQuery::handle() {64 if (param.isValid(temp)){65 param.set(temp);66 return true;67 }68 return false;69 }70 63 71 -
src/UIElements/Qt4/Query/AtomsQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::AtomsQtQuery::AtomsQtQuery(Parameter<std::vector<const atom *> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<const atom *> >(_param, _title),31 QtQuery<std::vector<const atom *> >(_param, _title), 32 32 QtQueryList<const atom *>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 bool QtDialog::AtomsQtQuery::handle()66 {67 if (param.isValid(temp)){68 param.set(temp);69 return true;70 }71 return false;72 }73 65 74 66 75 -
src/UIElements/Qt4/Query/BooleanQtQuery.cpp
r1c55b8 r852ea3 28 28 29 29 QtDialog::BooleanQtQuery::BooleanQtQuery(Parameter<bool> &_param, std::string _title, QBoxLayout *_parent, Dialog *_dialog) : 30 Dialog::TQuery<bool>(_param, _title),30 QtQuery<bool>(_param, _title), 31 31 parent(_parent), 32 32 dialog(_dialog) … … 56 56 } 57 57 58 bool QtDialog::BooleanQtQuery::handle(){59 if (param.isValid(temp)){60 param.set(temp);61 return true;62 }63 return false;64 }65 58 66 -
src/UIElements/Qt4/Query/DoubleQtQuery.cpp
r1c55b8 r852ea3 28 28 29 29 QtDialog::DoubleQtQuery::DoubleQtQuery(Parameter<double> &_param, std::string title,QBoxLayout *_parent,Dialog *_dialog) : 30 Dialog::TQuery<double>(_param, title),30 QtQuery<double>(_param, title), 31 31 parent(_parent), 32 32 dialog(_dialog) … … 50 50 QtDialog::DoubleQtQuery::~DoubleQtQuery() 51 51 { 52 //delete pipe;53 52 } 54 53 … … 58 57 } 59 58 60 bool QtDialog::DoubleQtQuery::handle() {61 if (param.isValid(temp)){62 param.set(temp);63 return true;64 }65 return false;66 }67 59 68 -
src/UIElements/Qt4/Query/DoublesQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::DoublesQtQuery::DoublesQtQuery(Parameter<std::vector<double> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<double> >(_param, _title),31 QtQuery<std::vector<double> >(_param, _title), 32 32 QtQueryList<double>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 bool QtDialog::DoublesQtQuery::handle()66 {67 if (param.isValid(temp)){68 param.set(temp);69 return true;70 }71 return false;72 }73 65 74 66 75 -
src/UIElements/Qt4/Query/ElementQtQuery.cpp
r1c55b8 r852ea3 31 31 32 32 QtDialog::ElementQtQuery::ElementQtQuery(Parameter<const element *> &_param, std::string _title, QBoxLayout *_parent, Dialog *_dialog) : 33 Dialog::TQuery<const element *>(_param, _title),33 QtQuery<const element *>(_param, _title), 34 34 parent(_parent), 35 35 dialog(_dialog) … … 66 66 } 67 67 68 bool QtDialog::ElementQtQuery::handle(){69 if (param.isValid(temp)){70 param.set(temp);71 return true;72 }73 return false;74 }75 68 76 -
src/UIElements/Qt4/Query/ElementsQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::ElementsQtQuery::ElementsQtQuery(Parameter<std::vector<const element *> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 32 Dialog::TQuery<std::vector<const element *> >(_param, _title),32 QtQuery<std::vector<const element *> >(_param, _title), 33 33 QtQueryList<const element *>(_parent, _dialog, temp) 34 34 { … … 64 64 } 65 65 66 bool QtDialog::ElementsQtQuery::handle()67 {68 if (param.isValid(temp)){69 param.set(temp);70 return true;71 }72 return false;73 }74 66 75 -
src/UIElements/Qt4/Query/FileQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::FileQtQuery::FileQtQuery(Parameter<boost::filesystem::path> &_param, std::string _title, QBoxLayout *_parent, Dialog *_dialog) : 32 Dialog::TQuery<boost::filesystem::path>(_param, _title),32 QtQuery<boost::filesystem::path>(_param, _title), 33 33 parent(_parent), 34 34 dialog(_dialog) … … 82 82 } 83 83 84 bool QtDialog::FileQtQuery::handle(){85 if (param.isValid(temp)){86 param.set(temp);87 return true;88 }89 return false;90 }91 -
src/UIElements/Qt4/Query/FilesQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::FilesQtQuery::FilesQtQuery(Parameter<std::vector<boost::filesystem::path> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 32 Dialog::TQuery<std::vector<boost::filesystem::path> >(_param, _title),32 QtQuery<std::vector<boost::filesystem::path> >(_param, _title), 33 33 QtQueryList<boost::filesystem::path>(_parent, _dialog, temp) 34 34 { … … 64 64 } 65 65 66 bool QtDialog::FilesQtQuery::handle()67 {68 if (param.isValid(temp)){69 param.set(temp);70 return true;71 }72 return false;73 }74 66 75 -
src/UIElements/Qt4/Query/IntQtQuery.cpp
r1c55b8 r852ea3 28 28 29 29 QtDialog::IntQtQuery::IntQtQuery(Parameter<int> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 30 Dialog::TQuery<int>(_param, _title),30 QtQuery<int>(_param, _title), 31 31 parent(_parent), 32 32 dialog(_dialog) … … 55 55 } 56 56 57 bool QtDialog::IntQtQuery::handle() {58 if (param.isValid(temp)){59 param.set(temp);60 return true;61 }62 return false;63 }64 -
src/UIElements/Qt4/Query/IntsQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::IntsQtQuery::IntsQtQuery(Parameter<std::vector<int> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<int> >(_param, _title),31 QtQuery<std::vector<int> >(_param, _title), 32 32 QtQueryList<int>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 bool QtDialog::IntsQtQuery::handle()66 {67 if (param.isValid(temp)){68 param.set(temp);69 return true;70 }71 return false;72 }73 65 74 66 75 -
src/UIElements/Qt4/Query/MoleculeQtQuery.cpp
r1c55b8 r852ea3 31 31 32 32 QtDialog::MoleculeQtQuery::MoleculeQtQuery(Parameter<const molecule *> &_param, std::string _title, QBoxLayout *_parent,Dialog *_dialog) : 33 Dialog::TQuery<const molecule *>(_param, _title),33 QtQuery<const molecule *>(_param, _title), 34 34 parent(_parent), 35 35 dialog(_dialog) … … 65 65 } 66 66 67 // Handling is easy, since the GUI makes it impossible to select invalid values68 bool QtDialog::MoleculeQtQuery::handle()69 {70 if (param.isValid(temp)){71 param.set(temp);72 return true;73 }74 return false;75 }76 -
src/UIElements/Qt4/Query/MoleculesQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::MoleculesQtQuery::MoleculesQtQuery(Parameter<std::vector<const molecule *> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<const molecule *> >(_param, _title),31 QtQuery<std::vector<const molecule *> >(_param, _title), 32 32 QtQueryList<const molecule *>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 bool QtDialog::MoleculesQtQuery::handle()66 {67 if (param.isValid(temp)){68 param.set(temp);69 return true;70 }71 return false;72 }73 65 74 66 75 -
src/UIElements/Qt4/Query/QtQuery.hpp
r1c55b8 r852ea3 35 35 class QFileDialog; 36 36 37 class QtDialog::AtomQtQuery : public QWidget, public Dialog::TQuery<const atom *> { 37 template<class T> 38 class QtQuery : public Dialog::TQuery<T> 39 { 40 public: 41 QtQuery(Parameter<T> &_param, std::string title, std::string _description = "") : 42 Dialog::TQuery<T>(_param, title, _description) {} 43 // QtQueries are interactive - no need for handle(). 44 virtual bool handle(){ return true; } 45 }; 46 47 class QtDialog::AtomQtQuery : public QWidget, public QtQuery<const atom *> { 38 48 Q_OBJECT 39 49 public: 40 50 AtomQtQuery(Parameter<const atom *> &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 41 51 virtual ~AtomQtQuery(); 42 virtual bool handle();43 52 44 53 public slots: … … 53 62 }; 54 63 55 class QtDialog::AtomsQtQuery : public QWidget, public Dialog::TQuery<std::vector<const atom *> >, public QtQueryList<const atom *> {64 class QtDialog::AtomsQtQuery : public QWidget, public QtQuery<std::vector<const atom *> >, public QtQueryList<const atom *> { 56 65 Q_OBJECT 57 66 public: 58 67 AtomsQtQuery(Parameter<std::vector<const atom *> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 59 68 virtual ~AtomsQtQuery(); 60 virtual bool handle();61 69 62 70 virtual void onSubUpdate(); … … 71 79 }; 72 80 73 class QtDialog::BooleanQtQuery : public QWidget, public Dialog::TQuery<bool> {81 class QtDialog::BooleanQtQuery : public QWidget, public QtQuery<bool> { 74 82 Q_OBJECT 75 83 public: 76 84 BooleanQtQuery(Parameter<bool> &, std::string _title, QBoxLayout *_parent, Dialog *_dialog); 77 85 virtual ~BooleanQtQuery(); 78 virtual bool handle();79 86 80 87 public slots: … … 89 96 }; 90 97 91 class QtDialog::RealSpaceMatrixQtQuery : public QWidget, public Dialog::TQuery<RealSpaceMatrix> {98 class QtDialog::RealSpaceMatrixQtQuery : public QWidget, public QtQuery<RealSpaceMatrix> { 92 99 Q_OBJECT 93 100 public: 94 101 RealSpaceMatrixQtQuery(Parameter<RealSpaceMatrix> &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 95 102 virtual ~RealSpaceMatrixQtQuery(); 96 virtual bool handle();97 103 98 104 public slots: … … 107 113 }; 108 114 109 class QtDialog::DoubleQtQuery : public QWidget, public Dialog::TQuery<double> {115 class QtDialog::DoubleQtQuery : public QWidget, public QtQuery<double> { 110 116 Q_OBJECT 111 117 public: 112 118 DoubleQtQuery(Parameter<double> &, std::string title,QBoxLayout *_parent,Dialog *_dialog); 113 119 virtual ~DoubleQtQuery(); 114 virtual bool handle();115 120 116 121 public slots: … … 125 130 }; 126 131 127 class QtDialog::DoublesQtQuery : public QWidget, public Dialog::TQuery<std::vector<double> >, public QtQueryList<double> {132 class QtDialog::DoublesQtQuery : public QWidget, public QtQuery<std::vector<double> >, public QtQueryList<double> { 128 133 Q_OBJECT 129 134 public: 130 135 DoublesQtQuery(Parameter<std::vector<double> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 131 136 virtual ~DoublesQtQuery(); 132 virtual bool handle();133 137 134 138 virtual void onSubUpdate(); … … 143 147 }; 144 148 145 class QtDialog::ElementQtQuery : public QWidget, public Dialog::TQuery<const element *> {149 class QtDialog::ElementQtQuery : public QWidget, public QtQuery<const element *> { 146 150 Q_OBJECT 147 151 public: 148 152 ElementQtQuery(Parameter<const element *> &, std::string _title, QBoxLayout *_parent, Dialog *_dialog); 149 153 virtual ~ElementQtQuery(); 150 virtual bool handle();151 154 152 155 public slots: … … 161 164 }; 162 165 163 class QtDialog::ElementsQtQuery : public QWidget, public Dialog::TQuery<std::vector<const element *> >, public QtQueryList<const element *> {166 class QtDialog::ElementsQtQuery : public QWidget, public QtQuery<std::vector<const element *> >, public QtQueryList<const element *> { 164 167 Q_OBJECT 165 168 public: 166 169 ElementsQtQuery(Parameter<std::vector<const element *> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 167 170 virtual ~ElementsQtQuery(); 168 virtual bool handle();169 171 170 172 virtual void onSubUpdate(); … … 191 193 }; 192 194 193 class QtDialog::FileQtQuery : public QWidget, public Dialog::TQuery<boost::filesystem::path> {195 class QtDialog::FileQtQuery : public QWidget, public QtQuery<boost::filesystem::path> { 194 196 Q_OBJECT 195 197 public: 196 198 FileQtQuery(Parameter<boost::filesystem::path> &, std::string _title, QBoxLayout *_parent, Dialog *_dialog); 197 199 virtual ~FileQtQuery(); 198 virtual bool handle();199 200 200 201 public slots: … … 212 213 }; 213 214 214 class QtDialog::FilesQtQuery : public QWidget, public Dialog::TQuery<std::vector<boost::filesystem::path> >, public QtQueryList<boost::filesystem::path> {215 class QtDialog::FilesQtQuery : public QWidget, public QtQuery<std::vector<boost::filesystem::path> >, public QtQueryList<boost::filesystem::path> { 215 216 Q_OBJECT 216 217 public: 217 218 FilesQtQuery(Parameter<std::vector<boost::filesystem::path> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 218 219 virtual ~FilesQtQuery(); 219 virtual bool handle();220 220 221 221 virtual void onSubUpdate(); … … 230 230 }; 231 231 232 class QtDialog::IntQtQuery : public QWidget, public Dialog::TQuery<int> {232 class QtDialog::IntQtQuery : public QWidget, public QtQuery<int> { 233 233 Q_OBJECT 234 234 public: 235 235 IntQtQuery(Parameter<int> &, std::string _title,QBoxLayout *_parent,Dialog *_dialog); 236 236 virtual ~IntQtQuery(); 237 virtual bool handle();238 237 239 238 public slots: … … 248 247 }; 249 248 250 class QtDialog::IntsQtQuery : public QWidget, public Dialog::TQuery<std::vector<int> >, public QtQueryList<int> {249 class QtDialog::IntsQtQuery : public QWidget, public QtQuery<std::vector<int> >, public QtQueryList<int> { 251 250 Q_OBJECT 252 251 public: 253 252 IntsQtQuery(Parameter<std::vector<int> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 254 253 virtual ~IntsQtQuery(); 255 virtual bool handle();256 254 257 255 virtual void onSubUpdate(); … … 266 264 }; 267 265 268 class QtDialog::MoleculeQtQuery : public QWidget, public Dialog::TQuery<const molecule *> {266 class QtDialog::MoleculeQtQuery : public QWidget, public QtQuery<const molecule *> { 269 267 Q_OBJECT 270 268 public: 271 269 MoleculeQtQuery(Parameter<const molecule *> &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 272 270 virtual ~MoleculeQtQuery(); 273 virtual bool handle();274 271 275 272 public slots: … … 284 281 }; 285 282 286 class QtDialog::MoleculesQtQuery : public QWidget, public Dialog::TQuery<std::vector<const molecule *> >, public QtQueryList<const molecule *> {283 class QtDialog::MoleculesQtQuery : public QWidget, public QtQuery<std::vector<const molecule *> >, public QtQueryList<const molecule *> { 287 284 Q_OBJECT 288 285 public: 289 286 MoleculesQtQuery(Parameter<std::vector<const molecule *> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 290 287 virtual ~MoleculesQtQuery(); 291 virtual bool handle();292 288 293 289 virtual void onSubUpdate(); … … 302 298 }; 303 299 304 class QtDialog::StringQtQuery : public QWidget, public Dialog::TQuery<std::string> {300 class QtDialog::StringQtQuery : public QWidget, public QtQuery<std::string> { 305 301 Q_OBJECT 306 302 public: 307 303 StringQtQuery(Parameter<std::string> &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 308 304 virtual ~StringQtQuery(); 309 virtual bool handle();310 305 311 306 public slots: … … 320 315 }; 321 316 322 class QtDialog::StringsQtQuery : public QWidget, public Dialog::TQuery<std::vector<std::string> >, public QtQueryList<std::string> {317 class QtDialog::StringsQtQuery : public QWidget, public QtQuery<std::vector<std::string> >, public QtQueryList<std::string> { 323 318 Q_OBJECT 324 319 public: 325 320 StringsQtQuery(Parameter<std::vector<std::string> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 326 321 virtual ~StringsQtQuery(); 327 virtual bool handle();328 322 329 323 virtual void onSubUpdate(); … … 338 332 }; 339 333 340 class QtDialog::UnsignedIntQtQuery : public QWidget, public Dialog::TQuery<unsigned int> {334 class QtDialog::UnsignedIntQtQuery : public QWidget, public QtQuery<unsigned int> { 341 335 Q_OBJECT 342 336 public: 343 337 UnsignedIntQtQuery(Parameter<unsigned int> &, std::string _title,QBoxLayout *_parent,Dialog *_dialog); 344 338 virtual ~UnsignedIntQtQuery(); 345 virtual bool handle();346 339 347 340 public slots: … … 356 349 }; 357 350 358 class QtDialog::UnsignedIntsQtQuery : public QWidget, public Dialog::TQuery<std::vector<unsigned int> >, public QtQueryList<unsigned int> {351 class QtDialog::UnsignedIntsQtQuery : public QWidget, public QtQuery<std::vector<unsigned int> >, public QtQueryList<unsigned int> { 359 352 Q_OBJECT 360 353 public: 361 354 UnsignedIntsQtQuery(Parameter<std::vector<unsigned int> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 362 355 virtual ~UnsignedIntsQtQuery(); 363 virtual bool handle();364 356 365 357 virtual void onSubUpdate(); … … 374 366 }; 375 367 376 class QtDialog::VectorQtQuery : public QWidget, public Dialog::TQuery<Vector> {368 class QtDialog::VectorQtQuery : public QWidget, public QtQuery<Vector> { 377 369 Q_OBJECT 378 370 public: 379 371 VectorQtQuery(Parameter<Vector> &, std::string title,QBoxLayout *,Dialog *); 380 372 virtual ~VectorQtQuery(); 381 virtual bool handle();382 373 383 374 public slots: … … 399 390 }; 400 391 401 class QtDialog::VectorsQtQuery : public QWidget, public Dialog::TQuery<std::vector<Vector> >, public QtQueryList<Vector> {392 class QtDialog::VectorsQtQuery : public QWidget, public QtQuery<std::vector<Vector> >, public QtQueryList<Vector> { 402 393 Q_OBJECT 403 394 public: 404 395 VectorsQtQuery(Parameter<std::vector<Vector> > &, std::string _title, QBoxLayout *_parent,Dialog *_dialog); 405 396 virtual ~VectorsQtQuery(); 406 virtual bool handle();407 397 408 398 virtual void onSubUpdate(); … … 417 407 }; 418 408 419 class QtDialog::RandomNumberDistribution_ParametersQtQuery : public QWidget, public Dialog::TQuery<RandomNumberDistribution_Parameters> {409 class QtDialog::RandomNumberDistribution_ParametersQtQuery : public QWidget, public QtQuery<RandomNumberDistribution_Parameters> { 420 410 Q_OBJECT 421 411 public: 422 412 RandomNumberDistribution_ParametersQtQuery(Parameter<RandomNumberDistribution_Parameters> &, std::string title,QBoxLayout *,Dialog *); 423 413 virtual ~RandomNumberDistribution_ParametersQtQuery(); 424 virtual bool handle();425 414 426 415 public slots: -
src/UIElements/Qt4/Query/RandomNumberDistribution_ParametersQtQuery.cpp
r1c55b8 r852ea3 31 31 32 32 QtDialog::RandomNumberDistribution_ParametersQtQuery::RandomNumberDistribution_ParametersQtQuery(Parameter<RandomNumberDistribution_Parameters> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 33 Dialog::TQuery<RandomNumberDistribution_Parameters>(_param, _title),33 QtQuery<RandomNumberDistribution_Parameters>(_param, _title), 34 34 parent(_parent), 35 35 dialog(_dialog) … … 65 65 } 66 66 67 bool QtDialog::RandomNumberDistribution_ParametersQtQuery::handle() {68 if (param.isValid(temp)){69 param.set(temp);70 return true;71 }72 return false;73 }74 67 75 -
src/UIElements/Qt4/Query/RealSpaceMatrixQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::RealSpaceMatrixQtQuery::RealSpaceMatrixQtQuery(Parameter<RealSpaceMatrix> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 32 Dialog::TQuery<RealSpaceMatrix>(_param, _title),32 QtQuery<RealSpaceMatrix>(_param, _title), 33 33 parent(_parent), 34 34 dialog(_dialog) … … 70 70 } 71 71 72 bool QtDialog::RealSpaceMatrixQtQuery::handle() {73 if (param.isValid(temp)){74 param.set(temp);75 return true;76 }77 return false;78 }79 72 80 -
src/UIElements/Qt4/Query/StringQtQuery.cpp
r1c55b8 r852ea3 28 28 29 29 QtDialog::StringQtQuery::StringQtQuery(Parameter<std::string> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 30 Dialog::TQuery<std::string>(_param, _title),30 QtQuery<std::string>(_param, _title), 31 31 parent(_parent), 32 32 dialog(_dialog) … … 55 55 } 56 56 57 // All values besides the empty std::string are valid58 bool QtDialog::StringQtQuery::handle()59 {60 if (temp != "")61 if (param.isValid(temp)){62 param.set(temp);63 return true;64 }65 return false;66 }67 -
src/UIElements/Qt4/Query/StringsQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::StringsQtQuery::StringsQtQuery(Parameter<std::vector<std::string> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<std::string> >(_param, _title),31 QtQuery<std::vector<std::string> >(_param, _title), 32 32 QtQueryList<std::string>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 // All values besides the empty std::string are valid66 bool QtDialog::StringsQtQuery::handle()67 {68 if (param.isValid(temp)){69 param.set(temp);70 return true;71 }72 return false;73 }74 -
src/UIElements/Qt4/Query/UnsignedIntQtQuery.cpp
r1c55b8 r852ea3 28 28 29 29 QtDialog::UnsignedIntQtQuery::UnsignedIntQtQuery(Parameter<unsigned int> &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 30 Dialog::TQuery<unsigned int>(_param, _title),30 QtQuery<unsigned int>(_param, _title), 31 31 parent(_parent), 32 32 dialog(_dialog) … … 56 56 } 57 57 58 bool QtDialog::UnsignedIntQtQuery::handle() {59 if (param.isValid(temp)){60 param.set(temp);61 return true;62 }63 return false;64 }65 -
src/UIElements/Qt4/Query/UnsignedIntsQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::UnsignedIntsQtQuery::UnsignedIntsQtQuery(Parameter<std::vector<unsigned int> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<std::vector<unsigned int> >(_param, _title),31 QtQuery<std::vector<unsigned int> >(_param, _title), 32 32 QtQueryList<unsigned int>(_parent, _dialog, temp) 33 33 { … … 63 63 } 64 64 65 bool QtDialog::UnsignedIntsQtQuery::handle()66 {67 if (param.isValid(temp)){68 param.set(temp);69 return true;70 }71 return false;72 }73 65 74 66 75 -
src/UIElements/Qt4/Query/VectorQtQuery.cpp
r1c55b8 r852ea3 29 29 30 30 QtDialog::VectorQtQuery::VectorQtQuery(Parameter<Vector> &_param, std::string title, QBoxLayout *_parent,Dialog *_dialog) : 31 Dialog::TQuery<Vector>(_param, title),31 QtQuery<Vector>(_param, title), 32 32 parent(_parent), 33 33 dialog(_dialog) … … 88 88 } 89 89 90 bool QtDialog::VectorQtQuery::handle() {91 if (param.isValid(temp)){92 param.set(temp);93 return true;94 }95 return false;96 }97 90 98 -
src/UIElements/Qt4/Query/VectorsQtQuery.cpp
r1c55b8 r852ea3 30 30 31 31 QtDialog::VectorsQtQuery::VectorsQtQuery(Parameter<std::vector<Vector> > &_param, std::string _title,QBoxLayout *_parent,Dialog *_dialog) : 32 Dialog::TQuery<std::vector<Vector> >(_param, _title),32 QtQuery<std::vector<Vector> >(_param, _title), 33 33 QtQueryList<Vector>(_parent, _dialog, temp) 34 34 { … … 64 64 } 65 65 66 bool QtDialog::VectorsQtQuery::handle()67 {68 if (param.isValid(temp)){69 param.set(temp);70 return true;71 }72 return false;73 }74 66 75
Note:
See TracChangeset
for help on using the changeset viewer.