print stack

Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
fufesou
2023-02-26 23:29:36 +08:00
parent 17f1c18c92
commit 0a52d64900
2 changed files with 21 additions and 6 deletions

View File

@@ -803,7 +803,9 @@ class CanvasModel with ChangeNotifier {
dyOffset = (y - dh * (y / size.height) - _y).toInt();
}
} catch (e) {
// Unhandled Exception: Unsupported operation: Infinity or NaN toInt
debugPrintStack(
label:
'(x,y) ($x,$y), (_x,_y) ($_x,$_y), _scale $_scale, display size (${getDisplayWidth()},${getDisplayHeight()}), size $size, , $e');
return;
}