4
下面的代碼拋出異常"type '([int]) => void' is not a subtype of type 'RequestAnimationFrameCallback' of 'callback'."
如何在Dart中使用animationFrame?
import 'dart:html';
void main() {
window.animationFrame.then((time) => print("test"));
}
如果我改變window.animationFrame.then
到window.requestAnimationFrame
,一切正常。我誤解了Dart期貨如何運作?
好的,已提交:http://code.google.com/p/dart/issues/detail?id = 9235 – Sydius 2013-03-18 16:08:26
確認,我也收到此錯誤。 – 2013-03-18 19:51:18