| 1313 | |
| 1314 | |
| 1315 | bool AppFrame::actionOnMenuDisplay(wxCommandEvent& event) { |
| 1316 | |
| 1317 | //by default, is managed. |
| 1318 | bool bManaged = true; |
| 1319 | |
| 1320 | if (event.GetId() == wxID_THEME_DEFAULT) { |
| 1321 | ThemeMgr::mgr.setTheme(COLOR_THEME_DEFAULT); |
| 1322 | } |
| 1323 | else if (event.GetId() == wxID_THEME_DEFAULT_JET) { |
| 1324 | ThemeMgr::mgr.setTheme(COLOR_THEME_DEFAULT_JET); |
| 1325 | } |
| 1326 | else if (event.GetId() == wxID_THEME_SHARP) { |
| 1327 | ThemeMgr::mgr.setTheme(COLOR_THEME_SHARP); |
| 1328 | } |
| 1329 | else if (event.GetId() == wxID_THEME_BW) { |
| 1330 | ThemeMgr::mgr.setTheme(COLOR_THEME_BW); |
| 1331 | } |
| 1332 | else if (event.GetId() == wxID_THEME_RAD) { |
| 1333 | ThemeMgr::mgr.setTheme(COLOR_THEME_RAD); |
| 1334 | } |
| 1335 | else if (event.GetId() == wxID_THEME_TOUCH) { |
| 1336 | ThemeMgr::mgr.setTheme(COLOR_THEME_TOUCH); |
| 1337 | } |
| 1338 | else if (event.GetId() == wxID_THEME_HD) { |
| 1339 | ThemeMgr::mgr.setTheme(COLOR_THEME_HD); |
| 1340 | } |
| 1341 | else if (event.GetId() == wxID_THEME_RADAR) { |
| 1342 | ThemeMgr::mgr.setTheme(COLOR_THEME_RADAR); |
| 1343 | } |
| 1344 | //Display : font sizes |
| 1345 | else if (event.GetId() == wxID_DISPLAY_BASE) { |
| 1346 | GLFont::setScale(GLFont::GLFONT_SCALE_NORMAL); |
| 1347 | } |
| 1348 | else if (event.GetId() == wxID_DISPLAY_BASE + 1) { |
| 1349 | GLFont::setScale(GLFont::GLFONT_SCALE_MEDIUM); |
| 1350 | } |
| 1351 | else if (event.GetId() == wxID_DISPLAY_BASE + 2) { |
| 1352 | GLFont::setScale(GLFont::GLFONT_SCALE_LARGE); |
| 1353 | } |
| 1354 | else if (event.GetId() == wxID_DISPLAY_BOOKMARKS) { |
| 1355 | if (hideBookmarksItem->IsChecked()) { |
| 1356 | bookmarkSplitter->Unsplit(bookmarkView); |
| 1357 | bookmarkSplitter->Layout(); |
| 1358 | } |
| 1359 | else { |
| 1360 | bookmarkSplitter->SplitVertically(bookmarkView, mainVisSplitter, wxGetApp().getConfig()->getBookmarkSplit()); |
| 1361 | bookmarkSplitter->Layout(); |
| 1362 | } |
| 1363 | } |
| 1364 | else { |
| 1365 | bManaged = false; |
| 1366 | } |
| 1367 | |
| 1368 | //update theme choice in children elements: |
| 1369 | if (event.GetId() >= wxID_THEME_DEFAULT && event.GetId() <= wxID_THEME_RADAR) { |
| 1370 | |
| 1371 | gainCanvas->setThemeColors(); |
| 1372 | modemProps->updateTheme(); |
nothing calls this directly
no test coverage detected