Commit 78004042 authored by dogmaphobic's avatar dogmaphobic

Airframe Panel tweaks.

parent f970a839
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
======================================================================*/ ======================================================================*/
import QtQuick 2.2 import QtQuick 2.5
import QtQuick.Controls 1.2 import QtQuick.Controls 1.2
import QtQuick.Controls.Styles 1.2 import QtQuick.Controls.Styles 1.2
import QtQuick.Dialogs 1.2 import QtQuick.Dialogs 1.2
...@@ -180,7 +180,7 @@ QGCView { ...@@ -180,7 +180,7 @@ QGCView {
Rectangle { Rectangle {
id: airframeBackground id: airframeBackground
width: _boxWidth width: _boxWidth
height: ScreenTools.defaultFontPixelWidth * 22.5 height: ScreenTools.defaultFontPixelHeight * 14
color: (modelData.name != controller.currentAirframeType) ? qgcPal.windowShade : qgcPal.buttonHighlight color: (modelData.name != controller.currentAirframeType) ? qgcPal.windowShade : qgcPal.buttonHighlight
readonly property real titleHeight: ScreenTools.defaultFontPixelHeight * 1.75 readonly property real titleHeight: ScreenTools.defaultFontPixelHeight * 1.75
...@@ -210,22 +210,22 @@ QGCView { ...@@ -210,22 +210,22 @@ QGCView {
id: image id: image
anchors.topMargin: innerMargin anchors.topMargin: innerMargin
anchors.top: title.bottom anchors.top: title.bottom
x: innerMargin width: parent.width * 0.75
width: parent.width - (innerMargin * 2)
height: parent.height - title.height - combo.height - (innerMargin * 3) height: parent.height - title.height - combo.height - (innerMargin * 3)
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
smooth: true smooth: true
mipmap: true
source: modelData.imageResource source: modelData.imageResource
anchors.horizontalCenter: parent.horizontalCenter
} }
QGCCheckBox { QGCCheckBox {
id: airframeCheckBox id: airframeCheckBox
anchors.bottom: image.bottom
anchors.right: image.right
checked: modelData.name == controller.currentAirframeType checked: modelData.name == controller.currentAirframeType
exclusiveGroup: airframeTypeExclusive exclusiveGroup: airframeTypeExclusive
anchors.bottom: image.bottom
anchors.right: parent.right
anchors.rightMargin: innerMargin
onCheckedChanged: { onCheckedChanged: {
if (checked && combo.currentIndex != -1) { if (checked && combo.currentIndex != -1) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment