diff --git a/_locales/en/messages.json b/_locales/en/messages.json
index 684d5c7f..14ac0f27 100755
--- a/_locales/en/messages.json
+++ b/_locales/en/messages.json
@@ -2442,6 +2442,9 @@
"missionTotalInformationHead": {
"message": "Total information"
},
+ "missionRTHsettingsTitle": {
+ "message": "RTH settings"
+ },
"useOnlyStandalone": {
"message": "Use stand-alone application.
Please visit the website to read the release notes and download."
},
diff --git a/js/fc.js b/js/fc.js
index 144d4495..ac0f10bd 100644
--- a/js/fc.js
+++ b/js/fc.js
@@ -214,7 +214,8 @@ var FC = {
lat: 0,
lon: 0,
alt: 0,
- endMission: 0
+ endMission: 0,
+ p1: 0
}
};
diff --git a/js/msp/MSPHelper.js b/js/msp/MSPHelper.js
index f410e6cf..1bab868a 100644
--- a/js/msp/MSPHelper.js
+++ b/js/msp/MSPHelper.js
@@ -452,6 +452,7 @@ var mspHelper = (function (gui) {
MISSION_PLANER.bufferPoint.lat = data.getInt32(2, true) / 10000000;
MISSION_PLANER.bufferPoint.lon = data.getInt32(6, true) / 10000000;
MISSION_PLANER.bufferPoint.alt = data.getInt32(10, true);
+ MISSION_PLANER.bufferPoint.p1 = data.getInt16(14, true);
break;
case MSPCodes.MSP_BOXIDS:
@@ -1839,8 +1840,8 @@ var mspHelper = (function (gui) {
buffer.push(specificByte(MISSION_PLANER.bufferPoint.alt, 1));
buffer.push(specificByte(MISSION_PLANER.bufferPoint.alt, 2));
buffer.push(specificByte(MISSION_PLANER.bufferPoint.alt, 3));
- buffer.push(lowByte(0)); //sbufReadU16(src); // P1
- buffer.push(highByte(0));
+ buffer.push(lowByte(MISSION_PLANER.bufferPoint.p1)); //sbufReadU16(src); // P1 speed or landing
+ buffer.push(highByte(MISSION_PLANER.bufferPoint.p1));
buffer.push(lowByte(0)); //sbufReadU16(src); // P2
buffer.push(highByte(0));
buffer.push(lowByte(0)); //sbufReadU16(src); // P3
diff --git a/main.js b/main.js
index 5725c8cc..a177d1ce 100644
--- a/main.js
+++ b/main.js
@@ -59,19 +59,21 @@ $(document).ready(function () {
}
});
+ win.setMinimumSize(1024, 800);
+
win.on('close', function () {
//Save window size and position
- var height = win.height;
- var width = win.width;
+ // var height = win.height;
+ // var width = win.width;
+ //
+ // if (height < 400) {
+ // height = 400
+ // }
+ // if (width < 512) {
+ // width = 512
+ // }
- if (height < 400) {
- height = 400
- }
- if (width < 512) {
- width = 512
- }
-
- chrome.storage.local.set({'windowSize': {height: height, width: width, x: win.x, y: win.y}}, function () {
+ chrome.storage.local.set({'windowSize': {height: win.height, width: win.width, x: win.x, y: win.y}}, function () {
// Notify that we saved.
console.log('Settings saved');
});
diff --git a/src/css/tabs/mission_planer.css b/src/css/tabs/mission_planer.css
index 40bd7f7b..234f3d2c 100644
--- a/src/css/tabs/mission_planer.css
+++ b/src/css/tabs/mission_planer.css
@@ -1,20 +1,56 @@
-.tab-calibration .content_toolbar {
- height: 100px;
+.tab-mission-control .btn a {
+ /* common styles for content toolbar buttons */
+ /*margin-top: 0;*/
+ /*margin-bottom: 0;*/
+ /*margin-right: 20px;*/
+ background-color: #37a8db;
+ border-radius: 3px;
+ border: 1px solid #3394b5;
+ color: #fff;
+ /*float: right;*/
+ font-family: 'open_sansbold', Arial, serif;
+ font-size: 12px;
+ text-shadow: 0 1px rgba(0, 0, 0, 0.25);
+ display: block;
+ cursor: pointer;
+ transition: all ease 0.2s;
+ padding: 0 9px;
+ line-height: 28px;
+ margin: 5px;
+ float: left;
+ width: 130px;
+ text-align: center;
}
-.tab-mission-control .waypoint {
- padding-left: 19px;
- padding-right: 19px;
- /*padding-bottom: 10px;*/
+.tab-mission-control .btn a:hover {
+ background-color: #3394b5;
+ transition: all ease 0.2s;
}
-.tab-mission-control .waypoint-left {
- width: 54%;
- float: left;
- padding-right: 5px;
+
+.tab-mission-control .btn a:active {
+ background-color: #37a8db;
+ transition: all ease 0.0s;
+ box-shadow: inset 0 1px 5px rgba(0, 0, 0, 0.35);
}
-.tab-mission-control .waypoint-right{
- width: 40%;
- float: right;
+
+.tab-mission-control .btn a.disabled {
+ cursor: default;
+ color: #fff;
+ background-color: #AFAFAF;
+ border: 1px solid #AFAFAF;
+ pointer-events: none;
+ text-shadow: none;
+ opacity: 0.5;
+}
+
+.tab-mission-control .btn-danger a {
+ background-color: #db250e;
+ border: 1px solid #b5480e;
+}
+
+.tab-mission-control .btn-danger a:hover {
+ background-color: #b5480e;
+ transition: all ease 0.2s;
}
.tab-mission-control .checksfail {
@@ -28,6 +64,26 @@
background-repeat:no-repeat;
}
+.tab-mission-control .content_wrapper {
+ display: flex;
+ /*height: 150px;*/
+ height: 90%;
+ /*width: 75%;*/
+ flex-direction: row;
+ justify-content: space-between;
+ flex-wrap: wrap;
+ padding-bottom: 5px;
+ padding-top: 5px;
+}
+
+.tab-mission-control {
+ height: 100%;
+}
+
+#missionMap {
+ height: 100%;
+}
+
.tab-mission-control input {
width: 115px;
padding-left: 3px;
@@ -36,87 +92,119 @@
text-align: left;
border: 1px solid silver;
border-radius: 3px;
- margin-left: 11px;
+ font-size: 12px;
+ font-weight: normal;
+}
+
+.tab-mission-control select {
+ width: 118px;
+ padding-left: 3px;
+ height: 20px;
+ line-height: 20px;
+ text-align: left;
+ border: 1px solid silver;
+ border-radius: 3px;
font-size: 12px;
font-weight: normal;
}
.tab-mission-control .point {
- display: inline-block;
+ display: block;
margin-bottom: 5px;
margin-left: 5px;
}
-
.tab-mission-control .point-label {
-
+ width: 60px;
+ display: inline-block;
}
-@media (max-width: 1236px) {
- .tab-mission-control .waypoint-left {
- width: 96%;
- }
- .tab-mission-control .waypoint-right{
- width: 96%;
- float: left;
- padding-right: 19px;
- }
- .tab-mission-control .content_toolbar {
- height: 240px;
- }
- .tab-mission-control .content_wrapper {
- height: calc(100% - 240px);
- }
-}
+/*.tab-calibration .content_toolbar {*/
+ /*height: 100px;*/
+/*}*/
-/* Need test! */
-.tab-mission-control .content_toolbar {
- display: flex;
- /*height: 150px;*/
- height: auto;
- flex-direction: row;
- justify-content: space-between;
- flex-wrap: wrap;
-}
+/*.tab-mission-control .waypoint {*/
+ /*padding-left: 19px;*/
+ /*padding-right: 19px;*/
+ /*!*padding-bottom: 10px;*!*/
+/*}*/
+/*.tab-mission-control .waypoint-left {*/
+ /*width: 54%;*/
+ /*float: left;*/
+ /*padding-right: 5px;*/
+/*}*/
+/*.tab-mission-control .waypoint-right{*/
+ /*width: 40%;*/
+ /*float: right;*/
+/*}*/
-.tab-mission-control .waypoint-left,
-.tab-mission-control .waypoint-right {
- width: 47%;
- float: none;
-}
-.tab-mission-control .btn.save_btn {
- display: flex;
- flex-direction: row;
- flex-wrap: wrap;
-}
-.tab-mission-control .btn.save_btn a{
- margin-top: 5px;
-}
+/*@media (max-width: 1236px) {*/
+ /*.tab-mission-control .waypoint-left {*/
+ /*width: 96%;*/
+ /*}*/
+ /*.tab-mission-control .waypoint-right{*/
+ /*width: 96%;*/
+ /*float: left;*/
+ /*padding-right: 19px;*/
+ /*}*/
+ /*.tab-mission-control .content_toolbar {*/
+ /*height: 240px;*/
+ /*}*/
+ /*.tab-mission-control .content_wrapper {*/
+ /*height: calc(100% - 240px);*/
+ /*}*/
+/*}*/
-.tab-mission-control .gui_box{
- width: 100%;
- clear: both;
- height: 90%;
-}
+/*!* Need test! *!*/
+/*.tab-mission-control .cf_column {*/
+ /*display: flex;*/
+ /*!*height: 150px;*!*/
+ /*height: auto;*/
+ /*flex-direction: row;*/
+ /*justify-content: space-between;*/
+ /*flex-wrap: wrap;*/
+/*}*/
-.tab-mission-control.toolbar_fixed_bottom{
- height: 100%;
-}
-/*.tab-mission-control .content_wrapper{*/
+/*.tab-mission-control .waypoint-left,*/
+/*.tab-mission-control .waypoint-right {*/
+ /*width: 47%;*/
+ /*float: none;*/
+/*}*/
+
+/*.tab-mission-control .btn.save_btn {*/
+ /*display: flex;*/
+ /*flex-direction: row;*/
+ /*flex-wrap: wrap;*/
+/*}*/
+
+/*.tab-mission-control .btn.save_btn a{*/
+ /*margin-top: 5px;*/
+/*}*/
+
+/*.tab-mission-control .gui_box{*/
+ /*width: 100%;*/
+ /*clear: both;*/
+ /*height: 90%;*/
+/*}*/
+
+/*.tab-mission-control.toolbar_fixed_bottom{*/
+ /*height: 100%;*/
+/*}*/
+/*!*.tab-mission-control .content_wrapper{*!*/
+ /*!*height: 100%;*!*/
+/*!*}*!*/
+/*#missionMap{*/
/*height: 100%;*/
/*}*/
-#missionMap{
- height: 100%;
-}
-@media (max-width: 1252px){
- .tab-mission-control .waypoint-left,
- .tab-mission-control .waypoint-right {
- width: 100%;
- }
- .tab-mission-control .waypoint-right{
- padding-right: 5px;
- margin-top: 5px;
- }
-}
+/*@media (max-width: 1252px){*/
+ /*.tab-mission-control .waypoint-left,*/
+ /*.tab-mission-control .waypoint-right {*/
+ /*width: 100%;*/
+ /*}*/
+ /*.tab-mission-control .waypoint-right{*/
+ /*padding-right: 5px;*/
+ /*margin-top: 5px;*/
+ /*}*/
+/*}*/
diff --git a/tabs/mission_control.html b/tabs/mission_control.html
index c7b04d66..518fb9e0 100644
--- a/tabs/mission_control.html
+++ b/tabs/mission_control.html
@@ -1,76 +1,99 @@
-