diff --git a/src/netedit/frames/GNEAttributesEditor.cpp b/src/netedit/frames/GNEAttributesEditor.cpp index 5b23e526323..bc750fcd5d9 100644 --- a/src/netedit/frames/GNEAttributesEditor.cpp +++ b/src/netedit/frames/GNEAttributesEditor.cpp @@ -52,7 +52,7 @@ #define MAX_ATTR 32 FXDEFMAP(GNEAttributesEditor) GNEAttributeTableMap[] = { - FXMAPFUNC(SEL_COMMAND, MID_HELP, GNEAttributesEditor::onCmdAttributeTableHelp) + FXMAPFUNC(SEL_COMMAND, MID_HELP, GNEAttributesEditor::onCmdAttributesEditorHelp) }; // Object implementation @@ -77,25 +77,25 @@ GNEAttributesEditor::GNEAttributesEditor(GNEFrame* frameParent, const int editor void -GNEAttributesEditor::showAttributeTableModule(GNEAttributeCarrier* AC) { +GNEAttributesEditor::showAttributesEditor(GNEAttributeCarrier* AC) { myEditedACs.clear(); myEditedACs.push_back(AC); - refreshAttributeTable(); + refreshAttributesEditor(); } void -GNEAttributesEditor::showAttributeTableModule(const std::unordered_set& ACs) { +GNEAttributesEditor::showAttributesEditor(const std::unordered_set& ACs) { myEditedACs.clear(); for (const auto& AC : ACs) { myEditedACs.push_back(AC); } - refreshAttributeTable(); + refreshAttributesEditor(); } void -GNEAttributesEditor::hideAttributeTableModule() { +GNEAttributesEditor::hideAttributesEditor() { myEditedACs.clear(); // hide all rows before hidding table for (const auto& row : myAttributesEditorRows) { @@ -106,7 +106,7 @@ GNEAttributesEditor::hideAttributeTableModule() { void -GNEAttributesEditor::refreshAttributeTable() { +GNEAttributesEditor::refreshAttributesEditor() { if (myEditedACs.size() > 0) { // Iterate over tag property of first AC and show row for every attribute int itRows = 0; @@ -136,12 +136,12 @@ GNEAttributesEditor::refreshAttributeTable() { } // only show if at least one row was shown if (itRows == 0) { - hideAttributeTableModule(); + hideAttributesEditor(); } else { show(); } } else { - hideAttributeTableModule(); + hideAttributesEditor(); } } @@ -153,7 +153,7 @@ GNEAttributesEditor::getFrameParent() const { long -GNEAttributesEditor::onCmdAttributeTableHelp(FXObject*, FXSelector, void*) { +GNEAttributesEditor::onCmdAttributesEditorHelp(FXObject*, FXSelector, void*) { if (myEditedACs.size() > 0) { myFrameParent->openHelpAttributesDialog(myEditedACs.front()); } @@ -180,7 +180,7 @@ GNEAttributesEditor::setAttribute(SumoXMLAttr attr, const std::string& value) { if ((myEditedACs.size() > 1) || (attr == SUMO_ATTR_ID)) { undoList->end(); } - refreshAttributeTable(); + refreshAttributesEditor(); // update frame parent (needed to update other attribute tables) myFrameParent->attributeUpdated(attr); } @@ -206,7 +206,7 @@ GNEAttributesEditor::toggleEnableAttribute(SumoXMLAttr attr, const bool value) { if ((myEditedACs.size() > 1) || (attr == SUMO_ATTR_ID)) { undoList->end(); } - refreshAttributeTable(); + refreshAttributesEditor(); // update frame parent (needed to update other attribute tables) myFrameParent->attributeUpdated(attr); } diff --git a/src/netedit/frames/GNEAttributesEditor.h b/src/netedit/frames/GNEAttributesEditor.h index 4a676d7fb12..22baa255658 100644 --- a/src/netedit/frames/GNEAttributesEditor.h +++ b/src/netedit/frames/GNEAttributesEditor.h @@ -55,16 +55,16 @@ class GNEAttributesEditor : public MFXGroupBoxModule { GNEAttributesEditor(GNEFrame* frameParent, const int editorOptions); /// @brief edit attributes of the given AC (usually the edited template AC) - void showAttributeTableModule(GNEAttributeCarrier* AC); + void showAttributesEditor(GNEAttributeCarrier* AC); /// @brief edit attributes of the given hash of ACs (usually the inspected ACs) - void showAttributeTableModule(const std::unordered_set& ACs); + void showAttributesEditor(const std::unordered_set& ACs); /// @brief hide attribute editor - void hideAttributeTableModule(); + void hideAttributesEditor(); /// @brief refresh attribute editor - void refreshAttributeTable(); + void refreshAttributesEditor(); /// @brief pointer to GNEFrame parent GNEFrame* getFrameParent() const; @@ -72,7 +72,7 @@ class GNEAttributesEditor : public MFXGroupBoxModule { /// @name FOX-callbacks /// @{ /// @brief Called when user press the help button - long onCmdAttributeTableHelp(FXObject*, FXSelector, void*); + long onCmdAttributesEditorHelp(FXObject*, FXSelector, void*); /// @} diff --git a/src/netedit/frames/common/GNEInspectorFrame.cpp b/src/netedit/frames/common/GNEInspectorFrame.cpp index e23ae6731e4..f57fb720213 100644 --- a/src/netedit/frames/common/GNEInspectorFrame.cpp +++ b/src/netedit/frames/common/GNEInspectorFrame.cpp @@ -327,9 +327,9 @@ GNEInspectorFrame::NeteditAttributesEditor::onCmdSetNeteditAttribute(FXObject* o myInspectorFrameParent->myViewNet->getUndoList()->end(); } // force refresh values of AttributesEditor and GEOAttributesEditor - myInspectorFrameParent->myAttributesEditor->refreshAttributeTable(); - myInspectorFrameParent->myFlowAttributesEditor->refreshAttributeTable(); - myInspectorFrameParent->myGEOAttributesEditor->refreshAttributeTable(); + myInspectorFrameParent->myAttributesEditor->refreshAttributesEditor(); + myInspectorFrameParent->myFlowAttributesEditor->refreshAttributesEditor(); + myInspectorFrameParent->myGEOAttributesEditor->refreshAttributesEditor(); } return 1; } @@ -521,7 +521,7 @@ GNEInspectorFrame::TemplateEditor::onCmdCopyTemplate(FXObject*, FXSelector, void // end copy template myInspectorFrameParent->myViewNet->getUndoList()->end(); // refresh inspector parent - myInspectorFrameParent->myAttributesEditor->refreshAttributeTable(); + myInspectorFrameParent->myAttributesEditor->refreshAttributesEditor(); } return 1; } @@ -859,10 +859,10 @@ GNEInspectorFrame::refreshInspection() { myHeaderLeftFrame->hide(); myBackButton->hide(); // Hide all elements - myAttributesEditor->hideAttributeTableModule(); - myFlowAttributesEditor->hideAttributeTableModule(); + myAttributesEditor->hideAttributesEditor(); + myFlowAttributesEditor->hideAttributesEditor(); myNeteditAttributesEditor->hideNeteditAttributesEditor(); - myGEOAttributesEditor->hideAttributeTableModule(); + myGEOAttributesEditor->hideAttributesEditor(); myParametersEditor->hideParametersEditor(); myAdditionalDialog->hideAdditionalDialog(); myTemplateEditor->hideTemplateEditor(); @@ -910,16 +910,16 @@ GNEInspectorFrame::refreshInspection() { getFrameHeaderLabel()->setText(headerString.c_str()); // Show attributes editor - myAttributesEditor->showAttributeTableModule(inspectedElements.getACs()); + myAttributesEditor->showAttributesEditor(inspectedElements.getACs()); // Show flow attributes editor - myFlowAttributesEditor->showAttributeTableModule(inspectedElements.getACs()); + myFlowAttributesEditor->showAttributesEditor(inspectedElements.getACs()); // show netedit attributes editor if we're inspecting elements with Netedit Attributes myNeteditAttributesEditor->showNeteditAttributesEditor(); // Show GEO attributes editor - myGEOAttributesEditor->showAttributeTableModule(inspectedElements.getACs()); + myGEOAttributesEditor->showAttributesEditor(inspectedElements.getACs()); // show parameters editor myParametersEditor->showParametersEditor(); @@ -1028,9 +1028,9 @@ GNEInspectorFrame::onCmdGoBack(FXObject*, FXSelector, void*) { void GNEInspectorFrame::updateFrameAfterUndoRedo() { - myAttributesEditor->refreshAttributeTable(); - myFlowAttributesEditor->refreshAttributeTable(); - myGEOAttributesEditor->refreshAttributeTable(); + myAttributesEditor->refreshAttributesEditor(); + myFlowAttributesEditor->refreshAttributesEditor(); + myGEOAttributesEditor->refreshAttributesEditor(); myParametersEditor->refreshParametersEditor(); myHierarchicalElementTree->refreshHierarchicalElementTree(); } @@ -1060,10 +1060,10 @@ GNEInspectorFrame::inspectClickedElement(const GNEViewNetHelper::ViewObjectsSele void GNEInspectorFrame::attributeUpdated(SumoXMLAttr /*attribute*/) { - myAttributesEditor->refreshAttributeTable(); - myFlowAttributesEditor->refreshAttributeTable(); + myAttributesEditor->refreshAttributesEditor(); + myFlowAttributesEditor->refreshAttributesEditor(); myNeteditAttributesEditor->refreshNeteditAttributesEditor(true); - myGEOAttributesEditor->refreshAttributeTable(); + myGEOAttributesEditor->refreshAttributesEditor(); } diff --git a/src/netedit/frames/data/GNEMeanDataFrame.cpp b/src/netedit/frames/data/GNEMeanDataFrame.cpp index 3235cfcfc3c..da9990ac37b 100644 --- a/src/netedit/frames/data/GNEMeanDataFrame.cpp +++ b/src/netedit/frames/data/GNEMeanDataFrame.cpp @@ -309,7 +309,7 @@ GNEMeanDataFrame::MeanDataSelector::showMeanDataSelector() { void GNEMeanDataFrame::MeanDataSelector::hideMeanDataSelector() { // hide attributes editor - myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributeTableModule(); + myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributesEditor(); // hide hide(); } @@ -373,9 +373,9 @@ GNEMeanDataFrame::MeanDataSelector::refreshMeanDataSelector(bool afterChangingID // check if show attribute editor if (!afterChangingID) { if (myCurrentMeanData) { - myMeanDataFrameParent->myMeanDataAttributesEditor->showAttributeTableModule(myCurrentMeanData); + myMeanDataFrameParent->myMeanDataAttributesEditor->showAttributesEditor(myCurrentMeanData); } else { - myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributeTableModule(); + myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributesEditor(); } } } @@ -403,7 +403,7 @@ GNEMeanDataFrame::MeanDataSelector::onCmdSelectItem(FXObject*, FXSelector, void* // refresh meanData editor module myMeanDataFrameParent->myMeanDataEditor->refreshMeanDataEditorModule(); // show modules if selected item is valid - myMeanDataFrameParent->myMeanDataAttributesEditor->showAttributeTableModule(myCurrentMeanData); + myMeanDataFrameParent->myMeanDataAttributesEditor->showAttributesEditor(myCurrentMeanData); // Write Warning in console if we're in testing mode WRITE_DEBUG(("Selected item '" + myMeanDataComboBox->getText() + "' in MeanDataSelector").text()); // update viewNet @@ -415,7 +415,7 @@ GNEMeanDataFrame::MeanDataSelector::onCmdSelectItem(FXObject*, FXSelector, void* // refresh meanData editor module myMeanDataFrameParent->myMeanDataEditor->refreshMeanDataEditorModule(); // hide all modules if selected item isn't valid - myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributeTableModule(); + myMeanDataFrameParent->myMeanDataAttributesEditor->hideAttributesEditor(); // set color of myMeanDataMatchBox to red (invalid) myMeanDataComboBox->setTextColor(FXRGB(255, 0, 0)); // Write Warning in console if we're in testing mode diff --git a/src/netedit/frames/demand/GNEDistributionFrame.cpp b/src/netedit/frames/demand/GNEDistributionFrame.cpp index b3b7024055c..ec5c26a726c 100644 --- a/src/netedit/frames/demand/GNEDistributionFrame.cpp +++ b/src/netedit/frames/demand/GNEDistributionFrame.cpp @@ -218,11 +218,11 @@ GNEDistributionFrame::DistributionSelector::refreshDistributionSelector() { // continue depending of myCurrentDistribution if (myCurrentDistribution) { // show modules - myAttributesEditor->showAttributeTableModule(myCurrentDistribution); + myAttributesEditor->showAttributesEditor(myCurrentDistribution); myDistributionValuesEditor->showDistributionValuesEditor(); } else { // hide modules - myAttributesEditor->hideAttributeTableModule(); + myAttributesEditor->hideAttributesEditor(); myDistributionValuesEditor->hideDistributionValuesEditor(); } } @@ -240,7 +240,7 @@ GNEDistributionFrame::DistributionSelector::onCmdSelectDistribution(FXObject*, F // set color of myTypeMatchBox to black (valid) myDistributionsComboBox->setTextColor(FXRGB(0, 0, 0)); // show modules - myAttributesEditor->showAttributeTableModule(distribution.second); + myAttributesEditor->showAttributesEditor(distribution.second); myDistributionValuesEditor->showDistributionValuesEditor(); // Write Warning in console if we're in testing mode WRITE_DEBUG(("Selected item '" + myDistributionsComboBox->getText() + "' in DistributionSelector").text()); @@ -252,7 +252,7 @@ GNEDistributionFrame::DistributionSelector::onCmdSelectDistribution(FXObject*, F // not found, then reset myCurrentDistribution myCurrentDistribution = nullptr; // hide modules - myAttributesEditor->hideAttributeTableModule(); + myAttributesEditor->hideAttributesEditor(); myDistributionValuesEditor->hideDistributionValuesEditor(); // set color of myTypeMatchBox to red (invalid) myDistributionsComboBox->setTextColor(FXRGB(255, 0, 0)); diff --git a/src/netedit/frames/demand/GNETypeFrame.cpp b/src/netedit/frames/demand/GNETypeFrame.cpp index 40e6e8a7311..c7bda8f4a10 100644 --- a/src/netedit/frames/demand/GNETypeFrame.cpp +++ b/src/netedit/frames/demand/GNETypeFrame.cpp @@ -147,7 +147,7 @@ GNETypeFrame::TypeSelector::refreshTypeSelector(const bool updateModuls) { // refresh vehicle type editor module myTypeFrameParent->myTypeEditor->refreshTypeEditorModule(); // show modules - myTypeFrameParent->myTypeAttributesEditor->showAttributeTableModule(myCurrentType); + myTypeFrameParent->myTypeAttributesEditor->showAttributesEditor(myCurrentType); myTypeFrameParent->myAttributesEditorExtended->showAttributesEditorExtendedModule(); myTypeFrameParent->myParametersEditor->refreshParametersEditor(); } @@ -166,7 +166,7 @@ GNETypeFrame::TypeSelector::onCmdSelectItem(FXObject*, FXSelector, void*) { // refresh vehicle type editor module myTypeFrameParent->myTypeEditor->refreshTypeEditorModule(); // show modules if selected item is valid - myTypeFrameParent->myTypeAttributesEditor->showAttributeTableModule(myCurrentType); + myTypeFrameParent->myTypeAttributesEditor->showAttributesEditor(myCurrentType); myTypeFrameParent->myAttributesEditorExtended->showAttributesEditorExtendedModule(); myTypeFrameParent->myParametersEditor->refreshParametersEditor(); // Write Warning in console if we're in testing mode @@ -180,7 +180,7 @@ GNETypeFrame::TypeSelector::onCmdSelectItem(FXObject*, FXSelector, void*) { // refresh vehicle type editor module myTypeFrameParent->myTypeEditor->refreshTypeEditorModule(); // hide all modules if selected item isn't valid - myTypeFrameParent->myTypeAttributesEditor->hideAttributeTableModule(); + myTypeFrameParent->myTypeAttributesEditor->hideAttributesEditor(); myTypeFrameParent->myAttributesEditorExtended->hideAttributesEditorExtendedModule(); // set color of myTypeMatchBox to red (invalid) myTypeComboBox->setTextColor(FXRGB(255, 0, 0)); @@ -415,7 +415,7 @@ GNETypeFrame::show() { // refresh vehicle type and Attribute Editor myTypeSelector->refreshTypeSelector(true); // show modules - myTypeAttributesEditor->showAttributeTableModule(myTypeSelector->getCurrentType()); + myTypeAttributesEditor->showAttributesEditor(myTypeSelector->getCurrentType()); myAttributesEditorExtended->showAttributesEditorExtendedModule(); // show frame GNEFrame::show(); @@ -443,7 +443,7 @@ GNETypeFrame::attributesEditorExtendedDialogOpened() { if (myTypeSelector->getCurrentType()) { GNEVehicleTypeDialog(myTypeSelector->getCurrentType(), true); // NOSONAR, constructor returns after dialog has been closed // call "showAttributeEditorModule" to refresh attribute list - myTypeAttributesEditor->showAttributeTableModule(myTypeSelector->getCurrentType()); + myTypeAttributesEditor->showAttributesEditor(myTypeSelector->getCurrentType()); myParametersEditor->refreshParametersEditor(); } }