diff --git a/src/PlanView/GeoFenceEditor.qml b/src/PlanView/GeoFenceEditor.qml index b34ec3e..114f85e 100644 --- a/src/PlanView/GeoFenceEditor.qml +++ b/src/PlanView/GeoFenceEditor.qml @@ -30,7 +30,7 @@ QGCFlickable { width: parent.width height: geoFenceItems.y + geoFenceItems.height + (_margin * 2) radius: _radius - color: qgcPal.buttonHighlight + color: qgcPal.missionItemEditor QGCLabel { id: geoFenceLabel diff --git a/src/PlanView/RallyPointEditorHeader.qml b/src/PlanView/RallyPointEditorHeader.qml index 7f99828..ba87f94 100644 --- a/src/PlanView/RallyPointEditorHeader.qml +++ b/src/PlanView/RallyPointEditorHeader.qml @@ -20,7 +20,7 @@ QGCFlickable { width: parent.width height: innerEditorRect.y + innerEditorRect.height + (_margin * 2) radius: _radius - color: qgcPal.buttonHighlight + color: qgcPal.missionItemEditor QGCLabel { id: editorLabel diff --git a/src/PlanView/RallyPointItemEditor.qml b/src/PlanView/RallyPointItemEditor.qml index b6b36ed..775f322 100644 --- a/src/PlanView/RallyPointItemEditor.qml +++ b/src/PlanView/RallyPointItemEditor.qml @@ -11,7 +11,7 @@ import QGroundControl.Palette 1.0 Rectangle { id: root height: _currentItem ? valuesRect.y + valuesRect.height + (_margin * 2) : titleBar.y - titleBar.height + _margin - color: _currentItem ? qgcPal.buttonHighlight : qgcPal.windowShade + color: _currentItem ? qgcPal.missionItemEditor : qgcPal.windowShade radius: _radius property var rallyPoint ///< RallyPoint object associated with editor diff --git a/src/PlanView/RallyPointMapVisuals.qml b/src/PlanView/RallyPointMapVisuals.qml index 1f05dfc..f303349 100644 --- a/src/PlanView/RallyPointMapVisuals.qml +++ b/src/PlanView/RallyPointMapVisuals.qml @@ -41,6 +41,19 @@ Item { } Component { + id: dragAreaComponent + + MissionItemIndicatorDrag { + itemCoordinate: rallyPointObject.coordinate + visible: rallyPointObject == myRallyPointController.currentRallyPoint + + property var rallyPointObject + + onItemCoordinateChanged: rallyPointObject.coordinate = itemCoordinate + } + } + + Component { id: rallyPointComponent MapQuickItem { @@ -72,17 +85,14 @@ Item { property var _visuals: [ ] Component.onCompleted: { - var rallyPoint = rallyPointComponent.createObject(map) - rallyPoint.coordinate = Qt.binding(function() { return object.coordinate }) - rallyPoint.rallyPointObject = Qt.binding(function() { return object }) - map.addMapItem(rallyPoint) - _visuals.push(rallyPoint) -/* - var dragArea = dragAreaComponent.createObject(map, { "itemIndicator": dragHandle, "itemCoordinate": object.coordinate }) - dragArea.polygonVertex = Qt.binding(function() { return index }) - _visuals.push(dragHandle) + var rallyPointIndicator = rallyPointComponent.createObject(map) + rallyPointIndicator.coordinate = Qt.binding(function() { return object.coordinate }) + rallyPointIndicator.rallyPointObject = Qt.binding(function() { return object }) + map.addMapItem(rallyPointIndicator) + _visuals.push(rallyPointIndicator) + + var dragArea = dragAreaComponent.createObject(map, { "itemIndicator": rallyPointIndicator, "rallyPointObject": object }) _visuals.push(dragArea) -*/ } Component.onDestruction: { diff --git a/src/QmlControls/QGCRadioButton.qml b/src/QmlControls/QGCRadioButton.qml index d0ed7c0..ccaaf0e 100644 --- a/src/QmlControls/QGCRadioButton.qml +++ b/src/QmlControls/QGCRadioButton.qml @@ -6,11 +6,10 @@ import QGroundControl.Palette 1.0 import QGroundControl.ScreenTools 1.0 RadioButton { - property var color: qgcPal.text ///< Text color - property int textStyle: Text.Normal - property color textStyleColor: qgcPal.text - - QGCPalette { id: qgcPal; colorGroupEnabled: enabled } + property var color: qgcPal.text ///< Text color + property int textStyle: Text.Normal + property color textStyleColor: qgcPal.text + property var qgcPal: QGCPalette { colorGroupEnabled: enabled } style: RadioButtonStyle { label: Item { @@ -47,7 +46,8 @@ RadioButton { indicator: Rectangle { width: ScreenTools.radioButtonIndicatorSize height: width - border.color: qgcPal.text + color: "white" + border.color: control.qgcPal.text antialiasing: true radius: height / 2 @@ -56,8 +56,8 @@ RadioButton { width: Math.round(parent.width * 0.5) height: width antialiasing: true - radius: height/2 - color: qgcPal.text + radius: height / 2 + color: "black" opacity: control.checked ? (control.enabled ? 1 : 0.5) : 0 } }