[ground_segment] settings: also set current value lable to ? when requesting update

This commit is contained in:
Felix Ruess
2014-12-08 13:01:54 +01:00
parent d5827f9be3
commit 2f8e003357
2 changed files with 9 additions and 3 deletions
+4 -2
View File
@@ -187,9 +187,11 @@ let one_setting = fun (i:int) (do_change:int -> float -> unit) packing dl_settin
let set_default = fun x ->
if not !modified then set_default x else () in
(* Update value *)
(* click current_value lable to request an update *)
let callback = fun _ ->
do_change i infinity; true in
do_change i infinity;
current_value#set_text "?";
true in
ignore (eb#event#connect#button_press ~callback);
(* Auto check button *)
+5 -1
View File
@@ -690,7 +690,11 @@ let get_setting = fun logging _sender vs ->
let vs = [ "index", List.assoc "index" vs;
"ac_id", Pprz.String ac_id ] in
Dl_Pprz.message_send dl_id "GET_SETTING" vs;
log logging ac_id "GET_SETTING" vs
log logging ac_id "GET_SETTING" vs;
(* mark the setting as not yet confirmed *)
let ac = Hashtbl.find aircrafts ac_id in
let idx = Pprz.int_of_value (List.assoc "index" vs) in
ac.dl_setting_values.(idx) <- infinity
(** Got a JUMP_TO_BLOCK, and send an BLOCK *)