git-svn-id: http://www.neo1973-germany.de/svn@138 46df4e5c-bc4e-4628-a0fc-830ba316316d
This commit is contained in:
parent
cd8cc144aa
commit
c882ebc859
2 changed files with 48 additions and 2 deletions
|
@ -6,7 +6,8 @@
|
|||
// Signal1: "dialer_send"
|
||||
// Parameter1.1: $"keynumber"
|
||||
// Parameter1.2: "backspace"
|
||||
// Parameter1.2: "dial"
|
||||
// Parameter1.3: "clear"
|
||||
// Parameter1.4: "dial"
|
||||
|
||||
data {
|
||||
item: "author" "thomasg [thomas (a) gstaedtner (.) net]";
|
||||
|
@ -167,7 +168,34 @@ collections {
|
|||
group {
|
||||
name: "pyneo/dialer/main";
|
||||
min: 100 100;
|
||||
max: 800 800;
|
||||
max: 1000 1000;
|
||||
script {
|
||||
public flag_timer_running;
|
||||
public flag_backspace_sent;
|
||||
public timer_id;
|
||||
|
||||
public clear_timer() {
|
||||
set_int(flag_backspace_sent, 0);
|
||||
set_int(flag_timer_running, 1);
|
||||
timer_id = timer(2, "clear_send", 1);
|
||||
}
|
||||
|
||||
public clear_send() {
|
||||
if (get_int(flag_backspace_sent) == 0) {
|
||||
set_int(flag_timer_running, 0);
|
||||
run_program(PROGRAM:"numberdisplay_backspace_emit_signal_clear");
|
||||
}
|
||||
}
|
||||
|
||||
public backspace_send() {
|
||||
if (get_int(flag_timer_running) == 1) {
|
||||
cancel_timer(get_int(timer_id));
|
||||
set_int(flag_backspace_sent, 1);
|
||||
run_program(PROGRAM:"numberdisplay_backspace_emit_signal_backspace");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
parts {
|
||||
part {
|
||||
name: "background";
|
||||
|
@ -366,8 +394,26 @@ collections {
|
|||
name: "numberdisplay_backspace_area_signal_emit";
|
||||
signal: "mouse,down,*";
|
||||
source: "numberdisplay_backspace_area";
|
||||
script {
|
||||
clear_timer();
|
||||
}
|
||||
}
|
||||
program {
|
||||
name: "numberdisplay_backspace_area_signal_stop";
|
||||
signal: "mouse,up,*";
|
||||
source: "numberdisplay_backspace_area";
|
||||
script {
|
||||
backspace_send();
|
||||
}
|
||||
}
|
||||
program {
|
||||
name: "numberdisplay_backspace_emit_signal_backspace";
|
||||
action: SIGNAL_EMIT "dialer_send" "backspace";
|
||||
}
|
||||
program {
|
||||
name: "numberdisplay_backspace_emit_signal_clear";
|
||||
action: SIGNAL_EMIT "dialer_send" "clear";
|
||||
}
|
||||
program {
|
||||
name: "numberdisplay_backspace_area_animation_start";
|
||||
signal: "mouse,down,*";
|
||||
|
|
Binary file not shown.
Loading…
Reference in a new issue