Eclipse SUMO - Simulation of Urban MObility
GNEViewParent.cpp
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2022 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials are made available under the
5 // terms of the Eclipse Public License 2.0 which is available at
6 // https://www.eclipse.org/legal/epl-2.0/
7 // This Source Code may also be made available under the following Secondary
8 // Licenses when the conditions for such availability set forth in the Eclipse
9 // Public License 2.0 are satisfied: GNU General Public License, version 2
10 // or later which is available at
11 // https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12 // SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13 /****************************************************************************/
18 // A single child window which contains a view of the edited network (adapted
19 // from GUISUMOViewParent)
20 // While we don't actually need MDI for netedit it is easier to adapt existing
21 // structures than to write everything from scratch.
22 /****************************************************************************/
23 
50 
51 #include "GNEApplicationWindow.h"
52 #include "GNEViewNet.h"
53 #include "GNENet.h"
54 #include "GNEViewParent.h"
55 #include "GNEUndoList.h"
56 
57 
58 // ===========================================================================
59 // FOX callback mapping
60 // ===========================================================================
61 
62 FXDEFMAP(GNEViewParent) GNEViewParentMap[] = {
63  FXMAPFUNC(SEL_COMMAND, MID_MAKESNAPSHOT, GNEViewParent::onCmdMakeSnapshot),
64  FXMAPFUNC(SEL_COMMAND, MID_LOCATEJUNCTION, GNEViewParent::onCmdLocate),
65  FXMAPFUNC(SEL_COMMAND, MID_LOCATEEDGE, GNEViewParent::onCmdLocate),
66  FXMAPFUNC(SEL_COMMAND, MID_LOCATEVEHICLE, GNEViewParent::onCmdLocate),
67  FXMAPFUNC(SEL_COMMAND, MID_LOCATEPERSON, GNEViewParent::onCmdLocate),
68  FXMAPFUNC(SEL_COMMAND, MID_LOCATEROUTE, GNEViewParent::onCmdLocate),
69  FXMAPFUNC(SEL_COMMAND, MID_LOCATESTOP, GNEViewParent::onCmdLocate),
70  FXMAPFUNC(SEL_COMMAND, MID_LOCATETLS, GNEViewParent::onCmdLocate),
71  FXMAPFUNC(SEL_COMMAND, MID_LOCATEADD, GNEViewParent::onCmdLocate),
72  FXMAPFUNC(SEL_COMMAND, MID_LOCATEPOI, GNEViewParent::onCmdLocate),
73  FXMAPFUNC(SEL_COMMAND, MID_LOCATEPOLY, GNEViewParent::onCmdLocate),
74  FXMAPFUNC(SEL_COMMAND, FXMDIChild::ID_MDI_MENUCLOSE, GNEViewParent::onCmdClose),
76 };
77 
78 // Object implementation
79 FXIMPLEMENT(GNEViewParent, GUIGlChildWindow, GNEViewParentMap, ARRAYNUMBER(GNEViewParentMap))
80 
81 
82 // ===========================================================================
83 // member method definitions
84 // ===========================================================================
85 
86 GNEViewParent::GNEViewParent(FXMDIClient* p, FXMDIMenu* mdimenu, const FXString& name, GNEApplicationWindow* parentWindow,
87  FXGLCanvas* share, GNENet* net, const bool newNet, GNEUndoList* undoList, FXIcon* ic, FXuint opts, FXint x, FXint y, FXint w, FXint h) :
88  GUIGlChildWindow(p, parentWindow, mdimenu, name, parentWindow->getToolbarsGrip().navigation, ic, opts, x, y, w, h),
89  myGNEAppWindows(parentWindow) {
90  // Add child to parent
91  myParent->addGLChild(this);
92 
93  // Create Vertical separator
94  new FXVerticalSeparator(myGripNavigationToolbar, GUIDesignVerticalSeparator);
95 
96  // Create undo/redo buttons
97  myUndoButton = new FXButton(myGripNavigationToolbar, "\tUndo\tUndo the last change. (Ctrl+Z)", GUIIconSubSys::getIcon(GUIIcon::UNDO), parentWindow, MID_HOTKEY_CTRL_Z_UNDO, GUIDesignButtonToolbar);
98  myRedoButton = new FXButton(myGripNavigationToolbar, "\tRedo\tRedo the last change. (Ctrl+Y)", GUIIconSubSys::getIcon(GUIIcon::REDO), parentWindow, MID_HOTKEY_CTRL_Y_REDO, GUIDesignButtonToolbar);
99 
100  // Create Vertical separator
101  new FXVerticalSeparator(myGripNavigationToolbar, GUIDesignVerticalSeparator);
102 
103  // create compute path manager button
104  myComputePathManagerButton = new FXButton(myGripNavigationToolbar, "\tCompute path manager\tCompute path manager", GUIIconSubSys::getIcon(GUIIcon::COMPUTEPATHMANAGER), parentWindow, MID_GNE_TOOLBAREDIT_COMPUTEPATHMANAGER, GUIDesignButtonToolbar);
105 
106  // Create Frame Splitter
107  myFramesSplitter = new FXSplitter(myContentFrame, this, MID_GNE_VIEWPARENT_FRAMEAREAWIDTH, GUIDesignSplitter | SPLITTER_HORIZONTAL);
108 
109  // Create frames Area
110  myFramesArea = new FXHorizontalFrame(myFramesSplitter, GUIDesignFrameArea);
111 
112  // Set default width of frames area
113  myFramesArea->setWidth(220);
114 
115  // Create view area
116  myViewArea = new FXHorizontalFrame(myFramesSplitter, GUIDesignViewnArea);
117 
118  // Add the view to a temporary parent so that we can add items to myViewArea in the desired order
119  FXComposite* tmp = new FXComposite(this);
120 
121  // Create view net
122  GNEViewNet* viewNet = new GNEViewNet(tmp, myViewArea, *myParent, this, net, newNet, undoList, myParent->getGLVisual(), share);
123 
124  // show toolbar grips
125  myGNEAppWindows->getToolbarsGrip().buildMenuToolbarsGrip();
126 
127  // Set pointer myView with the created view net
128  myView = viewNet;
129 
130  // build frames
131  myCommonFrames.buildCommonFrames(this, viewNet);
132  myNetworkFrames.buildNetworkFrames(this, viewNet);
133  myDemandFrames.buildDemandFrames(this, viewNet);
134  myDataFrames.buildDataFrames(this, viewNet);
135 
136  // Update frame areas after creation
137  onCmdUpdateFrameAreaWidth(nullptr, 0, nullptr);
138 
139  // Hidde all Frames Area
140  hideFramesArea();
141 
142  // Build view toolBars
143  myView->buildViewToolBars(this);
144 
145  // create windows
147 }
148 
149 
151  // delete toolbar grips
153  // Remove child before remove
154  myParent->removeGLChild(this);
155 }
156 
157 
158 void
164 }
165 
166 
167 GNEFrame*
171  } else if (myNetworkFrames.isNetworkFrameShown()) {
173  } else if (myDemandFrames.isDemandFrameShown()) {
175  } else if (myDataFrames.isDataFrameShown()) {
177  } else {
178  return nullptr;
179  }
180 }
181 
182 
186 }
187 
188 
192 }
193 
194 
198 }
199 
200 
203  return myCommonFrames.moveFrame;
204 }
205 
206 
210 }
211 
212 
216 }
217 
218 
222 }
223 
224 
228 }
229 
230 
233  return myNetworkFrames.TAZFrame;
234 }
235 
236 
240 }
241 
242 
246 }
247 
248 
252 }
253 
254 
257  return myDemandFrames.routeFrame;
258 }
259 
260 
264 }
265 
266 
270 }
271 
272 
275  return myDemandFrames.stopFrame;
276 }
277 
278 
282 }
283 
284 
288 }
289 
290 
294 }
295 
296 
300 }
301 
302 
306 }
307 
308 
312 }
313 
314 
318 }
319 
320 
321 void
323  const bool frameShown = myCommonFrames.isCommonFrameShown() ||
327  // show and recalc framesArea if at least there is a frame shown
328  if (frameShown) {
329  myFramesArea->recalc();
330  myFramesArea->show();
331  }
332 }
333 
334 
335 void
337  const bool frameShown = myCommonFrames.isCommonFrameShown() ||
341  // hide and recalc frames Area if all frames are hidden is enabled
342  if (!frameShown) {
343  myFramesArea->hide();
344  myFramesArea->recalc();
345  }
346 }
347 
348 
351  return myParent;
352 }
353 
354 
357  return myGNEAppWindows;
358 }
359 
360 
361 void
363  if (chooserDialog == nullptr) {
364  throw ProcessError("ChooserDialog already deleted");
365  } else if (chooserDialog == myACChoosers.ACChooserJunction) {
367  } else if (chooserDialog == myACChoosers.ACChooserEdges) {
368  myACChoosers.ACChooserEdges = nullptr;
369  } else if (chooserDialog == myACChoosers.ACChooserVehicles) {
371  } else if (chooserDialog == myACChoosers.ACChooserPersons) {
372  myACChoosers.ACChooserPersons = nullptr;
373  } else if (chooserDialog == myACChoosers.ACChooserRoutes) {
374  myACChoosers.ACChooserRoutes = nullptr;
375  } else if (chooserDialog == myACChoosers.ACChooserStops) {
376  myACChoosers.ACChooserStops = nullptr;
377  } else if (chooserDialog == myACChoosers.ACChooserTLS) {
378  myACChoosers.ACChooserTLS = nullptr;
379  } else if (chooserDialog == myACChoosers.ACChooserAdditional) {
381  } else if (chooserDialog == myACChoosers.ACChooserPOI) {
382  myACChoosers.ACChooserPOI = nullptr;
383  } else if (chooserDialog == myACChoosers.ACChooserPolygon) {
384  myACChoosers.ACChooserPolygon = nullptr;
385  } else if (chooserDialog == myACChoosers.ACChooserProhibition) {
387  } else {
388  throw ProcessError("Unregistered chooserDialog");
389  }
390 }
391 
392 
393 void
397 }
398 
399 
400 long
401 GNEViewParent::onCmdMakeSnapshot(FXObject*, FXSelector, void*) {
402  // get the new file name
403  FXFileDialog opendialog(this, "Save Snapshot");
404  opendialog.setIcon(GUIIconSubSys::getIcon(GUIIcon::CAMERA));
405  opendialog.setSelectMode(SELECTFILE_ANY);
406  opendialog.setPatternList("All Image Files (*.gif, *.bmp, *.xpm, *.pcx, *.ico, *.rgb, *.xbm, *.tga, *.png, *.jpg, *.jpeg, *.tif, *.tiff, *.ps, *.eps, *.pdf, *.svg, *.tex, *.pgf)\n"
407  "GIF Image (*.gif)\nBMP Image (*.bmp)\nXPM Image (*.xpm)\nPCX Image (*.pcx)\nICO Image (*.ico)\n"
408  "RGB Image (*.rgb)\nXBM Image (*.xbm)\nTARGA Image (*.tga)\nPNG Image (*.png)\n"
409  "JPEG Image (*.jpg, *.jpeg)\nTIFF Image (*.tif, *.tiff)\n"
410  "Postscript (*.ps)\nEncapsulated Postscript (*.eps)\nPortable Document Format (*.pdf)\n"
411  "Scalable Vector Graphics (*.svg)\nLATEX text strings (*.tex)\nPortable LaTeX Graphics (*.pgf)\n"
412  "All Files (*)");
413  if (gCurrentFolder.length() != 0) {
414  opendialog.setDirectory(gCurrentFolder);
415  }
416  if (!opendialog.execute() || !MFXUtils::userPermitsOverwritingWhenFileExists(this, opendialog.getFilename())) {
417  return 1;
418  }
419  gCurrentFolder = opendialog.getDirectory();
420  std::string file = opendialog.getFilename().text();
421  if (file.find(".") == std::string::npos) {
422  file.append(".png");
423  WRITE_MESSAGE("No file extension was specified - saving Snapshot as PNG.");
424  }
425  std::string error = myView->makeSnapshot(file);
426  if (error != "") {
427  // write warning if netedit is running in testing mode
428  WRITE_DEBUG("Opening FXMessageBox 'error saving snapshot'");
429  // open message box
430  FXMessageBox::error(this, MBOX_OK, "Saving failed.", "%s", error.c_str());
431  // write warning if netedit is running in testing mode
432  WRITE_DEBUG("Closed FXMessageBox 'error saving snapshot' with 'OK'");
433  }
434  return 1;
435 }
436 
437 
438 long
439 GNEViewParent::onCmdClose(FXObject*, FXSelector /* sel */, void*) {
440  myParent->handle(this, FXSEL(SEL_COMMAND, MID_HOTKEY_CTRL_W_CLOSESIMULATION), nullptr);
441  return 1;
442 }
443 
444 std::vector<GUIGlID>
445 GNEViewParent::getObjectIDs(int messageId) const {
446  UNUSED_PARAMETER(messageId);
447  std::vector<GUIGlID> result;
448  return result;
449 }
450 
451 long
452 GNEViewParent::onCmdLocate(FXObject*, FXSelector sel, void*) {
453  GNEViewNet* viewNet = dynamic_cast<GNEViewNet*>(myView);
454  // check that viewNet exist
455  if (viewNet) {
456  // declare a vector in which save attribute carriers to locate
457  std::vector<GNEAttributeCarrier*> ACsToLocate;
458  int messageId = FXSELID(sel);
459  switch (messageId) {
460  case MID_LOCATEJUNCTION: {
462  // restore focus in the existent chooser dialog
463  myACChoosers.ACChooserJunction->restore();
464  myACChoosers.ACChooserJunction->setFocus();
465  } else {
466  // fill ACsToLocate with junctions
467  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getJunctions().size());
468  for (const auto& junction : viewNet->getNet()->getAttributeCarriers()->getJunctions()) {
469  ACsToLocate.push_back(junction.second);
470  }
471  myACChoosers.ACChooserJunction = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEJUNCTION), "Junction Chooser", ACsToLocate);
472  }
473  break;
474  }
475  case MID_LOCATEEDGE: {
477  // restore focus in the existent chooser dialog
478  myACChoosers.ACChooserEdges->restore();
479  myACChoosers.ACChooserEdges->setFocus();
480  } else {
481  // fill ACsToLocate with edges
482  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getEdges().size());
483  for (const auto& edge : viewNet->getNet()->getAttributeCarriers()->getEdges()) {
484  ACsToLocate.push_back(edge.second);
485  }
486  myACChoosers.ACChooserEdges = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEEDGE), "Edge Chooser", ACsToLocate);
487  }
488  break;
489  }
490  case MID_LOCATEVEHICLE: {
492  // restore focus in the existent chooser dialog
493  myACChoosers.ACChooserVehicles->restore();
494  myACChoosers.ACChooserVehicles->setFocus();
495  } else {
496  // reserve memory
497  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_VEHICLE).size() +
498  viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_TRIP).size() +
500  viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_FLOW).size());
501  // fill ACsToLocate with vehicles
502  for (const auto& vehicle : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_VEHICLE)) {
503  ACsToLocate.push_back(vehicle);
504  }
505  // fill ACsToLocate with vehicles
506  for (const auto& trip : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_TRIP)) {
507  ACsToLocate.push_back(trip);
508  }
509  // fill ACsToLocate with routeFlows
510  for (const auto& flowRoute : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(GNE_TAG_FLOW_ROUTE)) {
511  ACsToLocate.push_back(flowRoute);
512  }
513  // fill ACsToLocate with routeFlowsFromTo
514  for (const auto& flow : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_FLOW)) {
515  ACsToLocate.push_back(flow);
516  }
517  myACChoosers.ACChooserVehicles = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEVEHICLE), "Vehicle Chooser", ACsToLocate);
518  }
519  break;
520  }
521  case MID_LOCATEPERSON: {
523  // restore focus in the existent chooser dialog
524  myACChoosers.ACChooserPersons->restore();
525  myACChoosers.ACChooserPersons->setFocus();
526  } else {
527  // reserve memory
528  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_PERSON).size() +
530  // fill ACsToLocate with persons
531  for (const auto& person : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_PERSON)) {
532  ACsToLocate.push_back(person);
533  }
534  // fill ACsToLocate with personFlows
535  for (const auto& personFlow : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_PERSONFLOW)) {
536  ACsToLocate.push_back(personFlow);
537  }
538  myACChoosers.ACChooserPersons = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEPERSON), "Person Chooser", ACsToLocate);
539  }
540  break;
541  }
542  case MID_LOCATEROUTE: {
544  // restore focus in the existent chooser dialog
545  myACChoosers.ACChooserRoutes->restore();
546  myACChoosers.ACChooserRoutes->setFocus();
547  } else {
548  // reserve memory
549  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_ROUTE).size());
550  // fill ACsToLocate with routes
551  for (const auto& route : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_ROUTE)) {
552  ACsToLocate.push_back(route);
553  }
554  myACChoosers.ACChooserRoutes = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEROUTE), "Route Chooser", ACsToLocate);
555  }
556  break;
557  }
558  case MID_LOCATESTOP: {
560  // restore focus in the existent chooser dialog
561  myACChoosers.ACChooserStops->restore();
562  myACChoosers.ACChooserStops->setFocus();
563  } else {
564  // reserve memory
565  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_LANE).size() +
570  // fill ACsToLocate with stop over lanes
571  for (const auto& stopLane : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_LANE)) {
572  ACsToLocate.push_back(stopLane);
573  }
574  // fill ACsToLocate with stop over busstops
575  for (const auto& stopBusStop : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_BUSSTOP)) {
576  ACsToLocate.push_back(stopBusStop);
577  }
578  // fill ACsToLocate with stop over container stops
579  for (const auto& stopContainerStop : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_CONTAINERSTOP)) {
580  ACsToLocate.push_back(stopContainerStop);
581  }
582  // fill ACsToLocate with stop over charging stations
583  for (const auto& stopChargingStation : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_CHARGINGSTATION)) {
584  ACsToLocate.push_back(stopChargingStation);
585  }
586  // fill ACsToLocate with stop over parking areas
587  for (const auto& stopParkingArea : viewNet->getNet()->getAttributeCarriers()->getDemandElements().at(SUMO_TAG_STOP_PARKINGAREA)) {
588  ACsToLocate.push_back(stopParkingArea);
589  }
590  myACChoosers.ACChooserStops = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATESTOP), "Stop Chooser", ACsToLocate);
591  }
592  break;
593  }
594  case MID_LOCATETLS: {
596  // restore focus in the existent chooser dialog
597  myACChoosers.ACChooserTLS->restore();
598  myACChoosers.ACChooserTLS->setFocus();
599  } else {
600  // fill ACsToLocate with junctions that haven TLS
601  ACsToLocate.reserve(viewNet->getNet()->getAttributeCarriers()->getJunctions().size());
602  for (const auto& junction : viewNet->getNet()->getAttributeCarriers()->getJunctions()) {
603  if (junction.second->getNBNode()->getControllingTLS().size() > 0) {
604  ACsToLocate.push_back(junction.second);
605  }
606  }
607  myACChoosers.ACChooserTLS = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATETLS), "TLS Chooser", ACsToLocate);
608  }
609  break;
610  }
611  case MID_LOCATEADD: {
613  // restore focus in the existent chooser dialog
615  myACChoosers.ACChooserAdditional->setFocus();
616  } else {
617  // fill ACsToLocate with additionals
618  for (const auto& additionalTag : viewNet->getNet()->getAttributeCarriers()->getAdditionals()) {
619  for (const auto& additional : additionalTag.second) {
620  ACsToLocate.push_back(additional);
621  }
622  }
623  myACChoosers.ACChooserAdditional = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEADD), "Additional Chooser", ACsToLocate);
624  }
625  break;
626  }
627  case MID_LOCATEPOI: {
629  // restore focus in the existent chooser dialog
630  myACChoosers.ACChooserPOI->restore();
631  myACChoosers.ACChooserPOI->setFocus();
632  } else {
633  // fill ACsToLocate with POIs
634  for (const auto& POI : viewNet->getNet()->getAttributeCarriers()->getShapes().at(SUMO_TAG_POI)) {
635  ACsToLocate.push_back(POI);
636  }
637  myACChoosers.ACChooserPOI = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEPOI), "POI Chooser", ACsToLocate);
638  }
639  break;
640  }
641  case MID_LOCATEPOLY: {
643  // restore focus in the existent chooser dialog
644  myACChoosers.ACChooserPolygon->restore();
645  myACChoosers.ACChooserPolygon->setFocus();
646  } else {
647  // fill ACsToLocate with polys and TAZs (because share namespae)
648  for (const auto& polygon : viewNet->getNet()->getAttributeCarriers()->getShapes().at(SUMO_TAG_POLY)) {
649  ACsToLocate.push_back(polygon);
650  }
651  for (const auto& taz : viewNet->getNet()->getAttributeCarriers()->getTAZElements().at(SUMO_TAG_TAZ)) {
652  ACsToLocate.push_back(taz);
653  }
654  myACChoosers.ACChooserPolygon = new GNEDialogACChooser(this, messageId, GUIIconSubSys::getIcon(GUIIcon::LOCATEPOLY), "Poly Chooser", ACsToLocate);
655  }
656  break;
657  }
658  default:
659  throw ProcessError("Unknown Message ID in onCmdLocate");
660  }
661  // update locator popup
662  myLocatorPopup->popdown();
663  myLocatorButton->killFocus();
664  myLocatorPopup->update();
665  }
666  return 1;
667 }
668 
669 
670 long
671 GNEViewParent::onKeyPress(FXObject* o, FXSelector sel, void* eventData) {
672  myView->onKeyPress(o, sel, eventData);
673  return 0;
674 }
675 
676 
677 long
678 GNEViewParent::onKeyRelease(FXObject* o, FXSelector sel, void* eventData) {
679  myView->onKeyRelease(o, sel, eventData);
680  return 0;
681 }
682 
683 
684 long
685 GNEViewParent::onCmdUpdateFrameAreaWidth(FXObject*, FXSelector, void*) {
686  const int framesAreaWidth = myFramesArea->getWidth();
687  // set width of FramesArea in all frames
688  myCommonFrames.setCommonFramesWidth(framesAreaWidth);
689  myNetworkFrames.setNetworkFramesWidth(framesAreaWidth);
690  myDemandFrames.setDemandFramesWidth(framesAreaWidth);
691  myDataFrames.setDataFramesWidth(framesAreaWidth);
692  return 0;
693 }
694 
695 // ---------------------------------------------------------------------------
696 // GNEViewParent::CommonFrames - methods
697 // ---------------------------------------------------------------------------
698 
700  inspectorFrame(nullptr),
701  deleteFrame(nullptr),
702  selectorFrame(nullptr),
703  moveFrame(nullptr) {
704 }
705 
706 
707 void
709  inspectorFrame = new GNEInspectorFrame(viewParent->myFramesArea, viewNet);
710  selectorFrame = new GNESelectorFrame(viewParent->myFramesArea, viewNet);
711  moveFrame = new GNEMoveFrame(viewParent->myFramesArea, viewNet);
712  deleteFrame = new GNEDeleteFrame(viewParent->myFramesArea, viewNet);
713 }
714 
715 
716 void
718  inspectorFrame->hide();
719  deleteFrame->hide();
720  selectorFrame->hide();
721  moveFrame->hide();
722 }
723 
724 
725 void
727  // set width in all frames
728  inspectorFrame->setFrameWidth(frameWidth);
729  deleteFrame->setFrameWidth(frameWidth);
730  selectorFrame->setFrameWidth(frameWidth);
731  moveFrame->setFrameWidth(frameWidth);
732 }
733 
734 
735 bool
737  // check all frames
738  if (inspectorFrame->shown()) {
739  return true;
740  } else if (deleteFrame->shown()) {
741  return true;
742  } else if (selectorFrame->shown()) {
743  return true;
744  } else if (moveFrame->shown()) {
745  return true;
746  } else {
747  return false;
748  }
749 }
750 
751 
752 GNEFrame*
754  // check all frames
755  if (inspectorFrame->shown()) {
756  return inspectorFrame;
757  } else if (deleteFrame->shown()) {
758  return deleteFrame;
759  } else if (selectorFrame->shown()) {
760  return selectorFrame;
761  } else if (moveFrame->shown()) {
762  return moveFrame;
763  } else {
764  return nullptr;
765  }
766 }
767 
768 // ---------------------------------------------------------------------------
769 // GNEViewParent::NetworkFrames - methods
770 // ---------------------------------------------------------------------------
771 
773  connectorFrame(nullptr),
774  TLSEditorFrame(nullptr),
775  additionalFrame(nullptr),
776  crossingFrame(nullptr),
777  TAZFrame(nullptr),
778  polygonFrame(nullptr),
779  prohibitionFrame(nullptr),
780  createEdgeFrame(nullptr) {
781 }
782 
783 
784 void
786  connectorFrame = new GNEConnectorFrame(viewParent->myFramesArea, viewNet);
787  prohibitionFrame = new GNEProhibitionFrame(viewParent->myFramesArea, viewNet);
788  TLSEditorFrame = new GNETLSEditorFrame(viewParent->myFramesArea, viewNet);
789  additionalFrame = new GNEAdditionalFrame(viewParent->myFramesArea, viewNet);
790  crossingFrame = new GNECrossingFrame(viewParent->myFramesArea, viewNet);
791  TAZFrame = new GNETAZFrame(viewParent->myFramesArea, viewNet);
792  polygonFrame = new GNEPolygonFrame(viewParent->myFramesArea, viewNet);
793  createEdgeFrame = new GNECreateEdgeFrame(viewParent->myFramesArea, viewNet);
794 }
795 
796 
797 void
799  connectorFrame->hide();
800  TLSEditorFrame->hide();
801  additionalFrame->hide();
802  crossingFrame->hide();
803  TAZFrame->hide();
804  polygonFrame->hide();
805  prohibitionFrame->hide();
806  createEdgeFrame->hide();
807 }
808 
809 
810 void
812  // set width in all frames
813  connectorFrame->setFrameWidth(frameWidth);
814  TLSEditorFrame->setFrameWidth(frameWidth);
815  additionalFrame->setFrameWidth(frameWidth);
816  crossingFrame->setFrameWidth(frameWidth);
817  TAZFrame->setFrameWidth(frameWidth);
818  polygonFrame->setFrameWidth(frameWidth);
819  prohibitionFrame->setFrameWidth(frameWidth);
820  createEdgeFrame->setFrameWidth(frameWidth);
821 }
822 
823 
824 bool
826  // check all frames
827  if (connectorFrame->shown()) {
828  return true;
829  } else if (TLSEditorFrame->shown()) {
830  return true;
831  } else if (additionalFrame->shown()) {
832  return true;
833  } else if (crossingFrame->shown()) {
834  return true;
835  } else if (TAZFrame->shown()) {
836  return true;
837  } else if (polygonFrame->shown()) {
838  return true;
839  } else if (prohibitionFrame->shown()) {
840  return true;
841  } else if (createEdgeFrame->shown()) {
842  return true;
843  } else {
844  return false;
845  }
846 }
847 
848 
849 GNEFrame*
851  // check all frames
852  if (connectorFrame->shown()) {
853  return connectorFrame;
854  } else if (TLSEditorFrame->shown()) {
855  return TLSEditorFrame;
856  } else if (additionalFrame->shown()) {
857  return additionalFrame;
858  } else if (crossingFrame->shown()) {
859  return crossingFrame;
860  } else if (TAZFrame->shown()) {
861  return TAZFrame;
862  } else if (polygonFrame->shown()) {
863  return polygonFrame;
864  } else if (prohibitionFrame->shown()) {
865  return prohibitionFrame;
866  } else if (createEdgeFrame->shown()) {
867  return createEdgeFrame;
868  } else {
869  return nullptr;
870  }
871 }
872 
873 // ---------------------------------------------------------------------------
874 // GNEViewParent::DemandFrames - methods
875 // ---------------------------------------------------------------------------
876 
878  routeFrame(nullptr),
879  vehicleFrame(nullptr),
880  vehicleTypeFrame(nullptr),
881  stopFrame(nullptr),
882  personFrame(nullptr),
883  personPlanFrame(nullptr),
884  containerFrame(nullptr),
885  containerPlanFrame(nullptr) {
886 }
887 
888 
889 void
891  routeFrame = new GNERouteFrame(viewParent->myFramesArea, viewNet);
892  vehicleFrame = new GNEVehicleFrame(viewParent->myFramesArea, viewNet);
893  vehicleTypeFrame = new GNETypeFrame(viewParent->myFramesArea, viewNet);
894  stopFrame = new GNEStopFrame(viewParent->myFramesArea, viewNet);
895  personFrame = new GNEPersonFrame(viewParent->myFramesArea, viewNet);
896  personPlanFrame = new GNEPersonPlanFrame(viewParent->myFramesArea, viewNet);
897  containerFrame = new GNEContainerFrame(viewParent->myFramesArea, viewNet);
898  containerPlanFrame = new GNEContainerPlanFrame(viewParent->myFramesArea, viewNet);
899 }
900 
901 
902 void
904  routeFrame->hide();
905  vehicleFrame->hide();
906  vehicleTypeFrame->hide();
907  stopFrame->hide();
908  personFrame->hide();
909  personPlanFrame->hide();
910  containerFrame->hide();
911  containerPlanFrame->hide();
912 }
913 
914 
915 void
917  // set width in all frames
918  routeFrame->setFrameWidth(frameWidth);
919  vehicleFrame->setFrameWidth(frameWidth);
920  vehicleTypeFrame->setFrameWidth(frameWidth);
921  stopFrame->setFrameWidth(frameWidth);
922  personFrame->setFrameWidth(frameWidth);
923  personPlanFrame->setFrameWidth(frameWidth);
924  containerFrame->setFrameWidth(frameWidth);
925  containerPlanFrame->setFrameWidth(frameWidth);
926 }
927 
928 
929 bool
931  // check all frames
932  if (routeFrame->shown()) {
933  return true;
934  } else if (vehicleFrame->shown()) {
935  return true;
936  } else if (vehicleTypeFrame->shown()) {
937  return true;
938  } else if (stopFrame->shown()) {
939  return true;
940  } else if (personFrame->shown()) {
941  return true;
942  } else if (personPlanFrame->shown()) {
943  return true;
944  } else if (containerFrame->shown()) {
945  return true;
946  } else if (containerPlanFrame->shown()) {
947  return true;
948  } else {
949  return false;
950  }
951 }
952 
953 
954 GNEFrame*
956  // check all frames
957  if (routeFrame->shown()) {
958  return routeFrame;
959  } else if (vehicleFrame->shown()) {
960  return vehicleFrame;
961  } else if (vehicleTypeFrame->shown()) {
962  return vehicleTypeFrame;
963  } else if (stopFrame->shown()) {
964  return stopFrame;
965  } else if (personFrame->shown()) {
966  return personFrame;
967  } else if (personPlanFrame->shown()) {
968  return personPlanFrame;
969  } else if (containerFrame->shown()) {
970  return containerFrame;
971  } else if (containerPlanFrame->shown()) {
972  return containerPlanFrame;
973  } else {
974  return nullptr;
975  }
976 }
977 
978 // ---------------------------------------------------------------------------
979 // GNEViewParent::DataFrames - methods
980 // ---------------------------------------------------------------------------
981 
983  edgeDataFrame(nullptr),
984  edgeRelDataFrame(nullptr),
985  TAZRelDataFrame(nullptr) {
986 }
987 
988 
989 void
991  edgeDataFrame = new GNEEdgeDataFrame(viewParent->myFramesArea, viewNet);
992  edgeRelDataFrame = new GNEEdgeRelDataFrame(viewParent->myFramesArea, viewNet);
993  TAZRelDataFrame = new GNETAZRelDataFrame(viewParent->myFramesArea, viewNet);
994 }
995 
996 
997 void
999  edgeDataFrame->hide();
1000  edgeRelDataFrame->hide();
1001  TAZRelDataFrame->hide();
1002 }
1003 
1004 
1005 void
1007  // set width in all frames
1008  edgeDataFrame->setFrameWidth(frameWidth);
1009  edgeRelDataFrame->setFrameWidth(frameWidth);
1010  TAZRelDataFrame->setFrameWidth(frameWidth);
1011 }
1012 
1013 
1014 bool
1016  // check all frames
1017  if (edgeDataFrame->shown()) {
1018  return true;
1019  } else if (edgeRelDataFrame->shown()) {
1020  return true;
1021  } else if (TAZRelDataFrame->shown()) {
1022  return true;
1023  } else {
1024  return false;
1025  }
1026 }
1027 
1028 
1029 GNEFrame*
1031  // check all frames
1032  if (edgeDataFrame->shown()) {
1033  return edgeDataFrame;
1034  } else if (edgeRelDataFrame->shown()) {
1035  return edgeRelDataFrame;
1036  } else if (TAZRelDataFrame->shown()) {
1037  return TAZRelDataFrame;
1038  } else {
1039  return nullptr;
1040  }
1041 }
1042 
1043 // ---------------------------------------------------------------------------
1044 // GNEViewParent::ACChoosers - methods
1045 // ---------------------------------------------------------------------------
1046 
1048  ACChooserJunction(nullptr),
1049  ACChooserEdges(nullptr),
1050  ACChooserVehicles(nullptr),
1051  ACChooserPersons(nullptr),
1052  ACChooserRoutes(nullptr),
1053  ACChooserStops(nullptr),
1054  ACChooserTLS(nullptr),
1055  ACChooserAdditional(nullptr),
1056  ACChooserPOI(nullptr),
1057  ACChooserPolygon(nullptr),
1058  ACChooserProhibition(nullptr) {
1059 }
1060 
1061 
1063  // remove all dialogs if are active
1064  if (ACChooserJunction) {
1065  delete ACChooserJunction;
1066  }
1067  if (ACChooserEdges) {
1068  delete ACChooserEdges;
1069  }
1070  if (ACChooserRoutes) {
1071  delete ACChooserRoutes;
1072  }
1073  if (ACChooserStops) {
1074  delete ACChooserStops;
1075  }
1076  if (ACChooserVehicles) {
1077  delete ACChooserVehicles;
1078  }
1079  if (ACChooserPersons) {
1080  delete ACChooserPersons;
1081  }
1082  if (ACChooserTLS) {
1083  delete ACChooserTLS;
1084  }
1085  if (ACChooserAdditional) {
1086  delete ACChooserAdditional;
1087  }
1088  if (ACChooserPOI) {
1089  delete ACChooserPOI;
1090  }
1091  if (ACChooserPolygon) {
1092  delete ACChooserPolygon;
1093  }
1094  if (ACChooserProhibition) {
1095  delete ACChooserProhibition;
1096  }
1097 }
1098 
1099 
1100 /****************************************************************************/
FXDEFMAP(GNEViewParent) GNEViewParentMap[]
@ MID_MAKESNAPSHOT
Make snapshot - button.
Definition: GUIAppEnum.h:373
@ MID_LOCATEPERSON
Locate person - button.
Definition: GUIAppEnum.h:359
@ MID_HOTKEY_CTRL_Y_REDO
Undo.
Definition: GUIAppEnum.h:117
@ MID_LOCATEJUNCTION
Locate junction - button.
Definition: GUIAppEnum.h:349
@ MID_HOTKEY_CTRL_W_CLOSESIMULATION
Close simulation - ID.
Definition: GUIAppEnum.h:113
@ MID_LOCATEPOLY
Locate polygons - button.
Definition: GUIAppEnum.h:369
@ MID_LOCATEADD
Locate addtional structure - button.
Definition: GUIAppEnum.h:365
@ MID_LOCATEPOI
Locate poi - button.
Definition: GUIAppEnum.h:367
@ MID_LOCATESTOP
Locate stop - button.
Definition: GUIAppEnum.h:357
@ MID_GNE_VIEWPARENT_FRAMEAREAWIDTH
Size of frame area updated.
Definition: GUIAppEnum.h:674
@ MID_LOCATEEDGE
Locate edge - button.
Definition: GUIAppEnum.h:351
@ MID_LOCATEVEHICLE
Locate vehicle - button.
Definition: GUIAppEnum.h:353
@ MID_LOCATETLS
Locate TLS - button.
Definition: GUIAppEnum.h:363
@ MID_HOTKEY_CTRL_Z_UNDO
Redo.
Definition: GUIAppEnum.h:119
@ MID_LOCATEROUTE
Locate route - button.
Definition: GUIAppEnum.h:355
@ MID_GNE_TOOLBAREDIT_COMPUTEPATHMANAGER
compute path manager
Definition: GUIAppEnum.h:666
#define GUIDesignButtonToolbar
little button with icon placed in navigation toolbar
Definition: GUIDesigns.h:100
#define GUIDesignFrameArea
Definition: GUIDesigns.h:331
#define GUIDesignVerticalSeparator
vertical separator
Definition: GUIDesigns.h:398
#define GUIDesignSplitter
Definition: GUIDesigns.h:406
#define GUIDesignViewnArea
design for viewn area
Definition: GUIDesigns.h:334
FXString gCurrentFolder
The folder used as last.
@ COMPUTEPATHMANAGER
@ LOCATEVEHICLE
@ LOCATEPERSON
@ LOCATEJUNCTION
#define WRITE_DEBUG(msg)
Definition: MsgHandler.h:290
#define WRITE_MESSAGE(msg)
Definition: MsgHandler.h:282
@ SUMO_TAG_STOP_CONTAINERSTOP
stop placed over a containerStop (used in netedit)
@ SUMO_TAG_TAZ
a traffic assignment zone
@ SUMO_TAG_STOP_CHARGINGSTATION
stop placed over a charging station (used in netedit)
@ SUMO_TAG_STOP_LANE
stop placed over a lane (used in netedit)
@ SUMO_TAG_POI
begin/end of the description of a Point of interest
@ SUMO_TAG_VEHICLE
description of a vehicle
@ GNE_TAG_FLOW_ROUTE
a flow definition using a route instead of a from-to edges route (used in NETEDIT)
@ SUMO_TAG_FLOW
a flow definitio nusing a from-to edges instead of a route (used by router)
@ SUMO_TAG_ROUTE
begin/end of the description of a route
@ SUMO_TAG_POLY
begin/end of the description of a polygon
@ SUMO_TAG_STOP_BUSSTOP
stop placed over a busStop (used in netedit)
@ SUMO_TAG_PERSON
@ SUMO_TAG_STOP_PARKINGAREA
stop placed over a parking area (used in netedit)
@ SUMO_TAG_PERSONFLOW
@ SUMO_TAG_TRIP
a single trip definition (used by router)
#define UNUSED_PARAMETER(x)
Definition: StdDefs.h:30
The main window of the Netedit.
GNEUndoList * getUndoList()
get pointer to undoList
GNEApplicationWindowHelper::ToolbarsGrip & getToolbarsGrip()
get ToolbarsGrip
const std::map< SumoXMLTag, std::set< GNEDemandElement * > > & getDemandElements() const
get demand elements
const std::map< std::string, GNEEdge * > & getEdges() const
map with the ID and pointer to edges of net
const std::map< SumoXMLTag, std::set< GNETAZElement * > > & getTAZElements() const
get TAZElements
const std::map< SumoXMLTag, std::set< GNEShape * > > & getShapes() const
get shapes
const std::map< SumoXMLTag, std::set< GNEAdditional * > > & getAdditionals() const
get additionals
const std::map< std::string, GNEJunction * > & getJunctions() const
get junctions
A NBNetBuilder extended by visualisation and editing capabilities.
Definition: GNENet.h:42
GNENetHelper::AttributeCarriers * getAttributeCarriers() const
get all attribute carriers used in this net
Definition: GNENet.cpp:125
long onUpdUndo(FXObject *, FXSelector, void *)
event after Undo
long onUpdRedo(FXObject *, FXSelector, void *)
event after Redo
GNENet * getNet() const
get the net object
GNEDialogACChooser * ACChooserStops
pointer to ACChooser dialog used for locate stops
GNEDialogACChooser * ACChooserEdges
pointer to ACChooser dialog used for locate edges
GNEDialogACChooser * ACChooserPolygon
pointer to ACChooser dialog used for locate Polygons
GNEDialogACChooser * ACChooserPOI
pointer to ACChooser dialog used for locate POIs
GNEDialogACChooser * ACChooserRoutes
pointer to ACChooser dialog used for locate routes
GNEDialogACChooser * ACChooserJunction
pointer to ACChooser dialog used for locate junctions
GNEDialogACChooser * ACChooserVehicles
pointer to ACChooser dialog used for locate vehicles
GNEDialogACChooser * ACChooserTLS
pointer to ACChooser dialog used for locate TLSs
GNEDialogACChooser * ACChooserProhibition
pointer to ACChooser dialog used for locate Prohibitions
GNEDialogACChooser * ACChooserPersons
pointer to ACChooser dialog used for locate persons
GNEDialogACChooser * ACChooserAdditional
pointer to ACChooser dialog used for locate additional
GNEMoveFrame * moveFrame
frame for move elements
GNEFrame * getCurrentShownFrame() const
get current common frame show
bool isCommonFrameShown() const
return true if at least there is a common frame shown
GNEDeleteFrame * deleteFrame
frame for delete elemetns
void buildCommonFrames(GNEViewParent *viewParent, GNEViewNet *viewNet)
build common frames
GNESelectorFrame * selectorFrame
frame for select elements
void hideCommonFrames()
hide common frames
GNEInspectorFrame * inspectorFrame
frame for inspect elements
void setCommonFramesWidth(int frameWidth)
set new width in all common frames
GNEEdgeDataFrame * edgeDataFrame
frame for DATA_EDGEDATA
void setDataFramesWidth(int frameWidth)
set new width in all data frames
GNEFrame * getCurrentShownFrame() const
get current data frame show
GNETAZRelDataFrame * TAZRelDataFrame
frame for DATA_TAZRELDATA
GNEEdgeRelDataFrame * edgeRelDataFrame
frame for DATA_EDGERELDATA
bool isDataFrameShown() const
return true if at least there is a data frame shown
void hideDataFrames()
hide data frames
void buildDataFrames(GNEViewParent *viewParent, GNEViewNet *viewNet)
build data frames
GNEPersonFrame * personFrame
frame for DEMAND_PERSON
GNEStopFrame * stopFrame
frame for DEMAND_STOP
GNERouteFrame * routeFrame
frame for DEMAND_ROUTE
GNEContainerFrame * containerFrame
frame for DEMAND_CONTAINER
GNEContainerPlanFrame * containerPlanFrame
frame for DEMAND_CONTAINERPLAN
GNEVehicleFrame * vehicleFrame
frame for DEMAND_VEHICLE
GNEFrame * getCurrentShownFrame() const
get current demand frame show
void setDemandFramesWidth(int frameWidth)
set new width in all demand frames
void buildDemandFrames(GNEViewParent *viewParent, GNEViewNet *viewNet)
build demand frames
GNEPersonPlanFrame * personPlanFrame
frame for DEMAND_PERSONPLAN
bool isDemandFrameShown() const
return true if at least there is a demand frame shown
GNETypeFrame * vehicleTypeFrame
frame for DEMAND_VEHICLETYPE
void hideDemandFrames()
hide demand frames
GNEAdditionalFrame * additionalFrame
frame for NETWORK_ADDITIONAL
bool isNetworkFrameShown() const
return true if at least there is a network frame shown
GNEPolygonFrame * polygonFrame
frame for NETWORK_POLYGON
GNECrossingFrame * crossingFrame
frame for NETWORK_CROSSING
GNEConnectorFrame * connectorFrame
frame for NETWORK_CONNECT
GNECreateEdgeFrame * createEdgeFrame
frame for NETWORK_CREATEDGE
GNEProhibitionFrame * prohibitionFrame
frame for NETWORK_PROHIBITION
GNETAZFrame * TAZFrame
frame for NETWORK_TAZ
GNETLSEditorFrame * TLSEditorFrame
frame for NETWORK_TLS
GNEFrame * getCurrentShownFrame() const
get current network frame show
void hideNetworkFrames()
hide network frames
void setNetworkFramesWidth(int frameWidth)
set new width in all network frames
void buildNetworkFrames(GNEViewParent *viewParent, GNEViewNet *viewNet)
build network frames
A single child window which contains a view of the simulation area.
Definition: GNEViewParent.h:82
long onCmdMakeSnapshot(FXObject *sender, FXSelector, void *)
GNECrossingFrame * getCrossingFrame() const
get frame for NETWORK_CROSSING
GUIMainWindow * getGUIMainWindow() const
get GUIMainWindow App
GNEConnectorFrame * getConnectorFrame() const
get frame for NETWORK_CONNECT
GNEStopFrame * getStopFrame() const
get frame for DEMAND_STOP
void updateUndoRedoButtons()
update toolbar undo/redo buttons (called when user press Ctrl+Z/Y)
long onCmdUpdateFrameAreaWidth(FXObject *, FXSelector, void *)
Called when user change the splitter between FrameArea and ViewNet.
GNEProhibitionFrame * getProhibitionFrame() const
get frame for NETWORK_PROHIBITION
long onKeyPress(FXObject *o, FXSelector sel, void *data)
Called when user press a key.
GNEPersonPlanFrame * getPersonPlanFrame() const
get frame for DEMAND_PERSONFRAME
DemandFrames myDemandFrames
struct for demand frames
GNEPolygonFrame * getPolygonFrame() const
get frame for NETWORK_POLYGON
GNETAZRelDataFrame * getTAZRelDataFrame() const
get frame for DATA_TAZRELDATA
GNEMoveFrame * getMoveFrame() const
get frame for move elements
long onCmdClose(FXObject *, FXSelector, void *)
Called when the user hits the close button (x)
GNESelectorFrame * getSelectorFrame() const
get frame for select elements
GNEContainerPlanFrame * getContainerPlanFrame() const
get frame for DEMAND_CONTAINERFRAME
void hideFramesArea()
hide frames area if all GNEFrames are hidden
FXButton * myRedoButton
toolbar redo button
GNEEdgeDataFrame * getEdgeDataFrame() const
get frame for DATA_EDGEDATA
GNEDeleteFrame * getDeleteFrame() const
get frame for delete elements
NetworkFrames myNetworkFrames
struct for network frames
ACChoosers myACChoosers
struct for ACChoosers
GNEVehicleFrame * getVehicleFrame() const
get frame for DEMAND_VEHICLE
void showFramesArea()
show frames area if at least a GNEFrame is showed
FXButton * myUndoButton
toolbar undo button
void hideAllFrames()
hide all frames
GNETypeFrame * getTypeFrame() const
get frame for DEMAND_VEHICLETYPE
GNETAZFrame * getTAZFrame() const
get frame for NETWORK_TAZ
GNETLSEditorFrame * getTLSEditorFrame() const
get frame for NETWORK_TLS
CommonFrames myCommonFrames
struct for common frames
GNEApplicationWindow * getGNEAppWindows() const
get GNE Application Windows
DataFrames myDataFrames
struct for data frames
GNEContainerFrame * getContainerFrame() const
get frame for DEMAND_CONTAINER
GNEAdditionalFrame * getAdditionalFrame() const
get frame for NETWORK_ADDITIONAL
FXHorizontalFrame * myFramesArea
frame to hold GNEFrames
GNEPersonFrame * getPersonFrame() const
get frame for DEMAND_PERSON
void eraseACChooserDialog(GNEDialogACChooser *chooserDialog)
remove created chooser dialog
GNEInspectorFrame * getInspectorFrame() const
get frame for inspect elements
GNEApplicationWindow * myGNEAppWindows
pointer to GNEApplicationWindow
GNEEdgeRelDataFrame * getEdgeRelDataFrame() const
get frame for DATA_EDGERELDATA
GNECreateEdgeFrame * getCreateEdgeFrame() const
get frame for NETWORK_CREATEEDGE
GNERouteFrame * getRouteFrame() const
get frame for DEMAND_ROUTE
GNEFrame * getCurrentShownFrame() const
get current frame (note: it can be null)
std::vector< GUIGlID > getObjectIDs(int messageId) const
long onCmdLocate(FXObject *, FXSelector, void *)
locator-callback
~GNEViewParent()
Destructor.
long onKeyRelease(FXObject *o, FXSelector sel, void *data)
Called when user releases a key.
virtual void create()
create GUIGlChildWindow
GUISUMOAbstractView * myView
The view.
FXMenuButton * myLocatorButton
The locator button.
FXPopup * myLocatorPopup
The locator menu.
GUIMainWindow * myParent
The parent window.
static FXIcon * getIcon(const GUIIcon which)
returns a icon previously defined in the enum GUIIcon
void removeGLChild(GUIGlChildWindow *child)
removes the given child window from the list (GUIGlChildWindow)
std::string makeSnapshot(const std::string &destFile, const int w=-1, const int h=-1)
Takes a snapshots and writes it into the given file.
virtual long onKeyPress(FXObject *o, FXSelector sel, void *data)
keyboard functions
virtual long onKeyRelease(FXObject *o, FXSelector sel, void *data)
static FXbool userPermitsOverwritingWhenFileExists(FXWindow *const parent, const FXString &file)
Returns true if either the file given by its name does not exist or the user allows overwriting it.
Definition: MFXUtils.cpp:39
C++ TraCI client API implementation.
Definition: GUI.h:31