就跟百度或高德地图一样打开后显示当前位置,我从http://blog.csdn.net/supermapsupport/article/details/50820418#reply
中的评论里下载了demo,里面没有jar包,然后我去官网下载了SuperMap iMobile 8C SP2 for Android_802_8623,拷贝了里面的jar跟so文件,
m_wokspace = new Workspace();
DatasourceConnectionInfo dsInfo = new DatasourceConnectionInfo();
dsInfo.setServer(CLOUD_URL);
dsInfo.setEngineType(EngineType.SuperMapCloud);
dsInfo.setAlias("SuperMapCloud");
Datasource ds = m_wokspace.getDatasources().open(dsInfo);
ds获取一直为null,注释掉后运行,就报下面这个错误
06-02 14:56:46.630: E/Surface(15579): Surface::lock failed, already locked
06-02 14:56:46.630: E/SurfaceHolder(15579): Exception locking surface
06-02 14:56:46.630: E/SurfaceHolder(15579): java.lang.IllegalArgumentException
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Surface.nativeLockCanvas(Native Method)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Surface.lockCanvas(Surface.java:236)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.SurfaceView$4.internalLockCanvas(SurfaceView.java:807)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.SurfaceView$4.lockCanvas(SurfaceView.java:768)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControl1.c(MapControl1.java:295)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControl1.refreshCallback(MapControl1.java:938)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControlNative.jni_SetSize(Native Method)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControl1.a(MapControl1.java:1084)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControl1.c(MapControl1.java:305)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.supermap.mapping.MapControl1$3.surfaceCreated(MapControl1.java:276)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.SurfaceView.updateWindow(SurfaceView.java:571)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.SurfaceView.access$000(SurfaceView.java:86)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.SurfaceView$3.onPreDraw(SurfaceView.java:175)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.ViewTreeObserver.dispatchOnPreDraw(ViewTreeObserver.java:833)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1860)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1004)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5481)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Choreographer.doCallbacks(Choreographer.java:562)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Choreographer.doFrame(Choreographer.java:532)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.os.Handler.handleCallback(Handler.java:730)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.os.Handler.dispatchMessage(Handler.java:92)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.os.Looper.loop(Looper.java:137)
06-02 14:56:46.630: E/SurfaceHolder(15579): at android.app.ActivityThread.main(ActivityThread.java:5136)
06-02 14:56:46.630: E/SurfaceHolder(15579): at java.lang.reflect.Method.invokeNative(Native Method)
06-02 14:56:46.630: E/SurfaceHolder(15579): at java.lang.reflect.Method.invoke(Method.java:525)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:737)
06-02 14:56:46.630: E/SurfaceHolder(15579): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
06-02 14:56:46.630: E/SurfaceHolder(15579): at dalvik.system.NativeStart.main(Native Method)
我想问下是什么原因,或者有什么可以运行的demo