don't waste time when we aren't in dyn-view mode at all
This commit is contained in:
parent
286629c3e1
commit
c9db8c22a3
1 changed files with 5 additions and 6 deletions
|
@ -243,11 +243,10 @@ main_loop = func(id) {
|
||||||
if (id != loop_id) {
|
if (id != loop_id) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (mouse_button) {
|
if (cockpit_view and !panel_visible) {
|
||||||
freeze();
|
if (mouse_button) {
|
||||||
} else {
|
freeze();
|
||||||
var alive = elapsedN.getValue() > mouse_freeze;
|
} elsif (elapsedN.getValue() > mouse_freeze) {
|
||||||
if (cockpit_view and !panel_visible and alive) {
|
|
||||||
view_manager.apply();
|
view_manager.apply();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -280,8 +279,8 @@ var view_manager = nil;
|
||||||
|
|
||||||
var cockpit_view = nil;
|
var cockpit_view = nil;
|
||||||
var panel_visible = nil;
|
var panel_visible = nil;
|
||||||
var mouse_mode = nil;
|
|
||||||
var elapsedN = nil;
|
var elapsedN = nil;
|
||||||
|
var mouse_mode = nil;
|
||||||
var mouse_freeze = 0;
|
var mouse_freeze = 0;
|
||||||
var mouse_button = nil;
|
var mouse_button = nil;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue