Quote:
Originally Posted by Morkl
I made an "EinkListView" class when experimenting, which is just a ListView that overrides all the methods that have updateMode overloads in Sony's android.view.View to use the updateMode ones:
|
In order to see more e-ink friendly applications and to get app designers on board, we need a replacement class for the usual WebView.
Being not an Android programmer, I looked around for generic code which could make it in such a replacement. So far I found these:
- The flicker-free page turn code used in cool reader:
credits to DairyKnight <dairyknight@gmail.com>
http://crengine.git.sourceforge.net/...ontroller.java
- Max Kammerer's code for his nook port of aarddict:
http:///github.com/max-kammerer/aarddict_nook
Code:
// from kbs - trook.projectsource code.
private final void pageUp() {
int cury = articleView2.getScrollY();
if (cury == 0) { return; }
int newy = cury - WEB_SCROLL_PX;
if (newy < 0) {
newy = 0;
}
articleView2.scrollTo(0, newy);
}
private final void pageDown() {
int cury = articleView2.getScrollY();
int hmax = articleView2.getContentHeight() - 200;
if (hmax < 0) {
hmax = 0;
}
int newy = cury + WEB_SCROLL_PX;
if (newy > hmax) {
newy = hmax;
}
if (cury != newy) {
articleView2.scrollTo(0, newy);
}
}
Cool reader has very low page turn flicker, the second code I could not see in action.
In an e-ink friendly app, there would be an option to select high-contrast skins and optimize page refreshes.
Once the keyword "e-ink" or "e-ink friendly" will show up in the Android Market, then we've got the ball rolling.