Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
75bdcff0
Commit
75bdcff0
authored
Sep 26, 2015
by
Don Gagne
Browse files
Merge pull request #1896 from DonLakeFlyer/MobileWidget
No widgets in mobile builds
parents
0615c0b7
d65d0f3c
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/ui/MainWindow.cc
View file @
75bdcff0
...
...
@@ -822,6 +822,8 @@ void MainWindow::_storeCurrentViewState(void)
{
// HIL dock widgets are dynamic and are not part of the saved state
_hideAllHilDockWidgets
();
#ifndef __mobile__
// Save list of visible widgets
bool
firstWidget
=
true
;
QString
widgetNames
=
""
;
...
...
@@ -835,6 +837,7 @@ void MainWindow::_storeCurrentViewState(void)
}
}
settings
.
setValue
(
_getWindowStateKey
()
+
"WIDGETS"
,
widgetNames
);
#endif
settings
.
setValue
(
_getWindowStateKey
(),
saveState
());
settings
.
setValue
(
_getWindowGeometryKey
(),
saveGeometry
());
}
...
...
@@ -905,6 +908,7 @@ void MainWindow::_loadCurrentViewState(void)
// Hide all widgets from previous view
_hideAllDockWidgets
();
#ifndef __mobile__
// Restore the widgets for the new view
QString
widgetNames
=
settings
.
value
(
_getWindowStateKey
()
+
"WIDGETS"
,
defaultWidgets
).
toString
();
qDebug
()
<<
widgetNames
;
...
...
@@ -915,6 +919,7 @@ void MainWindow::_loadCurrentViewState(void)
_showDockWidget
(
widgetName
,
true
);
}
}
#endif
if
(
settings
.
contains
(
_getWindowStateKey
()))
{
restoreState
(
settings
.
value
(
_getWindowStateKey
()).
toByteArray
());
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment