我按照wiki上有关apv-0.3.3的说明:选择了带有python命令的专业版,然后通过运行scripts / build_native.sh来使用当前的构建方法。没有问题或错误。 然后我从pdfview文件夹中将项目导入eclipse。我有一个错误说“返回类型与View.getRotation()不兼容”,所以我在PagesView.java中注释了getRotation()函数。当我在模拟器上运行项目时,每次打开PDF时,我在LogCat中都会出现以下错误:
09-05 18:46:33.008: E/AndroidRuntime(1652): FATAL EXCEPTION: main
09-05 18:46:33.008: E/AndroidRuntime(1652): java.lang.ExceptionInInitializerError
09-05 18:46:33.008: E/AndroidRuntime(1652): at cx.hell.android.pdfviewpro.OpenFileActivity.getPDF(OpenFileActivity.java:541)
09-05 18:46:33.008: E/AndroidRuntime(1652): at cx.hell.android.pdfviewpro.OpenFileActivity.startPDF(OpenFileActivity.java:502)
09-05 18:46:33.008: E/AndroidRuntime(1652): at cx.hell.android.pdfviewpro.OpenFileActivity.onCreate(OpenFileActivity.java:219)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.Activity.performCreate(Activity.java:4465)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1049)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1920)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.ActivityThread.access$600(ActivityThread.java:123)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.os.Handler.dispatchMessage(Handler.java:99)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.os.Looper.loop(Looper.java:137)
09-05 18:46:33.008: E/AndroidRuntime(1652): at android.app.ActivityThread.main(ActivityThread.java:4424)
09-05 18:46:33.008: E/AndroidRuntime(1652): at java.lang.reflect.Method.invokeNative(Native Method)
09-05 18:46:33.008: E/AndroidRuntime(1652): at java.lang.reflect.Method.invoke(Method.java:511)
09-05 18:46:33.008: E/AndroidRuntime(1652): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
09-05 18:46:33.008: E/AndroidRuntime(1652): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
09-05 18:46:33.008: E/AndroidRuntime(1652): at dalvik.system.NativeStart.main(Native Method)
09-05 18:46:33.008: E/AndroidRuntime(1652): Caused by: java.lang.UnsatisfiedLinkError: Couldn't load pdfview2: findLibrary returned null
09-05 18:46:33.008: E/AndroidRuntime(1652): at java.lang.Runtime.loadLibrary(Runtime.java:365)
09-05 18:46:33.008: E/AndroidRuntime(1652): at java.lang.System.loadLibrary(System.java:535)
09-05 18:46:33.008: E/AndroidRuntime(1652): at cx.hell.android.lib.pdf.PDF.<clinit>(PDF.java:25)
09-05 18:46:33.008: E/AndroidRuntime(1652): ... 17 more
我该如何解决这个问题?
谢谢!
答案 0 :(得分:0)
可能有点晚了
尝试移动PDF.Java
包中的cx.hell.android.lib.pdf