Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Leander Schulten
Lichtsteuerung
Commits
9fc898b2
Commit
9fc898b2
authored
Oct 08, 2019
by
Leander Schulten
Browse files
UX: ControlItem: Do not open the settings Popup outside the viewport
parent
e25e6420
Pipeline
#191761
passed with stage
in 4 minutes and 53 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/qml/ControlPane/ControlItem.qml
View file @
9fc898b2
...
...
@@ -66,6 +66,7 @@ ControlItemTemplate{
let
pos
=
mapToItem
(
item
.
parent
,
pressX
,
pressY
);
// do not move the popup out of the viewport
pos
.
x
=
Math
.
min
(
pos
.
x
,
item
.
parent
.
width
-
popup
.
width
-
5
);
pos
.
y
=
Math
.
min
(
pos
.
y
,
item
.
parent
.
height
-
popup
.
height
-
5
);
pos
=
item
.
mapFromItem
(
item
.
parent
,
pos
.
x
,
pos
.
y
);
popup
.
x
=
pos
.
x
;
popup
.
y
=
pos
.
y
;
...
...
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