diff options
author | benadha <benawiadha@gmail.com> | 2021-02-02 15:46:35 +0700 |
---|---|---|
committer | benadha <benawiadha@gmail.com> | 2021-02-02 15:46:35 +0700 |
commit | a8674e4cb39609d3839e636b35a93eb9ee36a258 (patch) | |
tree | d6fb03f46cf92affc29e574556be0cf1c39581f8 /epy.py | |
parent | b74cf629f17cbd5e822998165f7d7a37171e6982 (diff) | |
download | epy-a8674e4cb39609d3839e636b35a93eb9ee36a258.tar.gz |
(probably) Useless: if totlines - y < rows
Diffstat (limited to 'epy.py')
-rwxr-xr-x | epy.py | 44 |
1 files changed, 15 insertions, 29 deletions
@@ -1951,36 +1951,22 @@ def reader(ebook, index, width, y, pctg, sect): SCREEN.clear() SCREEN.addstr(0, 0, countstring) SCREEN.refresh() - if totlines - y < rows: - if CFG["PageScrollAnimation"] and ANIMATE is not None: - for i in range(width+1): - curses.napms(1) - # to optimize performance - if i == width: - # to cleanup screen from animation residue - # actually only problematic for "next" animation - # but just to be safe - SCREEN.clear() - SCREEN.refresh() - if ANIMATE == "next": - pad.refresh(y, 0, 0, x+width-i, totlines-y, x+width) - elif ANIMATE == "prev": - pad.refresh(y, width-i-1, 0, x, totlines-y, x+i) - else: - pad.refresh(y, 0, 0, x, totlines-y, x+width) + if CFG["PageScrollAnimation"] and ANIMATE is not None: + for i in range(width+1): + curses.napms(1) + # to optimize performance + if i == width: + # to cleanup screen from animation residue + # actually only problematic for "next" animation + # but just to be safe + SCREEN.clear() + SCREEN.refresh() + if ANIMATE == "next": + pad.refresh(y, 0, 0, x+width-i, rows-1, x+width) + elif ANIMATE == "prev": + pad.refresh(y, width-i-1, 0, x, rows-1, x+i) else: - if CFG["PageScrollAnimation"] and ANIMATE is not None: - for i in range(width+1): - curses.napms(1) - if i == width: - SCREEN.clear() - SCREEN.refresh() - if ANIMATE == "next": - pad.refresh(y, 0, 0, x+width-i, rows-1, x+width) - elif ANIMATE == "prev": - pad.refresh(y, width-i-1, 0, x, rows-1, x+i) - else: - pad.refresh(y, 0, 0, x, rows-1, x+width) + pad.refresh(y, 0, 0, x, rows-1, x+width) ANIMATE = None LOCALSUMALLL = SUMALLLETTERS.value if MULTIPROC else SUMALLLETTERS |