64 myIntervalTable->setSelBackColor(FXRGBA(255, 255, 255, 255));
65 myIntervalTable->setSelTextColor(FXRGBA(0, 0, 0, 255));
66 myIntervalTable->setEditable(
false);
69 updateIntervalTable();
87 FXMessageBox::warning(getApp(), MBOX_OK,
"Overlapping detected",
"%s", (
"Values of '" +
myEditedAdditional->
getID() +
"' cannot be saved. There are intervals overlapped.").c_str());
93 getApp()->stopModal(
this, TRUE);
104 getApp()->stopModal(
this, FALSE);
132 std::vector<GNEAdditional*> rerouterChildren;
134 if (!rerouterChild->getTagProperty()->isSymbol()) {
135 rerouterChildren.push_back(rerouterChild);
139 for (
int i = 0; i < (int)rerouterChildren.size(); i++) {
149 for (
int i = 0; i < (int)rerouterChildren.size(); i++) {
166 std::vector<GNEAdditional*> rerouterChildren;
168 if (!rerouterChild->getTagProperty()->isSymbol()) {
169 rerouterChildren.push_back(rerouterChild);
187 FXTableItem* item =
nullptr;
189 for (
const auto& rerouterChild : rerouterChildren) {
191 item =
new FXTableItem(rerouterChild->getAttribute(
SUMO_ATTR_BEGIN).c_str());
194 item =
new FXTableItem(rerouterChild->getAttribute(
SUMO_ATTR_END).c_str());
198 item->setJustify(FXTableItem::CENTER_X | FXTableItem::CENTER_Y);
199 item->setEnabled(
false);
FXDEFMAP(GNERerouterDialog) GNERerouterDialogMap[]
@ MID_GNE_REROUTEDIALOG_ADD_INTERVAL
add interval
@ MID_GNE_REROUTEDIALOG_TABLE_INTERVAL
select table interval
@ MID_GNE_REROUTEDIALOG_SORT_INTERVAL
sort rerouter intervals
#define GUIDesignButtonIcon
button only with icon
#define GUIDesignTableAdditionals
design for tables used in additional dialogs
#define GUIDesignAuxiliarHorizontalFrame
design for auxiliar (Without borders) horizontal frame used to pack another frames
#define GUIDesignLabelThick(justify)
label extended over frame with thick and with text justify to left
@ SUMO_TAG_INTERVAL
an aggreagated-output interval
@ SUMO_ATTR_BEGIN
weights: time range begin
@ SUMO_ATTR_END
weights: time range end
int GUIDesignHeight
the default size for GUI elements
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
Dialog to edit sequences, parameters, etc.. of Additionals.
void acceptChanges()
Accept changes did in this dialog.
void cancelChanges()
Cancel changes did in this dialog.
GNEAdditional * myEditedAdditional
pointer to edited additional
void resetChanges()
reset changes did in this dialog.
const std::string getID() const
get ID (all Attribute Carriers have one)
GNENet * getNet() const
get pointer to net
const GNEHierarchicalContainerChildren< GNEAdditional * > & getChildAdditionals() const
return child additionals
bool checkChildAdditionalsOverlapping() const
check if children are overlapped (Used by Rerouters)
GNEViewNet * getViewNet() const
get view net
Dialog for edit rerouters.
~GNERerouterDialog()
destructor
long onCmdAccept(FXObject *, FXSelector, void *)
long onCmdReset(FXObject *, FXSelector, void *)
event after press reset button
long onCmdAddInterval(FXObject *, FXSelector, void *)
add new interval
long onCmdCancel(FXObject *, FXSelector, void *)
event after press cancel button
long onCmdClickedInterval(FXObject *, FXSelector, void *)
remove or edit interval
FXTable * myIntervalTable
list with intervals
void updateIntervalTable()
update data table
Dialog for edit rerouter intervals.
void add(GNEChange *command, bool doit=false, bool merge=true)
Add new command, executing it if desired. The new command will be merged with the previous command if...
GNEUndoList * getUndoList() const
get the undoList object
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 FXIcon * getIcon(const GUIIcon which)
returns a icon previously defined in the enum GUIIcon