Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
033b9fc8
Commit
033b9fc8
authored
May 01, 2019
by
Gus Grubba
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Handle window initial and minimal size
Enable full screen / windowed toggle
parent
b3807a9f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
55 additions
and
5 deletions
+55
-5
MainRootWindow.qml
src/ui/MainRootWindow.qml
+23
-5
DebugWindow.qml
src/ui/preferences/DebugWindow.qml
+32
-0
No files found.
src/ui/MainRootWindow.qml
View file @
033b9fc8
...
...
@@ -12,6 +12,7 @@ import QtQuick 2.11
import
QtQuick
.
Controls
2.4
import
QtQuick
.
Dialogs
1.3
import
QtQuick
.
Layouts
1.11
import
QtQuick
.
Window
2.11
import
QGroundControl
1.0
import
QGroundControl
.
Palette
1.0
...
...
@@ -23,12 +24,18 @@ import QGroundControl.FlightMap 1.0
/// Native QML top level window
ApplicationWindow
{
id
:
mainWindow
width
:
1280
height
:
720
minimumWidth
:
920
minimumHeight
:
646
width
:
ScreenTools
.
isMobile
?
Screen
.
width
:
Math
.
min
(
250
*
Screen
.
pixelDensity
,
Screen
.
width
)
height
:
ScreenTools
.
isMobile
?
Screen
.
height
:
Math
.
min
(
150
*
Screen
.
pixelDensity
,
Screen
.
height
)
minimumWidth
:
ScreenTools
.
isMobile
?
Screen
.
width
:
Math
.
min
(
215
*
Screen
.
pixelDensity
,
Screen
.
width
)
minimumHeight
:
ScreenTools
.
isMobile
?
Screen
.
height
:
Math
.
min
(
120
*
Screen
.
pixelDensity
,
Screen
.
height
)
visible
:
true
Component.onCompleted
:
{
if
(
ScreenTools
.
isMobile
)
{
mainWindow
.
showFullScreen
()
}
}
readonly
property
real
_topBottomMargins
:
ScreenTools
.
defaultFontPixelHeight
*
0.5
readonly
property
string
_mainToolbar
:
QGroundControl
.
corePlugin
.
options
.
mainToolbarUrl
readonly
property
string
_planToolbar
:
QGroundControl
.
corePlugin
.
options
.
planToolbarUrl
...
...
@@ -287,6 +294,18 @@ ApplicationWindow {
id
:
toolbar
anchors.fill
:
parent
source
:
_mainToolbar
//-- Toggle Full Screen / Windowed
MouseArea
{
anchors.fill
:
parent
enabled
:
!
ScreenTools
.
isMobile
onDoubleClicked
:
{
if
(
mainWindow
.
visibility
===
Window
.
Windowed
)
{
mainWindow
.
showFullScreen
()
}
else
{
mainWindow
.
showNormal
()
}
}
}
}
}
...
...
@@ -594,4 +613,3 @@ ApplicationWindow {
}
}
src/ui/preferences/DebugWindow.qml
View file @
033b9fc8
...
...
@@ -242,6 +242,38 @@ Item {
font.pointSize
:
16
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
qsTr
(
"
Desktop Available Width:
"
)
color
:
qgcPal
.
text
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
Screen
.
desktopAvailableWidth
color
:
qgcPal
.
text
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
qsTr
(
"
Font Point Size 16.5
"
)
color
:
qgcPal
.
text
font.pointSize
:
16.5
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
qsTr
(
"
Desktop Available Height:
"
)
color
:
qgcPal
.
text
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
Screen
.
desktopAvailableHeight
color
:
qgcPal
.
text
font.family
:
ScreenTools
.
normalFontFamily
}
Text
{
text
:
qsTr
(
"
Font Point Size 17
"
)
color
:
qgcPal
.
text
font.pointSize
:
17
font.family
:
ScreenTools
.
normalFontFamily
}
}
Rectangle
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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