- Timestamp:
- Apr 18, 2016, 10:33:41 PM (9 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:
- ea2663
- Parents:
- 24eb6b
- git-author:
- Frederik Heber <heber@…> (03/18/16 10:17:01)
- git-committer:
- Frederik Heber <heber@…> (04/18/16 22:33:41)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/UIElements/Views/Qt4/MoleculeList/QtMoleculeList.hpp
r24eb6b r5771e6 26 26 27 27 #include "UIElements/Views/Qt4/MoleculeList/QtMoleculeItem.hpp" 28 #include "UIElements/Views/Qt4/MoleculeList/QtObservedMoleculeObserver.hpp" 28 29 #include "UIElements/Qt4/InstanceBoard/QtObservedMolecule.hpp" 29 30 … … 47 48 48 49 private slots: 50 void formulaChanged(const QtObservedMolecule::ptr _mol); 51 void nameChanged(const QtObservedMolecule::ptr _mol); 52 49 53 void moleculeNameChanged(QStandardItem*); 50 54 void checkForVisibilityChange(QStandardItem*); 51 void checkState();52 53 friend class QtMoleculeItem;54 55 std::string readdItem(QtMoleculeItem *_molitem);56 55 57 56 signals: 58 void moleculeSelected( molecule*);59 void moleculeUnSelected( molecule*);57 void moleculeSelected(const QtObservedMolecule::ptr _mol); 58 void moleculeUnSelected(const QtObservedMolecule::ptr _mol); 60 59 void moleculesVisibilityChanged(const moleculeId_t, bool); 61 60 62 61 private: 63 64 bool ChangingChildrensVisibility;65 62 66 63 private slots: … … 70 67 71 68 private: 72 mutable boost::recursive_mutex listAccessing_mutex;73 mutable boost::recursive_mutex refill_mutex;74 mutable boost::recursive_mutex map_mutex;75 76 //!> informs the view in regular intervals about updates77 QTimer *update_timer;78 79 //!> how often per second update is signalled to view80 static const unsigned int update_times_per_second;81 82 69 friend class QtMoleculeListView; 83 70 … … 107 94 void removeMoleculeItem(QtMoleculeItem * const _item); 108 95 int setOccurrence(QStandardItem * const _groupitem); 109 bool areAnyItemsDirty();110 96 void setVisibilityForMoleculeItem(QtMoleculeItem* _item); 111 97 void setVisibilityForGroupItem(QStandardItem* _item); 98 void moveItem(QtMoleculeItem *_molitem, const std::string &_new_formula); 112 99 113 void updateItemStates();100 // void updateItemStates(); 114 101 115 102 //!> reference to InstanceBoard … … 130 117 MoleculeItemBiMap_t MoleculeItemBiMap; 131 118 132 typedef std::map<moleculeId_t, unsigned int> KilledItemsPerMolecule_t;133 //!> takes note of how many items have already been killed for a specific row/molecule134 KilledItemsPerMolecule_t KilledItemsPerMolecule;135 136 119 typedef std::set< moleculeId_t > list_of_molecules_t; 137 120 typedef std::set< std::pair<moleculeId_t, QtMoleculeItem::COLUMNTYPES> > list_of_molecule_items_t; 138 121 typedef std::set< std::pair<std::string, QtMoleculeItem::COLUMNTYPES> > list_of_group_items_t; 139 122 140 //!> list of molecule items that need an update 141 list_of_molecule_items_t dirtyMolItems; 142 //!> list of molecule items that need an update of visibility 143 list_of_molecules_t visibilityMolItems; 144 //!> list of group items that need an update 145 list_of_group_items_t dirtyGroupItems; 146 //!> list of group items that need an update of visibility 147 list_of_group_items_t visibilityGroupItems; 148 //!> list of new molecules which need to be added 149 std::vector<QtObservedMolecule::ptr> newMolecules; 150 //!> list of molecules that have been removed 151 std::vector<moleculeId_t> removedMolecules; 152 //!> list of molecule items to molecule's whose formulas has changed and need to be moved 153 list_of_molecules_t toBeMovedItems; 123 //!> listens to all QtObservedMolecule and relays important events to us 124 QtObservedMoleculeObserver observer; 154 125 }; 155 126
Note:
See TracChangeset
for help on using the changeset viewer.