私は mezzofanti OCR オープン ソースを使用しており、言語をダウンロードしようとしていますが、インターネットに接続していないと表示されます。デバイスのインターネット接続は開いていて動作しており、Android マニフェストでインターネット アクセス許可を持っています。
<uses-permission android:name="android.permission.INTERNET"/>
なぜ機能しないのかわかりませんか?
これは丸太猫です:
10-10 18:10:27.925: V/MLOG: Download.java:(12289): DownloadFile opened connection
10-10 18:10:27.930: V/MLOG: Download.java:(12289): java.io.FileNotFoundException: /sdcard/tessdata/temp/languages.txt: open failed: ENOENT (No such file or directory)
10-10 18:10:27.970: D/dalvikvm(12289): GC_FOR_ALLOC freed 94K, 3% free 10046K/10311K, paused 19ms
10-10 18:10:27.990: V/MLOG: OCR.java:(12289): GetLanguage(): eng
10-10 18:10:28.115: W/SurfaceView(12289): CHECK surface infomation creating=false formatChanged=false sizeChanged=false visible=false visibleChanged=true surfaceChanged=true realSizeChanged=false redrawNeeded=false left=false top=false
10-10 18:11:04.680: V/MLOG: Download.java:(12289): DownloadLanguageBrief (http://www.itwizard.ro/mezzolang/languages.txt)
10-10 18:11:05.005: V/MLOG: Download.java:(12289): DownloadFile opened connection
10-10 18:11:05.010: V/MLOG: Download.java:(12289): java.io.FileNotFoundException: /sdcard/tessdata/temp/languages.txt: open failed: ENOENT (No such file or directory)
10-10 18:11:05.080: V/MLOG: OCR.java:(12289): GetLanguage(): eng
10-10 18:11:05.100: D/dalvikvm(12289): GC_CONCURRENT freed 566K, 7% free 9897K/10567K, paused 7ms+3ms
10-10 18:15:07.385: E/WindowManager(12289): Activity com.itwizard.mezzofanti.PreferencesActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@4167e4a0 that was originally added here
10-10 18:15:07.385: E/WindowManager(12289): android.view.WindowLeaked: Activity com.itwizard.mezzofanti.PreferencesActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@4167e4a0 that was originally added here
10-10 18:15:07.385: E/WindowManager(12289): at android.view.ViewRootImpl.<init>(ViewRootImpl.java:386)
10-10 18:15:07.385: E/WindowManager(12289): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:267)
10-10 18:15:07.385: E/WindowManager(12289): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:215)
10-10 18:15:07.385: E/WindowManager(12289): at android.view.WindowManagerImpl$CompatModeWrapper.addView(WindowManagerImpl.java:140)
10-10 18:15:07.385: E/WindowManager(12289): at android.view.Window$LocalWindowManager.addView(Window.java:537)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.Dialog.show(Dialog.java:278)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.AlertDialog$Builder.show(AlertDialog.java:932)
10-10 18:15:07.385: E/WindowManager(12289): at com.itwizard.mezzofanti.PreferencesActivity.ShowAlert(PreferencesActivity.java:229)
10-10 18:15:07.385: E/WindowManager(12289): at com.itwizard.mezzofanti.PreferencesActivity.CreateDownloadableLangsSubMenu(PreferencesActivity.java:342)
10-10 18:15:07.385: E/WindowManager(12289): at com.itwizard.mezzofanti.PreferencesActivity.onCreate(PreferencesActivity.java:195)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.Activity.performCreate(Activity.java:4465)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1052)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1932)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1993)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread.handleRelaunchActivity(ActivityThread.java:3363)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread.access$700(ActivityThread.java:127)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1163)
10-10 18:15:07.385: E/WindowManager(12289): at android.os.Handler.dispatchMessage(Handler.java:99)
10-10 18:15:07.385: E/WindowManager(12289): at android.os.Looper.loop(Looper.java:137)
10-10 18:15:07.385: E/WindowManager(12289): at android.app.ActivityThread.main(ActivityThread.java:4507)
10-10 18:15:07.385: E/WindowManager(12289): at java.lang.reflect.Method.invokeNative(Native Method)
10-10 18:15:07.385: E/WindowManager(12289): at java.lang.reflect.Method.invoke(Method.java:511)
10-10 18:15:07.385: E/WindowManager(12289): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:790)
10-10 18:15:07.385: E/WindowManager(12289): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:557)
10-10 18:15:07.385: E/WindowManager(12289): at dalvik.system.NativeStart.main(Native Method)
10-10 18:15:07.440: V/MLOG: Download.java:(12289): DownloadLanguageBrief (http://www.itwizard.ro/mezzolang/languages.txt)
10-10 18:15:08.120: V/MLOG: Download.java:(12289): DownloadFile opened connection
10-10 18:15:08.120: V/MLOG: Download.java:(12289): java.io.FileNotFoundException: /sdcard/tessdata/temp/languages.txt: open failed: ENOENT (No such file or directory)
10-10 18:15:08.185: V/MLOG: OCR.java:(12289): GetLanguage(): eng
10-10 18:15:11.375: D/dalvikvm(12289): GC_CONCURRENT freed 173K, 5% free 10128K/10567K, paused 3ms+5ms