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
d28bafba
Commit
d28bafba
authored
May 30, 2018
by
Gus Grubba
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Double click to delete a vertex
parent
79f54537
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
27 additions
and
23 deletions
+27
-23
MissionItemIndicatorDrag.qml
src/FlightMap/MapItems/MissionItemIndicatorDrag.qml
+6
-0
QGCMapPolygonVisuals.qml
src/MissionManager/QGCMapPolygonVisuals.qml
+1
-1
QGCMapPolylineVisuals.qml
src/MissionManager/QGCMapPolylineVisuals.qml
+14
-15
CorridorScanEditor.qml
src/PlanView/CorridorScanEditor.qml
+6
-7
No files found.
src/FlightMap/MapItems/MissionItemIndicatorDrag.qml
View file @
d28bafba
...
@@ -29,6 +29,7 @@ Rectangle {
...
@@ -29,6 +29,7 @@ Rectangle {
property
var
itemCoordinate
///< Coordinate we are updating during drag
property
var
itemCoordinate
///< Coordinate we are updating during drag
signal
clicked
signal
clicked
signal
doubleClicked
signal
dragStart
signal
dragStart
signal
dragStop
signal
dragStop
...
@@ -76,6 +77,11 @@ Rectangle {
...
@@ -76,6 +77,11 @@ Rectangle {
itemDragger
.
clicked
()
itemDragger
.
clicked
()
}
}
onDoubleClicked
:
{
focus
=
true
itemDragger
.
doubleClicked
()
}
property
bool
dragActive
:
drag
.
active
property
bool
dragActive
:
drag
.
active
onDragActiveChanged
:
{
onDragActiveChanged
:
{
if
(
dragActive
)
{
if
(
dragActive
)
{
...
...
src/MissionManager/QGCMapPolygonVisuals.qml
View file @
d28bafba
...
@@ -291,7 +291,7 @@ Item {
...
@@ -291,7 +291,7 @@ Item {
}
}
}
}
onClicked
:
mapPolygon
.
removeVertex
(
polygonVertex
)
on
Double
Clicked
:
mapPolygon
.
removeVertex
(
polygonVertex
)
}
}
}
}
...
...
src/MissionManager/QGCMapPolylineVisuals.qml
View file @
d28bafba
...
@@ -128,10 +128,10 @@ Item {
...
@@ -128,10 +128,10 @@ Item {
Menu
{
Menu
{
id
:
menu
id
:
menu
property
int
removeVertex
property
int
removeVertex
MenuItem
{
MenuItem
{
id
:
removeVertexItem
text
:
qsTr
(
"
Remove vertex
"
)
text
:
qsTr
(
"
Remove vertex
"
)
onTriggered
:
mapPolyline
.
removeVertex
(
parent
.
removeVertex
)
onTriggered
:
mapPolyline
.
removeVertex
(
parent
.
removeVertex
)
}
}
...
@@ -140,6 +140,10 @@ Item {
...
@@ -140,6 +140,10 @@ Item {
text
:
qsTr
(
"
Load KML...
"
)
text
:
qsTr
(
"
Load KML...
"
)
onTriggered
:
kmlLoadDialog
.
openForLoad
()
onTriggered
:
kmlLoadDialog
.
openForLoad
()
}
}
function
resetMenu
()
{
removeVertexItem
.
visible
=
mapPolyline
.
count
>
2
}
}
}
Component
{
Component
{
...
@@ -167,7 +171,7 @@ Item {
...
@@ -167,7 +171,7 @@ Item {
width
:
ScreenTools
.
defaultFontPixelHeight
*
1.5
width
:
ScreenTools
.
defaultFontPixelHeight
*
1.5
height
:
width
height
:
width
radius
:
width
/
2
radius
:
width
/
2
border.color
:
"
white
"
border.color
:
"
white
"
color
:
"
transparent
"
color
:
"
transparent
"
opacity
:
.
50
opacity
:
.
50
z
:
_zorderSplitHandle
z
:
_zorderSplitHandle
...
@@ -243,10 +247,13 @@ Item {
...
@@ -243,10 +247,13 @@ Item {
}
}
onClicked
:
{
onClicked
:
{
if
(
polylineVertex
==
0
)
{
menu
.
resetMenu
()
menu
.
removeVertex
=
polylineVertex
menu
.
removeVertex
=
polylineVertex
menu
.
popup
()
menu
.
popup
()
}
else
{
}
onDoubleClicked
:
{
if
(
polylineVertex
!=
0
)
{
mapPolyline
.
removeVertex
(
polylineVertex
)
mapPolyline
.
removeVertex
(
polylineVertex
)
}
}
}
}
...
@@ -271,15 +278,7 @@ Item {
...
@@ -271,15 +278,7 @@ Item {
height
:
width
height
:
width
radius
:
width
/
2
radius
:
width
/
2
color
:
"
white
"
color
:
"
white
"
opacity
:
.
90
opacity
:
0.9
QGCLabel
{
anchors.horizontalCenter
:
parent
.
horizontalCenter
anchors.verticalCenter
:
parent
.
verticalCenter
text
:
"
...
"
color
:
"
black
"
visible
:
polylineVertex
==
0
}
}
}
}
}
}
}
...
...
src/PlanView/CorridorScanEditor.qml
View file @
d28bafba
...
@@ -106,11 +106,11 @@ Rectangle {
...
@@ -106,11 +106,11 @@ Rectangle {
QGCCheckBox
{
QGCCheckBox
{
id
:
relAlt
id
:
relAlt
anchors.left
:
parent
.
left
text
:
qsTr
(
"
Relative altitude
"
)
text
:
qsTr
(
"
Relative altitude
"
)
checked
:
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
checked
:
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
enabled
:
missionItem
.
cameraCalc
.
isManualCamera
&&
!
missionItem
.
followTerrain
enabled
:
missionItem
.
cameraCalc
.
isManualCamera
&&
!
missionItem
.
followTerrain
visible
:
QGroundControl
.
corePlugin
.
options
.
showMissionAbsoluteAltitude
||
(
!
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
&&
!
missionItem
.
followTerrain
)
visible
:
QGroundControl
.
corePlugin
.
options
.
showMissionAbsoluteAltitude
||
(
!
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
&&
!
missionItem
.
followTerrain
)
Layout.alignment
:
Qt
.
AlignLeft
Layout.columnSpan
:
2
Layout.columnSpan
:
2
onClicked
:
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
=
checked
onClicked
:
missionItem
.
cameraCalc
.
distanceToSurfaceRelative
=
checked
...
@@ -146,12 +146,11 @@ Rectangle {
...
@@ -146,12 +146,11 @@ Rectangle {
}
}
GridLayout
{
GridLayout
{
anchors.left
:
parent
.
left
Layout.fillWidth
:
true
anchors.right
:
parent
.
right
columnSpacing
:
_margin
columnSpacing
:
_margin
rowSpacing
:
_margin
rowSpacing
:
_margin
columns
:
2
columns
:
2
visible
:
followsTerrainCheckBox
.
checked
visible
:
followsTerrainCheckBox
.
checked
QGCLabel
{
text
:
qsTr
(
"
Tolerance
"
)
}
QGCLabel
{
text
:
qsTr
(
"
Tolerance
"
)
}
FactTextField
{
FactTextField
{
...
...
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