2
0
mirror of https://github.com/koreader/koreader synced 2024-10-31 21:20:20 +00:00
Commit Graph

48 Commits

Author SHA1 Message Date
Martín Fernández
53234fcdc1
add hasSystemFonts device property (#7535)
Add system + user paths to the ReMarkable (has normal linux paths)
2021-04-19 09:04:31 +02:00
NiLuJe
3274183466 Minor Input & TimeVal cleanups
* Input: Don't create a new TimeVal object for input frame timestamps, just promote our existing table by assigning it the `TimeVal` metatable.
* TimeVal: Export (const) `zero` & `huge` TimeVal objects, because they're common enough in our codebase. (NOTE: not actually const, that's a Lua 5.4 feature ;p).
* GestureDetector: Explain the behavior of the `last_tevs` & `first_tevs` tables, and why one needs a new object and not the other.
* Speaking of, simplify the copy method for `first_tevs`, because it doesn't need to create a new TimeVal object, we can just reference the original, it's unique and re-assigned for each frame.
2021-04-16 22:12:15 +02:00
NiLuJe
bf6c0cdd6c
LuaSettings: Add a method to initialize a setting properly (#7371)
* LuaSettings/DocSettings: Updated readSetting API to allow proper initialization to default.
Use it to initialize tables, e.g., fixing corner-cases in readerFooter that could prevent settings from being saved.
(Fixes an issue reported on Gitter).
* LuaSettings/DocSettings: Add simpler API than the the flip* ones to toggle boolean settings.
* Update LuaSettings/DocSettigns usage throughout the codebase to use the dedicated boolean methods wher appropriate, and clean up some of the more mind-bending uses.
* FileChooser: Implement an extended default exclusion list (fix #2360)
* ScreenSaver: Refactor to avoid the pile of kludges this was threatening to become. Code should be easier to follow and use, and fallbacks now behave as expected (fix #4418).
2021-03-06 22:44:18 +01:00
yparitcher
dc964f3941
reader.lua: rework file/directory argument handling. (#7053)
platform: do not pass a directory on the command line.
The home directory will be properly set by Device.home_dir.

It was sometimes crashing when opened with no args.

Fixes: #7049
2021-01-07 20:38:10 +01:00
John Beard
0e494169f2
Keyboard input in InputText (#7037)
For text input, use the SDL events, which contain the decoded
strings.

Still handle keypresses for non-text input.
2020-12-30 22:26:40 +01:00
Martín Fernández
d914476973
sdl: resize FM (#6882)
Required after #6309.

Uses the same logic as in android (I cannot locate the PR right now). Tested on a mac.
2020-11-14 21:15:05 +01:00
ezdiy
ef8d2d0d6e
linuxfb: is_always_portrait must be passed to screen init() from all frontends. (#6712)
This is because fb driver should not be inspecting self.device for low level
caps anymore.

Fixes #6711
2020-09-25 13:20:02 +02:00
Martín Fernández
c7f77de72a
refactor thirdparty app integration (#6513)
* refactor thirdparty app integration
* Fix fora package name
2020-08-27 21:41:16 +02:00
Martín Fernández
b9ffb2e0d0
pocketbook: warmth lights support (#6531)
* also enables natural light controls for the emulator
2020-08-19 22:41:10 +02:00
Martín Fernández
d935ca6937
sdl: keep track of window position and size (#6495) 2020-08-13 13:20:49 +02:00
Martín Fdez
bdbebb9e08 standalone osx application bundle 2020-08-05 13:04:06 +02:00
Martín Fernández
ca21d1401a SDL: use platform as model for desktop computers, report battery if available 2020-07-22 14:41:11 +02:00
Martín Fdez
fca7f9e7d5 desktop/emulator 2020-07-21 00:23:05 +02:00
Martín Fernández
1adea4a497 Add macOS target
Co-authored-by: Jason Benwell <jbenwell@hotmail.com>
2020-07-11 01:29:49 +02:00
Martín Fdez
a376a52c3a easier user font paths with Device.home_dir 2020-07-10 15:16:38 +02:00
Martín Fernández
32207523b0
emulator: add fake network manager (#6314) 2020-06-26 20:47:09 +02:00
Martín Fernández
2e731dd4dd
[chore] Device abstraction (#6280)
* generic Device:info() function which returns the model

* add Device:canSuspend() and make it true in all devices that have suspend routines and the emulator

* also enable fake poweroff/reboot on the emulator

* add Device.home_dir

* add Device:hasExitOptions() and update menus & comments
2020-06-19 09:41:50 +02:00
Martín Fdez
3e3ddbfc4b desktop: don't show which results on console 2020-06-09 17:08:48 +02:00
Martín Fernández
3a4b5d3cab
desktop: add support for 3rd party dictionary apps (#6167) 2020-05-22 17:38:16 +02:00
Martín Fernández
5704f63bfc
fix openLink on linux (#6161) 2020-05-18 15:36:00 +02:00
Martín Fdez
8e831eb756 desktop: disable battery on touch menu and reader footer
isDesktop and isEmulator are now different entities
2020-04-13 19:24:28 +02:00
Frans de Jonge
f7861bc1eb
[feat] Add haptic feedback (#5380)
References <https://github.com/koreader/koreader/issues/5374>.
2019-09-29 15:42:05 +02:00
Frans de Jonge
7019ff15bd
[chore] Drop SDL 1.2 (#5324)
Depends on https://github.com/koreader/koreader-base/pull/963.

Also includes Initial import of <linux/rtc.h> related stuff https://github.com/koreader/koreader-base/pull/965
2019-09-05 23:30:13 +02:00
Frans de Jonge
a2dcfe9aec
[doc] Tag @todo, @fixme and @warning (#5244)
This commit standardizes the various todos around the code a bit in a manner recognized by LDoc.

Besides drawing more attention by being displayed in the developer docs, they're also extractable with LDoc on the command line:

```sh
ldoc --tags todo,fixme *.lua
```

However, whether that particular usage offers any advantage over other search tools is questionable at best.

* and some random beautification
2019-08-23 19:53:53 +02:00
Martín Fernández
3a957d71e3 [Desktop] Open writable font dir, toggle system+user/user fonts, fix openLink on mac (#5220)
Fixes #5093
2019-08-20 18:38:02 +02:00
Robert
803a143764 [sdl] Add support arrow key for next/prev page (#5149)
Close: #4997 
This PR add support arrow key and mouse scroll wheel for next/previous page.

- Document in page mode:

PageDown, Arrow down, Arrow right - go to next page
PageUp, Arrow up, arrow left - go to prev page
Mouse scroll wheel down - go to next page
Mouse scroll wheel up - go to prev page

- Document in scroll mode:

PageDown, Arrow right - go to next page
PageUp, Arrow, arrow left - go to prev page
Arrow down - scroll document down
Arrow up - scroll document up
Mouse scroll wheel down - scroll document down
Mouse scroll wheel up - scroll document up
2019-07-28 13:57:03 +02:00
Frans de Jonge
709207a621
[feat, UX] Add external link to Wallabag (#4863)
Offers a choice when Wallabag is available.
2019-03-31 19:19:07 +02:00
Frans de Jonge
b1ed2838c8
[UX] Add Device:openLink() stub for Linux SDL (#4822)
References #4821.
2019-03-20 16:58:32 +01:00
Frans de Jonge
728bb187fa
[UX] Gesture manager: add two-finger swipe left and right (#4815)
Also add Device:hasMultitouch() to control whether the configuration menu is shown.

Cf. #4727.
2019-03-19 20:18:38 +01:00
Frans de Jonge
2cbec1b54e
[fix] Add fake delayed pan to SDL scroll event (#4758)
Not actually delayed. Avoids a crash otherwise caused by #4666.
2019-03-08 19:39:50 +01:00
Frans de Jonge
8e5c1addf5
[feat] Update check (#4620)
The concept is quite simple: stick a file on the OTA server named
something like `koreader-appimage-latest-stable` (by analogy with
`koreader-cervantes-latest-stable.zsync`), which contains nothing
but a filename.

The difference with the zsync update is that the link is then launched
in the user's browser (AppImage) or DownloadManager (Android, not yet
implemented).

* Android hasOTAUpdate = no for the moment
2019-02-21 08:26:48 +01:00
Martín Fernández
04e17424d0 display network settings based on device capabilities + fix android basic network info 2019-02-18 14:32:35 +01:00
Martín Fernández
19d13b1876 [feat, Android] Add basic support for android eink refreshes on some rockchip devices (#4517)
Supported devices:

- Boyue T61 and *some* clones
- Boyue T62 and *some* clones
- Onyx C67
- Energy Sistem (which are in fact Boyue T62 clones). Was tested on a energy pro 4.

Others may work with the same controller too, but are disabled by default.

Requires https://github.com/koreader/koreader-base/pull/798
Requires https://github.com/koreader/android-luajit-launcher/pull/96

Fixes #4373 
Fixes #1613 (supported devices will show the "full refresh rate" option under eink settings. Others won't)

Related #4228 (need to add support for this specific device to work)
2019-02-01 09:18:27 +01:00
Martín Fernández
6de5927dc2 [build] Add support for Debian packages (#4434)
* Add support for Debian packages

* SDL: add device probe
2019-01-03 18:21:35 +01:00
Frans de Jonge
88dee4194d
[feat] SDL2: add window icon (new logo) (#3884)
Also update Ubuntu Touch icon

Fixes #2000, fixes #3858
2018-04-15 23:39:42 +02:00
Frans de Jonge
086ced07f9
[feat, UX] SDL: add Gtk3 filechooser (#3827)
The specifics for other implementations are easy to change in the backend.
2018-04-03 20:03:56 +02:00
Frans de Jonge
7f4be45d4e
[chore] Handle SDL_MOUSEWHEEL and less hackish SDL events (#3826) 2018-04-03 14:56:28 +02:00
Frans de Jonge
7e6de30889
[feat, UX] SDL2: drop file to open (#3793)
Includes:

* crengine: use cache files renamed as .cr3.keep https://github.com/koreader/crengine/pull/137
2018-03-22 19:13:54 +01:00
Frans de Jonge
f1aae6a03c [UX, fix] Redraw PdfDocument and DjvuDocument after resizing window 2018-03-19 21:19:23 +01:00
Frans de Jonge
24c0132744
[feat] SDL2: resize window (#3775)
References #1417 

Bumps base for https://github.com/koreader/koreader-base/pull/614

Also includes:
* Speedup loading from cache EPUB with many files https://github.com/koreader/crengine/pull/133
* Avoid rewriting cache file when no change were made https://github.com/koreader/crengine/pull/134
2018-03-18 21:32:39 +01:00
Frans de Jonge
06dfe4fb78
[feat] Add Device:hasClipboard() (#3465)
References https://github.com/koreader/koreader/issues/3441
2017-11-14 19:20:58 +01:00
poire-z
53f083f516 Allow for toggling color rendering
New menu item in Screen submenu.
hasColorScreen enabled for SDL device.
2017-10-02 00:10:29 +02:00
Robert
5258643a85 Add a date setting (#3234) 2017-09-18 19:04:36 +02:00
Robert
7f58a13626 Ability to setup clock (#3085)
* Ability to setup clock
2017-08-15 19:54:02 +02:00
Hzj_jie
7d2ed4c3d0 Move kobo auto-suspension logic out of UIManager (#2933) 2017-06-23 10:04:11 -07:00
Qingping Hou
f95ad00b9e feat: add logger module & rewrite kobo suspend script in lua 2017-01-02 19:52:09 -08:00
Qingping Hou
59e791db82 feat: support numeric input for keyboard only devices 2016-01-31 15:08:13 -08:00
chrox
a60544b1ad Koreader Ubuntu-touch port
Currently only tested on Ubuntu-touch emulator with framework
ubuntu-sdk-14.10 for armhf.
The ubuntu-touch port is binary compatible with the Kobo port
major changes in this PR are:
1. rename the emulator device to sdl device since both the emulator
and the ubuntu-touch target use libsdl to handle input/output.
2. ubuntu-touch app has no write access to the installation dir so
all write-outs should be in a seperate dir definded in `datastorage`.
2015-10-03 14:48:51 +08:00