[ https://issues.apache.org/jira/browse/CB-5059?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14292964#comment-14292964 ]
ASF GitHub Bot commented on CB-5059: ------------------------------------ GitHub user dpogue opened a pull request: https://github.com/apache/cordova-android/pull/151 CB-5059 Add a CookieManager abstraction for pluggable webviews. Crosswalk and GeckoView implementations of CordovaWebView can provide their own ICordovaCookieManager implementation for plugins to use. /cc @infil00p & @agrieve If you think this is the correct way to go about this, I'll make an implementation for the Crosswalk engine and update the FileTransfer plugin. You can merge this pull request into a Git repository by running: $ git pull https://github.com/dpogue/cordova-android 4.0.x-cookies Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-android/pull/151.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #151 ---- commit 411f498a270aeebe33b4cca0bfe1d6176bb53d01 Author: Darryl Pogue <dvpdin...@gmail.com> Date: 2015-01-27T04:45:25Z CB-5059 Add a CookieManager abstraction for pluggable webviews. Crosswalk and GeckoView implementations of CordovaWebView can provide their own ICordovaCookieManager implementation for plugins to use. ---- > The android implementation of file transfer plugin should not depend on the > concrete class android.webkit.CookieManager > ----------------------------------------------------------------------------------------------------------------------- > > Key: CB-5059 > URL: https://issues.apache.org/jira/browse/CB-5059 > Project: Apache Cordova > Issue Type: Improvement > Components: Plugin File Transfer > Affects Versions: Master > Environment: cordova-android, git branch 3.0.x > Reporter: Junmin > Fix For: Master > > > The android implementation of file transfer plugin leverages the class > android.webkit.CookieManager, which depends on the concrete web > infrastructure android.webkit.WebView. This dependence ruins the portability > of the plugin. For example, it could not run on a substantial implementation > of CordovaWebView which based on a android third party component(such as > chromium for android). > Following is the crash log when initializing the CookieManager without > android.webkit.WebView: > I/dalvikvm(5006): java.lang.IllegalStateException: Call > CookieSyncManager::createInstance() or create a webview before using this > class > I/dalvikvm(5006): at > android.webkit.JniUtil.checkInitialized(JniUtil.java:44) > I/dalvikvm(5006): at > android.webkit.JniUtil.getDatabaseDirectory(JniUtil.java:65) > I/dalvikvm(5006): at > android.webkit.CookieManagerClassic.nativeGetCookie(Native Method) > I/dalvikvm(5006): at > android.webkit.CookieManagerClassic.getCookie(CookieManagerClassic.java:109) > I/dalvikvm(5006): at > android.webkit.CookieManagerClassic.getCookie(CookieManagerClassic.java:96) > I/dalvikvm(5006): at > org.apache.cordova.filetransfer.FileTransfer$4.run(FileTransfer.java:747) -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org