Cleanup board/sensor alignment UI.

10.3.x-maintenance
Dominic Clifton 2016-01-07 00:29:31 +01:00
parent 6b3b5a6d94
commit 14135cb64e
4 changed files with 55 additions and 29 deletions

View File

@ -470,13 +470,22 @@
"message": "Board and Sensor Alignment"
},
"configurationBoardAlignmentRoll": {
"message": "Roll Adjustment [deg]"
"message": "Roll Degrees"
},
"configurationBoardAlignmentPitch": {
"message": "Pitch Adjustment [deg]"
"message": "Pitch Degrees"
},
"configurationBoardAlignmentYaw": {
"message": "Yaw Adjustment [deg]"
"message": "Yaw Degrees"
},
"configurationSensorAlignmentGyro": {
"message": "Gyroscope Alignment"
},
"configurationSensorAlignmentAcc": {
"message": "Accelerometer Alignment"
},
"configurationSensorAlignmentMag": {
"message": "Compass/Magnetometer Alignment"
},
"configurationAccelTrims": {
"message": "Accelerometer Trim"

View File

@ -202,7 +202,9 @@
border-bottom: 1px solid #ddd;
}
.tab-configuration .number {
.tab-configuration .number,
.tab-configuration .select
{
margin-bottom: 5px;
clear: left;
padding-bottom: 5px;
@ -211,7 +213,8 @@
float: left;
}
.tab-configuration .number:last-child {
.tab-configuration .number:last-child,
.tab-configuration .select:last-child {
border-bottom: none;
padding-bottom: 0px;
margin-bottom: 0px;
@ -361,12 +364,12 @@
}
.tab-configuration .board select {
float: left;
width: 100%;
/*float: left;*/
width: 50%;
height: 20px;
margin: 0 0px 2px 0;
border: 1px solid silver;
brder-radius:3px;
border-radius:3px;
}
@ -385,7 +388,7 @@
height: 20px;
margin: 0 0px 2px 0;
border: 1px solid silver;
brder-radius:3px;
border-radius:3px;
margin-bottom: 20px;
margin-top:3px;
@ -441,12 +444,17 @@
}
.tab-configuration .sensoralignment {
width: 40%;
width: 60%;
float: left;
}
.tab-configuration .board_align_content {
width: 60%;
width: 40%;
float: left;
}
.tab-configuration .sensoralignment span {
width: 50%;
float: left;
}

View File

@ -123,23 +123,32 @@
</div>
</div>
<div class="sensoralignment">
<div class="number">
<select class="gyroalign">
<option value="0">GYRO alignment: default</option>
<!-- list generated here -->
</select>
<div class="select">
<label>
<span i18n="configurationSensorAlignmentGyro"></span>
<select class="gyroalign">
<option value="0">Default</option>
<!-- list generated here -->
</select>
</label>
</div>
<div class="number">
<select class="accalign">
<option value="0">ACC alignment: default</option>
<!-- list generated here -->
</select>
<div class="select">
<label>
<span i18n="configurationSensorAlignmentAcc"></span>
<select class="accalign">
<option value="0">Default</option>
<!-- list generated here -->
</select>
</label>
</div>
<div class="number">
<select class="magalign">
<option value="0">MAG alignment: default</option>
<!-- list generated here -->
</select>
<div class="select">
<label>
<span i18n="configurationSensorAlignmentMag"></span>
<select class="magalign">
<option value="0">Default</option>
<!-- list generated here -->
</select>
</label>
</div>
</div>
</div>

View File

@ -231,9 +231,9 @@ TABS.configuration.initialize = function (callback, scrollPosition) {
$('.tab-configuration .sensoralignment').hide();
} else {
for (var i = 0; i < alignments.length; i++) {
orientation_gyro_e.append('<option value="' + (i+1) + '">GYRO align: '+ alignments[i] + '</option>');
orientation_acc_e.append('<option value="' + (i+1) + '">ACC align: '+ alignments[i] + '</option>');
orientation_mag_e.append('<option value="' + (i+1) + '">MAG align: '+ alignments[i] + '</option>');
orientation_gyro_e.append('<option value="' + (i+1) + '">'+ alignments[i] + '</option>');
orientation_acc_e.append('<option value="' + (i+1) + '">'+ alignments[i] + '</option>');
orientation_mag_e.append('<option value="' + (i+1) + '">'+ alignments[i] + '</option>');
}
orientation_gyro_e.val(SENSOR_ALIGNMENT.align_gyro);
orientation_acc_e.val(SENSOR_ALIGNMENT.align_acc);