112 ACs->getNumberOfSelectedJpsWalkableAreas() +
113 ACs->getNumberOfSelectedJpsObstacles());
132 if (numberLines == 0) {
134 }
else if (numberLines > 1) {
253 FXVerticalFrame* col1 =
new FXVerticalFrame(selectionButtons, LAYOUT_FILL_X, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
254 FXVerticalFrame* col2 =
new FXVerticalFrame(selectionButtons, LAYOUT_FILL_X, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
276 std::vector<GNEAttributeCarrier*> loadedACs;
277 std::ifstream strm(file.c_str());
283 std::map<const std::string, GNEAttributeCarrier*> GLFUllNameAC;
285 for (
const auto& GLObject : GLObjects) {
294 while (strm.good()) {
298 if (line.length() != 0) {
310 loadedACs.push_back(AC);
316 if (loadedACs.size() > 0) {
330 opendialog.setSelectMode(SELECTFILE_EXISTING);
335 if (opendialog.execute()) {
354 const auto selectedACs =
mySelectorFrameParent->myViewNet->getNet()->getAttributeCarriers()->getSelectedAttributeCarriers(
false);
355 for (
const auto& selectedAC : selectedACs) {
365 TL(
"Storing Selection failed"), e.what());
383 bool askedContinueIfLock =
false;
384 bool addLockedElements =
false;
385 bool unlockedElements =
false;
386 for (
const auto& ACToUnselect : massiveSelection.
ACsToUnselect) {
387 if (ACToUnselect.second ==
false) {
389 unlockedElements =
true;
390 }
else if (!askedContinueIfLock) {
393 askedContinueIfLock =
true;
396 if (unlockedElements || addLockedElements) {
398 for (
const auto& ACToUnselect : massiveSelection.
ACsToUnselect) {
399 if (addLockedElements || !ACToUnselect.second) {
430 bool askedContinueIfLock =
false;
431 bool addLockedElements =
false;
432 bool unlockedElements =
false;
433 for (
const auto& ACToSelect : massiveSelection.
ACsToSelect) {
434 if (ACToSelect.second ==
false) {
436 unlockedElements =
true;
437 }
else if (!askedContinueIfLock) {
440 askedContinueIfLock =
true;
443 for (
const auto& ACToUnselect : massiveSelection.
ACsToUnselect) {
444 if (ACToUnselect.second ==
false) {
446 unlockedElements =
true;
447 }
else if (!askedContinueIfLock) {
450 askedContinueIfLock =
true;
453 if (unlockedElements || addLockedElements) {
455 for (
const auto& ACToSelect : massiveSelection.
ACsToSelect) {
456 if (addLockedElements || !ACToSelect.second) {
460 for (
const auto& ACToUnselect : massiveSelection.
ACsToUnselect) {
461 if (addLockedElements || !ACToUnselect.second) {
479 std::unordered_set<GNENetworkElement*> networkElementsToRemove;
480 std::unordered_set<GNENetworkElement*> edgesToKeep;
482 for (
const auto& junction :
mySelectorFrameParent->myViewNet->getNet()->getAttributeCarriers()->getJunctions()) {
483 if (!junction.second->isAttributeCarrierSelected()) {
484 networkElementsToRemove.insert(junction.second);
487 for (
const auto& incomingEdge : junction.second->getGNEIncomingEdges()) {
488 if (!incomingEdge->isAttributeCarrierSelected()) {
489 networkElementsToRemove.insert(incomingEdge);
491 edgesToKeep.insert(incomingEdge);
496 for (
const auto& edge : edgesToKeep) {
497 for (
const auto& junctionParent : edge->getParentJunctions()) {
498 auto it = networkElementsToRemove.find(junctionParent);
499 if (it != networkElementsToRemove.end()) {
500 networkElementsToRemove.erase(it);
505 const auto shapeElementsToRemove =
mySelectorFrameParent->myViewNet->getNet()->getAttributeCarriers()->getUnselectedShapes();
507 for (
const auto shapeElement : shapeElementsToRemove) {
510 for (
const auto networkElement : networkElementsToRemove) {
528 std::unordered_set<GNEAttributeCarrier*> networkACs;
530 for (
const auto& junction : ACs->getJunctions()) {
531 networkACs.insert(junction.second);
533 for (
const auto& incomingEdge : junction.second->getGNEIncomingEdges()) {
534 if (!filterLanes || selectEdges) {
535 networkACs.insert(incomingEdge);
538 if (!filterLanes || !selectEdges) {
539 for (
const auto& lane : incomingEdge->getChildLanes()) {
540 networkACs.insert(lane);
544 for (
const auto& connection : incomingEdge->getGNEConnections()) {
545 networkACs.insert(connection);
549 for (
const auto& crossing : junction.second->getGNECrossings()) {
550 networkACs.insert(crossing);
553 for (
const auto& walkingArea : junction.second->getGNEWalkingAreas()) {
554 networkACs.insert(walkingArea);
558 for (
const auto& additionalTags : ACs->getAdditionals()) {
559 for (
const auto& additional : additionalTags.second) {
560 if (additional.second->getTagProperty()->isSelectable()) {
561 networkACs.insert(additional.second);
568 for (
const auto& networkAC : networkACs) {
569 const auto networkACObjectType = networkAC->getGUIGlObject()->getType();
572 massiveSelection.
lockedTypes[networkACObjectType] = networkAC->getGUIGlObject()->isGLObjectLocked();
575 if (networkAC->isAttributeCarrierSelected()) {
581 return massiveSelection;
591 for (
const auto& demandElementTag : ACs->getDemandElements()) {
592 for (
const auto& demandElement : demandElementTag.second) {
593 if (demandElement.second->getTagProperty()->isSelectable()) {
594 const auto networkACObjectType = demandElement.first->getType();
597 massiveSelection.
lockedTypes[networkACObjectType] = demandElement.first->isGLObjectLocked();
600 if (demandElement.second->isAttributeCarrierSelected()) {
603 massiveSelection.
ACsToSelect[demandElement.second] = massiveSelection.
lockedTypes.at(networkACObjectType);
608 return massiveSelection;
618 for (
const auto& genericDataTag :
mySelectorFrameParent->myViewNet->getNet()->getAttributeCarriers()->getGenericDatas()) {
619 for (
const auto& genericData : genericDataTag.second) {
620 if (genericData.second->getTagProperty()->isSelectable()) {
621 const auto networkACObjectType = genericData.first->getType();
624 massiveSelection.
lockedTypes[networkACObjectType] = genericData.first->isGLObjectLocked();
627 if (genericData.second->isAttributeCarrierSelected()) {
635 return massiveSelection;
644 TL(
"Confirm selection operation"),
645 TL(
"There are locked elements in the current selection."),
646 TL(
"Apply operation to locked elements?"));
680 const auto staticTooltipMenu = selectorFrameParent->
getViewNet()->getViewParent()->getGNEAppWindows()->getStaticTooltipMenu();
704 for (
const auto& item :
myItems) {
717 for (
const auto& item :
myItems) {
737 for (
const auto& item :
myItems) {
765 const auto selectedACs = viewNet->getNet()->getAttributeCarriers()->getSelectedAttributeCarriers(
true);
769 std::vector<GNEAttributeCarrier*> editedParents;
770 for (
const auto& selectedAC : selectedACs) {
772 const auto connection = viewNet->getNet()->getAttributeCarriers()->retrieveConnection(selectedAC->getGUIGlObject());
773 editedParents.push_back(connection->getLaneFrom());
774 editedParents.push_back(connection->getLaneTo());
776 const auto crossing = viewNet->getNet()->getAttributeCarriers()->retrieveCrossing(selectedAC->getGUIGlObject());
777 editedParents.push_back(crossing->getParentJunctions().front());
780 const auto hierarchicalElement = selectedAC->getHierarchicalElement();
783 editedParents.insert(editedParents.end(), hierarchicalElement->getParentJunctions().begin(), hierarchicalElement->getParentJunctions().end());
787 if (selectedAC->getTagProperty()->getTag() ==
SUMO_TAG_LANE) {
789 editedParents.push_back(
dynamic_cast<GNELane*
>(selectedAC)->getParentEdge());
790 }
else if (selectedAC->getTagProperty()->getTag() ==
SUMO_TAG_TAZ) {
792 for (
const auto& tss : selectedAC->getHierarchicalElement()->getChildTAZSourceSinks()) {
793 editedParents.push_back(tss->getParentEdges().front());
796 editedParents.insert(editedParents.end(), hierarchicalElement->getParentEdges().begin(), hierarchicalElement->getParentEdges().end());
801 editedParents.insert(editedParents.end(), hierarchicalElement->getParentLanes().begin(), hierarchicalElement->getParentLanes().end());
805 editedParents.insert(editedParents.end(), hierarchicalElement->getParentAdditionals().begin(), hierarchicalElement->getParentAdditionals().end());
809 editedParents.insert(editedParents.end(), hierarchicalElement->getParentAdditionals().begin(), hierarchicalElement->getParentAdditionals().end());
813 editedParents.insert(editedParents.end(), hierarchicalElement->getParentDemandElements().begin(), hierarchicalElement->getParentDemandElements().end());
817 editedParents.insert(editedParents.end(), hierarchicalElement->getParentGenericDatas().begin(), hierarchicalElement->getParentGenericDatas().end());
822 if (editedParents.size() > 0) {
823 if (editedParents.size() > 1) {
826 for (
const auto& HE : editedParents) {
833 if (editedParents.size() > 1) {
834 viewNet->getUndoList()->end();
849 const auto selectedACs =
mySelectorFrameParent->getViewNet()->getNet()->getAttributeCarriers()->getSelectedAttributeCarriers(
true);
853 std::vector<GNEAttributeCarrier*> editedChildren;
854 for (
const auto& selectedAC : selectedACs) {
856 const auto hierarchicalElement = selectedAC->getHierarchicalElement();
861 const auto junction =
dynamic_cast<GNEJunction*
>(selectedAC);
863 editedChildren.insert(editedChildren.end(), junction->getGNEIncomingEdges().begin(), junction->getGNEIncomingEdges().end());
864 editedChildren.insert(editedChildren.end(), junction->getGNEOutgoingEdges().begin(), junction->getGNEOutgoingEdges().end());
866 editedChildren.insert(editedChildren.end(), hierarchicalElement->getChildJunctions().begin(), hierarchicalElement->getChildJunctions().end());
871 if (selectedAC->getTagProperty()->getTag() ==
SUMO_TAG_EDGE) {
873 const auto edge =
dynamic_cast<GNEEdge*
>(selectedAC);
875 editedChildren.insert(editedChildren.end(), edge->getChildLanes().begin(), edge->getChildLanes().end());
877 editedChildren.insert(editedChildren.end(), hierarchicalElement->getChildEdges().begin(), hierarchicalElement->getChildEdges().end());
882 if (selectedAC->getTagProperty()->getTag() ==
SUMO_TAG_EDGE) {
884 const auto edge =
dynamic_cast<GNEEdge*
>(selectedAC);
886 editedChildren.insert(editedChildren.end(), edge->getGNEConnections().begin(), edge->getGNEConnections().end());
887 }
else if (selectedAC->getTagProperty()->getTag() ==
SUMO_TAG_LANE) {
889 const auto lane =
dynamic_cast<GNELane*
>(selectedAC);
891 for (
const auto& connection : lane->getParentEdge()->getGNEConnections()) {
893 editedChildren.push_back(connection);
898 const auto junction =
dynamic_cast<GNEJunction*
>(selectedAC);
902 editedChildren.insert(editedChildren.end(), connections.begin(), connections.end());
909 const auto junction =
dynamic_cast<GNEJunction*
>(selectedAC);
911 editedChildren.insert(editedChildren.end(), junction->getGNECrossings().begin(), junction->getGNECrossings().end());
916 editedChildren.insert(editedChildren.end(), hierarchicalElement->getChildLanes().begin(), hierarchicalElement->getChildLanes().end());
921 for (
const auto& additionalChild : hierarchicalElement->getChildAdditionals()) {
922 if (!additionalChild->getTagProperty()->isWireElement() && !additionalChild->getTagProperty()->isSymbol()) {
923 editedChildren.push_back(additionalChild);
930 for (
const auto& wireChild : hierarchicalElement->getChildAdditionals()) {
931 if (wireChild->getTagProperty()->isWireElement() && !wireChild->getTagProperty()->isSymbol()) {
932 editedChildren.push_back(wireChild);
938 editedChildren.insert(editedChildren.end(), hierarchicalElement->getChildDemandElements().begin(), hierarchicalElement->getChildDemandElements().end());
942 editedChildren.insert(editedChildren.end(), hierarchicalElement->getChildGenericDatas().begin(), hierarchicalElement->getChildGenericDatas().end());
946 if (editedChildren.size() > 0) {
947 if (editedChildren.size() > 1) {
950 for (
const auto& HE : editedChildren) {
957 if (editedChildren.size() > 1) {
987 GNEFrame(viewParent, viewNet,
TL(
"Selection")) {
1043 if (AC ==
nullptr) {
1047 if (
myViewNet->getLockManager().isObjectLocked(AC->getGUIGlObject()->getType(), AC->isAttributeCarrierSelected())) {
1051 if ((AC->getTagProperty()->isNetworkElement() || AC->getTagProperty()->isAdditionalElement()) &&
1052 !
myViewNet->getEditModes().isCurrentSupermodeNetwork()) {
1055 if (AC->getTagProperty()->isDemandElement() && !
myViewNet->getEditModes().isCurrentSupermodeDemand()) {
1058 if (AC->getTagProperty()->isDataElement() && !
myViewNet->getEditModes().isCurrentSupermodeData()) {
1064 if (filteredGLObjects.size() > 1) {
1065 myViewNet->openSelectDialogAtCursor(filteredGLObjects);
1068 if (AC->isAttributeCarrierSelected()) {
1069 AC->unselectAttributeCarrier();
1071 AC->selectAttributeCarrier();
1085 std::set<std::pair<std::string, GNEAttributeCarrier*> > ACsToSelect, ACsToUnselect;
1089 auto selectedACs =
myViewNet->getNet()->getAttributeCarriers()->getSelectedAttributeCarriers(
false);
1091 for (
const auto& selectedAC : selectedACs) {
1092 ACsToUnselect.insert(std::make_pair(selectedAC->getID(), selectedAC));
1096 for (
const auto& AC : ACs) {
1098 switch (setOperation) {
1100 ACsToUnselect.insert(std::make_pair(AC->getID(), AC));
1103 if (ACsToUnselect.find(std::make_pair(AC->getID(), AC)) != ACsToUnselect.end()) {
1104 ACsToSelect.insert(std::make_pair(AC->getID(), AC));
1108 ACsToSelect.insert(std::make_pair(AC->getID(), AC));
1114 std::set<GNEEdge*> edgesToSelect;
1116 for (
const auto& AC : ACsToSelect) {
1117 if (AC.second->getTagProperty()->getTag() ==
SUMO_TAG_EDGE) {
1118 edgesToSelect.insert(
myViewNet->getNet()->getAttributeCarriers()->retrieveEdge(AC.second->getID()));
1122 for (
const auto& edgeToSelect : edgesToSelect) {
1124 ACsToSelect.insert(std::make_pair(edgeToSelect->getFromJunction()->getID(), edgeToSelect->getFromJunction()));
1125 for (
const auto& connectionToSelect : edgeToSelect->getFromJunction()->getGNEConnections()) {
1126 ACsToSelect.insert(std::make_pair(connectionToSelect->getID(), connectionToSelect));
1128 for (
const auto& fromCrossingToSelect : edgeToSelect->getFromJunction()->getGNECrossings()) {
1129 ACsToSelect.insert(std::make_pair(fromCrossingToSelect->getID(), fromCrossingToSelect));
1131 for (
const auto& fromWalkingAreaToSelect : edgeToSelect->getFromJunction()->getGNEWalkingAreas()) {
1132 ACsToSelect.insert(std::make_pair(fromWalkingAreaToSelect->getID(), fromWalkingAreaToSelect));
1135 ACsToSelect.insert(std::make_pair(edgeToSelect->getToJunction()->getID(), edgeToSelect->getToJunction()));
1136 for (
const auto& connectionToSelect : edgeToSelect->getToJunction()->getGNEConnections()) {
1137 ACsToSelect.insert(std::make_pair(connectionToSelect->getID(), connectionToSelect));
1139 for (
const auto& toCrossingToSelect : edgeToSelect->getToJunction()->getGNECrossings()) {
1140 ACsToSelect.insert(std::make_pair(toCrossingToSelect->getID(), toCrossingToSelect));
1142 for (
const auto& toWalkingAreaToSelect : edgeToSelect->getToJunction()->getGNEWalkingAreas()) {
1143 ACsToSelect.insert(std::make_pair(toWalkingAreaToSelect->getID(), toWalkingAreaToSelect));
1148 if ((ACsToSelect.size() + ACsToUnselect.size()) > 0) {
1151 for (
const auto& ACToUnselect : ACsToUnselect) {
1152 if (ACToUnselect.second->getTagProperty()->isSelectable()) {
1156 for (
const auto& ACToSelect : ACsToSelect) {
1157 if (ACToSelect.second->getTagProperty()->isSelectable()) {
FXDEFMAP(GNESelectorFrame::ModificationMode) ModificationModeMap[]
@ NETWORK
Network mode (Edges, junctions, etc..).
@ MID_GNE_SELECTORFRAME_SELECTSCALE
changes the visual scaling of selected items
@ MID_GNE_SELECTORFRAME_CHILDREN
select/unselect children
@ MID_CHOOSEN_SAVE
Save set.
@ MID_CHOOSEN_INVERT
Deselect selected items.
@ MID_CHOOSEN_DELETE
delete set
@ MID_CHOOSEN_OPERATION
set type of selection
@ MID_CHOOSEN_LOAD
Load set.
@ MID_CHOOSEN_REDUCE
simplify network reduction
@ MID_CHOOSEN_CLEAR
Clear set.
@ MID_GNE_SELECT
select element
@ MID_GNE_SELECTORFRAME_PARENTS
select/unselect parents
#define GUIDesignSpinDial
#define GUIDesignTextColorRed
red color (for invalid text)
#define GUIDesignComboBox
#define GUIDesignAuxiliarHorizontalFrame
design for auxiliar (Without borders) horizontal frame used to pack another frames
#define GUIDesignComboBoxVisibleItems
#define GUIDesignLabelThick(justify)
label extended over frame with thick and with text justify to left
#define GUIDesignTextColorBlack
black color (for correct text)
#define GUIDesignRadioButton
#define GUIDesignLabelFrameInformation
label extended over frame without thick and with text justify to left, used to show information in fr...
FXString gCurrentFolder
The folder used as last.
#define WRITE_ERRORF(...)
@ SUMO_TAG_TAZ
a traffic assignment zone
@ SUMO_TAG_CONNECTION
connectioon between two lanes
@ SUMO_TAG_JUNCTION
begin/end of the description of a junction
@ SUMO_TAG_CROSSING
crossing between edges for pedestrians
@ SUMO_TAG_LANE
begin/end of the description of a single lane
@ SUMO_TAG_EDGE
begin/end of the description of an edge
@ GNE_ATTR_SELECTED
element is selected
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
const std::string getID() const override
get ID (all Attribute Carriers have one)
bool isTemplate() const
check if this AC is template
const GNETagProperties * getTagProperty() const
get tagProperty associated with this Attribute Carrier
virtual GUIGlObject * getGUIGlObject()=0
get GUIGlObject associated with this AttributeCarrier
Result getResult() const
get result to indicate if this dialog was closed accepting or rejecting changes
GNEViewNet * getViewNet() const
get view net
GNEViewNet * myViewNet
FOX need this.
FXVerticalFrame * myContentFrame
Vertical frame that holds all widgets of frame.
virtual void show()
show Frame
virtual void hide()
hide Frame
GNEFrame(GNEViewParent *viewParent, GNEViewNet *viewNet, const std::string &frameLabel)
Constructor.
GNEGroupBoxModule (based on FXGroupBox).
GNEGroupBoxModule(GNEFrame *frame, const std::string &text, const int options=Options::COLLAPSIBLE)
constructor for frames
FXVerticalFrame * getCollapsableFrame()
get collapsable frame (used by all elements that will be collapsed if button is toggled)
std::vector< GNEConnection * > getGNEConnections() const
Returns all GNEConnections vinculated with this junction.
FXRadioButton * myReplaceRadioButton
replace radio button
Operation
FOX-declaration.
ModificationMode(GNESelectorFrame *selectorFrameParent)
constructor
Operation myModificationModeType
how to modify selection
long onCmdSelectModificationMode(FXObject *, FXSelector, void *)
FXRadioButton * myAddRadioButton
FOX need this.
~ModificationMode()
destructor
Operation getModificationMode() const
get current modification mode
FXRadioButton * myRemoveRadioButton
remove radio button
FXRadioButton * myKeepRadioButton
keep button
SelectionHierarchy(GNESelectorFrame *selectorFrameParent)
FOX-declaration.
MFXComboBoxIcon * myChildrenComboBox
comboBox for children
~SelectionHierarchy()
destructor
FXButton * myUnselectParentsButton
unselect parents button
Selection myCurrentSelectedChild
current selected child
GNESelectorFrame * mySelectorFrameParent
pointer to Selector Frame Parent
FXButton * mySelectParentsButton
select parents button
FXButton * myUnselectChildrenButton
unselect parents button
long onCmdParents(FXObject *obj, FXSelector, void *)
called when user press select/unselect parents button
long onCmdChildren(FXObject *obj, FXSelector, void *)
called when user press select/unselect children button
long onCmdSelectItem(FXObject *obj, FXSelector, void *)
called when user select an item in comboBox
MFXComboBoxIcon * myParentsComboBox
comboBox for parents
const std::vector< std::pair< Selection, std::string > > myItems
FXButton * mySelectChildrenButton
select children button
Selection myCurrentSelectedParent
current selected parent
SelectionOperation(GNESelectorFrame *selectorFrameParent)
FOX-declaration.
long onCmdSave(FXObject *, FXSelector, void *)
Called when the user presses the Save-button.
MassiveSelection processMassiveNetworkElementSelection(const bool filterLanes) const
process massive network element selection
bool askContinueIfLock() const
ask if continue due locking
long onCmdDelete(FXObject *, FXSelector, void *)
Called when the user presses the delete-button.
long onCmdReduce(FXObject *, FXSelector, void *)
Called when the user presses the Reduce-button.
~SelectionOperation()
destructor
long onCmdInvert(FXObject *, FXSelector, void *)
Called when the user presses the Invert-button.
long onCmdClear(FXObject *, FXSelector, void *)
Called when the user presses the Clear-button.
long onCmdLoad(FXObject *, FXSelector, void *)
Called when the user presses the Load-button.
void loadFromFile(const std::string &file) const
load from file
MassiveSelection processMassiveDataElementSelection() const
process massive dataelement selection
GNESelectorFrame * mySelectorFrameParent
pointer to Selector Frame Parent
MassiveSelection processMassiveDemandElementSelection() const
process massive demand element selection
GNESelectorFrame * mySelectorFrameParent
FOX need this.
~VisualScaling()
destructor
long onCmdScaleSelection(FXObject *, FXSelector, void *)
Called when the user changes visual scaling.
VisualScaling(GNESelectorFrame *selectorFrameParent)
FOX-declaration.
FXRealSpinner * mySelectionScaling
Spinner for selection scaling.
FXVerticalFrame * getContentFrame() const
get vertical frame that holds all widgets of frame
void updateFrameAfterUndoRedo()
function called after undo/redo in the current frame
ModificationMode * getModificationModeModul() const
get modification mode modul
GNESelectorFrame::SelectionOperation * mySelectionOperation
modul for selection operations
~GNESelectorFrame()
Destructor.
GNESelectorFrame::SelectionInformation * mySelectionInformation
modul for selection information
GNESelectorFrame::VisualScaling * myVisualScaling
modul for visual scaling
GNESelectorFrame::Information * myInformation
information modul
GNESelectorFrame::SelectionHierarchy * mySelectionHierarchy
modul for selection hierarchy
GNESelectorFrame::ModificationMode * myModificationMode
modul for change modification mode
GNEMatchAttribute * myMatchAttribute
modul for match attribute
void clearCurrentSelection() const
clear current selection with possibility of undo/redo
GNESelectorFrame::SelectionOperation * getSelectionOperationModul() const
get selection operation modul
void handleIDs(const std::vector< GNEAttributeCarrier * > &ACs, const ModificationMode::Operation setop=ModificationMode::Operation::DEFAULT)
apply list of ids to the current selection according to Operation,
GNESelectorFrame(GNEViewParent *viewParent, GNEViewNet *viewNet)
Constructor.
SelectionInformation * getSelectionInformation() const
get modul for selection information
bool selectAttributeCarrier(const GNEViewNetHelper::ViewObjectsSelector &viewObjects)
select attribute carrier (element)
bool isDataElement() const
return true if tag correspond to a data element
bool isSelectable() const
return true if tag correspond to a selectable element
bool isDemandElement() const
return true if tag correspond to a demand element
class used to group all variables related with objects under cursor after a click over view
GNEAttributeCarrier * getAttributeCarrierFront() const
get front attribute carrier or a pointer to nullptr
const std::vector< GUIGlObject * > & getGLObjects() const
get vector with GL objects
A single child window which contains a view of the simulation area.
static FXButton * buildFXButton(FXComposite *p, const std::string &text, const std::string &tip, const std::string &help, FXIcon *ic, FXObject *tgt, FXSelector sel, FXuint opts=BUTTON_NORMAL, FXint x=0, FXint y=0, FXint w=0, FXint h=0, FXint pl=DEFAULT_PAD, FXint pr=DEFAULT_PAD, FXint pt=DEFAULT_PAD, FXint pb=DEFAULT_PAD)
build button
static FXRadioButton * buildFXRadioButton(FXComposite *p, const std::string &text, const std::string &tip, const std::string &help, FXObject *tgt, FXSelector sel, FXuint opts=RADIOBUTTON_NORMAL, FXint x=0, FXint y=0, FXint w=0, FXint h=0, FXint pl=DEFAULT_PAD, FXint pr=DEFAULT_PAD, FXint pt=DEFAULT_PAD, FXint pb=DEFAULT_PAD)
build radio button
static StringBijection< GUIGlObjectType > TypeNames
associates object types with strings
GUIGlObjectType getType() const
Returns the type of the object as coded in GUIGlObjectType.
static GUIGlObjectStorage gIDStorage
A single static instance of this class.
static FXIcon * getIcon(const GUIIcon which)
returns a icon previously defined in the enum GUIIcon
A list item which allows for custom coloring.
static FXString getFilename2Write(FXWindow *parent, const FXString &header, const FXString &extensions, FXIcon *icon, FXString ¤tFolder)
Returns the file name to write.
Static storage of an output device and its base (abstract) implementation.
void close()
Closes the device and removes it from the dictionary.
static OutputDevice & getDevice(const std::string &name, bool usePrefix=true)
Returns the described OutputDevice.
static StringBijection< TXTFileExtension > TXTFileExtensions
TXT file Extensions.
static std::string replace(std::string str, const std::string &what, const std::string &by)
Replaces all occurrences of the second string by the third string within the first string.
static bool startsWith(const std::string &str, const std::string prefix)
Checks whether a given string starts with the prefix.
~MassiveSelection()
destructor
std::unordered_map< GNEAttributeCarrier *, bool > ACsToSelect
ACs to select (the bool flag shows if element is locked).
std::map< GUIGlObjectType, bool > lockedTypes
locked types
std::unordered_map< GNEAttributeCarrier *, bool > ACsToUnselect
ACs to select (the bool flag shows if element is locked).
bool isElementToProcess() const
check if there are element to process
MassiveSelection()
constructor (invalidated)
static std::vector< GUIGlObject * > filterElementsByLayer(const std::vector< GUIGlObject * > &GLObjects)
filter elements based on the layer