|
|
@ -37,16 +37,13 @@ MapPanel::MapPanel(const QMapboxGLSettings &mapboxSettings, QWidget *parent) : Q |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void MapPanel::requestVisible(bool visible) { |
|
|
|
void MapPanel::requestVisible(bool visible) { |
|
|
|
if (visible != isVisible()) { |
|
|
|
|
|
|
|
// signal HomeWindow to hide the sidebar and switch to map window if showing
|
|
|
|
// signal HomeWindow to hide the sidebar and switch to map window if showing
|
|
|
|
// TODO: perhaps showEvent is better
|
|
|
|
|
|
|
|
if (visible) { |
|
|
|
if (visible) { |
|
|
|
emit mapPanelRequested(); |
|
|
|
emit mapPanelRequested(); |
|
|
|
content_stack->setCurrentIndex(0); |
|
|
|
content_stack->setCurrentIndex(0); |
|
|
|
} |
|
|
|
} |
|
|
|
setVisible(visible); |
|
|
|
setVisible(visible); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void MapPanel::toggleMapSettings() { |
|
|
|
void MapPanel::toggleMapSettings() { |
|
|
|
requestVisible(true); |
|
|
|
requestVisible(true); |
|
|
|