Monodroid horizo​​ntalscrollview在滚动时经常抛出错误

时间:2013-08-22 20:09:42

标签: c# android xamarin.android xamarin horizontalscrollview

我使用monodroid并将horizo​​ntalscrollview作为RelativeLayout的唯一子项。我在代码中这样做,它在滚动的前几秒工作正常,然后它冻结并给我以下错误:

[SurfaceTextureClient] Fence::wait failed (Interrupted system call)
[ViewRootImpl] Could not lock surface
[ViewRootImpl] java.lang.IllegalArgumentException
[ViewRootImpl]  at android.view.Surface.nativeLockCanvas(Native Method)
[ViewRootImpl]  at android.view.Surface.lockCanvas(Surface.java:452)
[ViewRootImpl]  at android.view.ViewRootImpl.drawSoftware(ViewRootImpl.java:2214)
[ViewRootImpl]  at android.view.ViewRootImpl.draw(ViewRootImpl.java:2177)
[ViewRootImpl]  at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2045)
[ViewRootImpl]  at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1854)
[ViewRootImpl]  at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:989)
[ViewRootImpl]  at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:4351)
[ViewRootImpl]  at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
[ViewRootImpl]  at android.view.Choreographer.doCallbacks(Choreographer.java:562)
[ViewRootImpl]  at android.view.Choreographer.doFrame(Choreographer.java:532)
[ViewRootImpl]  at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
[ViewRootImpl]  at android.os.Handler.handleCallback(Handler.java:725)
[ViewRootImpl]  at android.os.Handler.dispatchMessage(Handler.java:92)
[ViewRootImpl]  at android.os.Looper.loop(Looper.java:137)
[ViewRootImpl]  at android.app.ActivityThread.main(ActivityThread.java:5227)
[ViewRootImpl]  at java.lang.reflect.Method.invokeNative(Native Method)
[ViewRootImpl]  at java.lang.reflect.Method.invoke(Method.java:511)
[ViewRootImpl]  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795)
[ViewRootImpl]  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:562)
[ViewRootImpl]  at dalvik.system.NativeStart.main(Native Method)

我有点困惑,因为这是一个非常简单的活动,我找不到这个滚动问题的原因。

1 个答案:

答案 0 :(得分:1)

我发现只有在调试中运行项目时才会发生这种情况。我相信这是当前版本的Xamarin(4.0.12 Build 3)的一个问题