- Timestamp:
- Sep 19, 2013, 8:23:52 PM (11 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:
- c5177f
- Parents:
- 126867
- git-author:
- Frederik Heber <heber@…> (08/20/13 20:31:52)
- git-committer:
- Frederik Heber <heber@…> (09/19/13 20:23:52)
- Location:
- src
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Actions/ActionQueue.cpp
r126867 r05c989 55 55 ActionQueue::~ActionQueue() 56 56 { 57 queue.clear(); 57 58 delete history; 58 59 delete AR; 60 } 61 62 void ActionQueue::queueAction(const std::string &name) 63 { 64 Action* _action = AR->getActionByName(name); 65 queue.push_back(_action); 66 _action->call(); 59 67 } 60 68 -
src/Actions/ActionQueue.hpp
r126867 r05c989 39 39 typedef std::vector<std::string> ActionTokens_t; 40 40 typedef std::list<Action *> ActionQueue_t; 41 42 /** Queues the Action with \a name to be called. 43 * 44 */ 45 void queueAction(const std::string &name); 41 46 42 47 /** Returns the spawned action by token \a name. -
src/UIElements/CommandLineUI/CommandLineWindow.cpp
r126867 r05c989 73 73 if (AQ.isActionKnownByName(*CommandRunner)) { 74 74 // LOG1, "INFO: Checking presence of " << *CommandRunner << ": " << "calling " << *CommandRunner); 75 A Q.getActionByName(*CommandRunner)->call();75 ActionQueue::getInstance().queueAction(*CommandRunner); 76 76 } else { 77 77 // LOG(1, "INFO: Checking presence of " << *CommandRunner << ": " << "absent."); -
src/UIElements/Menu/Qt4/QtMenuPipe.cpp
r126867 r05c989 55 55 56 56 void QtMenuPipe::called() { 57 Action* action = ActionQueue::getInstance().getActionByName(ActionName);58 57 try{ 59 action->call();58 ActionQueue::getInstance().queueAction(ActionName); 60 59 }catch(ActionFailureException e){ 61 60 ELOG(1, "Action failed or cancelled"); -
src/UIElements/Menu/TextMenu/ActionMenuItem.cpp
r126867 r05c989 53 53 54 54 void ActionMenuItem::doTrigger() { 55 Action* action = ActionQueue::getInstance().getActionByName(ActionName); 56 action->call(); 55 ActionQueue::getInstance().queueAction(ActionName); 57 56 } 58 57 -
src/UIElements/Qt4/QtMainWindow.cpp
r126867 r05c989 172 172 MoleCuilder::WorldOutput(); 173 173 else{ 174 Action* action = ActionQueue::getInstance().getActionByName("output-as");175 174 try{ 176 action->call();175 ActionQueue::getInstance().queueAction("output-as"); 177 176 }catch(...){ 178 177 ELOG(1, "Action failed or cancelled");
Note:
See TracChangeset
for help on using the changeset viewer.