/**************************************************************************** * * (c) 2009-2016 QGROUNDCONTROL PROJECT * * QGroundControl is licensed according to the terms in the file * COPYING.md in the root of the source code directory. * ****************************************************************************/ import QtQuick 2.5 import QtQuick.Controls 1.2 import QtQuick.Dialogs 1.2 import QtQuick.Layouts 1.2 import QGroundControl.FactSystem 1.0 import QGroundControl.FactControls 1.0 import QGroundControl.Palette 1.0 import QGroundControl.Controls 1.0 import QGroundControl.ScreenTools 1.0 SetupPage { id: powerPage pageComponent: powerPageComponent Component { id: powerPageComponent Column { spacing: _margins property Fact battAmpPerVolt: controller.getParameterFact(-1, "BATT_AMP_PERVOLT") property Fact battCapacity: controller.getParameterFact(-1, "BATT_CAPACITY") property Fact battCurrPin: controller.getParameterFact(-1, "BATT_CURR_PIN") property Fact battMonitor: controller.getParameterFact(-1, "BATT_MONITOR") property Fact battVoltMult: controller.getParameterFact(-1, "BATT_VOLT_MULT") property Fact battVoltPin: controller.getParameterFact(-1, "BATT_VOLT_PIN") property real _margins: ScreenTools.defaultFontPixelHeight / 2 property bool _showAdvanced: sensorCombo.currentIndex == sensorModel.count - 1 property real _fieldWidth: ScreenTools.defaultFontPixelWidth * 25 Component.onCompleted: calcSensor() function calcSensor() { for (var i=0; i