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
844e6780
Commit
844e6780
authored
Apr 06, 2017
by
DonLakeFlyer
Browse files
Fix toolstrip recalc
parent
5cc59734
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/QmlControls/ToolStrip.qml
View file @
844e6780
...
...
@@ -39,7 +39,7 @@ Rectangle {
// whether to show or hide the optional elements on the fly.
property
bool
_showOptionalElements
:
true
property
bool
_needRecalc
:
tru
e
property
bool
_needRecalc
:
fals
e
Component.onCompleted
:
recalcShowOptionalElements
()
...
...
@@ -54,7 +54,6 @@ Rectangle {
onDefaultFontPixelHeightChanged
:
recalcShowOptionalElements
()
}
/*
onHeightChanged
:
{
if
(
_needRecalc
)
{
_needRecalc
=
false
...
...
@@ -63,18 +62,13 @@ Rectangle {
}
}
}
*/
function
recalcShowOptionalElements
()
{
if
(
_showOptionalElements
)
{
if
(
maxHeight
&&
height
>
maxHeight
)
{
_showOptionalElements
=
false
}
}
else
{
if
(
maxHeight
>
0
)
{
_needRecalc
=
false
_showOptionalElements
=
height
<=
maxHeight
_needRecalc
=
true
_showOptionalElements
=
true
}
}
QGCPalette
{
id
:
qgcPal
}
...
...
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