| 1 | /* | 
|---|
| 2 | * Project: MoleCuilder | 
|---|
| 3 | * Description: creates and alters molecular systems | 
|---|
| 4 | * Copyright (C)  2010 University of Bonn. All rights reserved. | 
|---|
| 5 | * Please see the LICENSE file or "Copyright notice" in builder.cpp for details. | 
|---|
| 6 | */ | 
|---|
| 7 |  | 
|---|
| 8 | /* | 
|---|
| 9 | * CommandLineDialog.cpp | 
|---|
| 10 | * | 
|---|
| 11 | *  Created on: May 8, 2010 | 
|---|
| 12 | *      Author: heber | 
|---|
| 13 | */ | 
|---|
| 14 |  | 
|---|
| 15 | // include config.h | 
|---|
| 16 | #ifdef HAVE_CONFIG_H | 
|---|
| 17 | #include <config.h> | 
|---|
| 18 | #endif | 
|---|
| 19 |  | 
|---|
| 20 | #include "Helpers/MemDebug.hpp" | 
|---|
| 21 |  | 
|---|
| 22 | #include "CommandLineUI/CommandLineDialog.hpp" | 
|---|
| 23 |  | 
|---|
| 24 |  | 
|---|
| 25 | using namespace std; | 
|---|
| 26 |  | 
|---|
| 27 |  | 
|---|
| 28 | CommandLineDialog::CommandLineDialog() | 
|---|
| 29 | { | 
|---|
| 30 | } | 
|---|
| 31 |  | 
|---|
| 32 | CommandLineDialog::~CommandLineDialog() | 
|---|
| 33 | { | 
|---|
| 34 | } | 
|---|
| 35 |  | 
|---|
| 36 |  | 
|---|
| 37 | void CommandLineDialog::queryEmpty(const char* title, string _description){ | 
|---|
| 38 | registerQuery(new EmptyCommandLineQuery(title, _description)); | 
|---|
| 39 | } | 
|---|
| 40 |  | 
|---|
| 41 | void CommandLineDialog::queryInt(const char* title, string _description){ | 
|---|
| 42 | registerQuery(new IntCommandLineQuery(title, _description)); | 
|---|
| 43 | } | 
|---|
| 44 |  | 
|---|
| 45 | void CommandLineDialog::queryInts(const char* title, string _description){ | 
|---|
| 46 | registerQuery(new IntsCommandLineQuery(title, _description)); | 
|---|
| 47 | } | 
|---|
| 48 |  | 
|---|
| 49 | void CommandLineDialog::queryBoolean(const char* title, string _description){ | 
|---|
| 50 | registerQuery(new BooleanCommandLineQuery(title, _description)); | 
|---|
| 51 | } | 
|---|
| 52 |  | 
|---|
| 53 | void CommandLineDialog::queryDouble(const char* title, string _description){ | 
|---|
| 54 | registerQuery(new DoubleCommandLineQuery(title, _description)); | 
|---|
| 55 | } | 
|---|
| 56 |  | 
|---|
| 57 | void CommandLineDialog::queryDoubles(const char* title, string _description){ | 
|---|
| 58 | registerQuery(new DoublesCommandLineQuery(title, _description)); | 
|---|
| 59 | } | 
|---|
| 60 |  | 
|---|
| 61 | void CommandLineDialog::queryString(const char* title, string _description){ | 
|---|
| 62 | registerQuery(new StringCommandLineQuery(title, _description)); | 
|---|
| 63 | } | 
|---|
| 64 |  | 
|---|
| 65 | void CommandLineDialog::queryStrings(const char* title, string _description){ | 
|---|
| 66 | registerQuery(new StringsCommandLineQuery(title, _description)); | 
|---|
| 67 | } | 
|---|
| 68 |  | 
|---|
| 69 | void CommandLineDialog::queryAtom(const char* title, string _description) { | 
|---|
| 70 | registerQuery(new AtomCommandLineQuery(title, _description)); | 
|---|
| 71 | } | 
|---|
| 72 |  | 
|---|
| 73 | void CommandLineDialog::queryAtoms(const char* title, string _description) { | 
|---|
| 74 | registerQuery(new AtomsCommandLineQuery(title, _description)); | 
|---|
| 75 | } | 
|---|
| 76 |  | 
|---|
| 77 | void CommandLineDialog::queryMolecule(const char* title, string _description) { | 
|---|
| 78 | registerQuery(new MoleculeCommandLineQuery(title, _description)); | 
|---|
| 79 | } | 
|---|
| 80 |  | 
|---|
| 81 | void CommandLineDialog::queryMolecules(const char* title, string _description) { | 
|---|
| 82 | registerQuery(new MoleculesCommandLineQuery(title, _description)); | 
|---|
| 83 | } | 
|---|
| 84 |  | 
|---|
| 85 | void CommandLineDialog::queryVector(const char* title, bool check, string _description) { | 
|---|
| 86 | registerQuery(new VectorCommandLineQuery(title,check, _description)); | 
|---|
| 87 | } | 
|---|
| 88 |  | 
|---|
| 89 | void CommandLineDialog::queryVectors(const char* title, bool check, string _description) { | 
|---|
| 90 | registerQuery(new VectorsCommandLineQuery(title,check, _description)); | 
|---|
| 91 | } | 
|---|
| 92 |  | 
|---|
| 93 | void CommandLineDialog::queryBox(const char* title, string _description) { | 
|---|
| 94 | registerQuery(new BoxCommandLineQuery(title,_description)); | 
|---|
| 95 | } | 
|---|
| 96 |  | 
|---|
| 97 | void CommandLineDialog::queryElement(const char* title, string _description){ | 
|---|
| 98 | registerQuery(new ElementCommandLineQuery(title, _description)); | 
|---|
| 99 | } | 
|---|
| 100 |  | 
|---|
| 101 | void CommandLineDialog::queryElements(const char* title, string _description){ | 
|---|
| 102 | registerQuery(new ElementsCommandLineQuery(title, _description)); | 
|---|
| 103 | } | 
|---|
| 104 |  | 
|---|
| 105 | void CommandLineDialog::queryFile(const char* title, string _description){ | 
|---|
| 106 | registerQuery(new FileCommandLineQuery(title, _description)); | 
|---|
| 107 | } | 
|---|
| 108 |  | 
|---|
| 109 | /************************** Query Infrastructure ************************/ | 
|---|
| 110 | /*       ---> shifted to folder Query                                   */ | 
|---|
| 111 | /************************************************************************/ | 
|---|