-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to set cache ? #222
Comments
like this: |
thanks!
…---Original---
From: "yeaper_yeo"<[email protected]>
Date: Thu, Apr 2, 2020 14:28 PM
To: "wasabeef/richeditor-android"<[email protected]>;
Cc: "goadsth"<[email protected]>;"Author"<[email protected]>;
Subject: Re: [wasabeef/richeditor-android] How to set cache ? (#222)
like this:
private void addCookies(String url) {
CookieManager cookieManager = CookieManager.getInstance();
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
cookieManager.removeSessionCookies(null);
PersistentCookieStore cookieStore = new PersistentCookieStore(UIUtils.getContext());
for (Cookie cookie : cookieStore.getCookies()) { //add cookie
cookieManager.setCookie(url, String.format("%s=%s", cookie.name(), cookie.value()));
}
cookieManager.flush();
}
}
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
I used editor.getSettings() to set web's cache,but it didn't work,it load pictures slowly everytime I reopened the same activity.
The text was updated successfully, but these errors were encountered: