53 : FXDialogBox(parent,
TL("Application Settings")),
60 FXCheckButton* b =
nullptr;
61 FXVerticalFrame* f1 =
new FXVerticalFrame(
this, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0);
63 b->setCheck(myAppQuitOnEnd);
64 b =
new FXCheckButton(f1,
TL(
"Autostart Simulation on Load and Reload"),
this,
MID_AUTOSTART);
65 b->setCheck(myAppAutoStart);
66 b =
new FXCheckButton(f1,
TL(
"Reload Simulation after finish (Demo mode)"),
this,
MID_DEMO);
67 b->setCheck(myAppDemo);
68 b =
new FXCheckButton(f1,
TL(
"Locate elements when clicking on messages"),
this,
MID_LOCATELINKS);
69 b->setCheck(myLocateLinks);
71 FXMatrix* m1 =
new FXMatrix(f1, 2, (LAYOUT_FILL_X | LAYOUT_LEFT | MATRIX_BY_COLUMNS), 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
76 const auto& onlineMaps = parent->getOnlineMaps();
77 const int numRows = (int)onlineMaps.size() + 1;
78 myTable->setVisibleRows(numRows);
79 myTable->setVisibleColumns(2);
80 myTable->setTableSize(numRows, 2);
81 myTable->setBackColor(FXRGB(255, 255, 255));
82 myTable->getRowHeader()->setWidth(0);
83 myTable->setTableSize(numRows, 2);
84 myTable->setColumnText(0,
"Name");
85 myTable->setColumnText(1,
"URL");
86 FXHeader* header = myTable->getColumnHeader();
88 header->setItemSize(0, 60);
89 header->setItemSize(1, 275);
91 for (
const auto& item : onlineMaps) {
92 myTable->setItemText(row, 0, item.first.c_str());
93 myTable->setItemText(row, 1, item.second.c_str());
97 new FXHorizontalSeparator(f1, SEPARATOR_GROOVE | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_FILL_X);
99 b->setCheck(myAllowTextures);
100 FXHorizontalFrame* f2 =
new FXHorizontalFrame(f1, LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_FILL_X | PACK_UNIFORM_WIDTH, 0, 0, 0, 0, 10, 10, 5, 5);
101 FXButton* initial =
GUIDesigns::buildFXButton(f2,
TL(
"&OK"),
"",
"",
nullptr,
this,
MID_SETTINGS_OK, BUTTON_INITIAL | BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 30, 30, 4, 4);
102 GUIDesigns::buildFXButton(f2,
TL(
"&Cancel"),
"",
"",
nullptr,
this,
MID_SETTINGS_CANCEL, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 30, 30, 4, 4);
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
void addOnlineMap(const std::string &name, const std::string &url)
Global storage for textures; manages and draws them.
static void allowTextures(const bool val)
switch texture drawing on and off