fixed on refresh(reset origin and scaled), and move arrows to more,

smaller padding, to-do: scale restore not working
This commit is contained in:
open-trade
2020-12-24 10:44:44 +08:00
parent 5d5097eccd
commit 130104a475
2 changed files with 37 additions and 39 deletions

View File

@@ -159,12 +159,14 @@ class FfiModel with ChangeNotifier {
}
void handleSwitchDisplay(Map<String, dynamic> evt) {
var old = _pi.currentDisplay;
_pi.currentDisplay = int.parse(evt['display']);
_display.x = double.parse(evt['x']);
_display.y = double.parse(evt['y']);
_display.width = int.parse(evt['width']);
_display.height = int.parse(evt['height']);
FFI.cursorModel.updateDisplayOrigin(_display.x, _display.y);
if (old != _pi.currentDisplay)
FFI.cursorModel.updateDisplayOrigin(_display.x, _display.y);
notifyListeners();
}