Conversation
|
This PR is basically ready from my side. The last two points in the TODO above still need to be discussed. |
|
This had been on my wishlist for years. Thanks! A few things:
which is theoretically slower than the for loop because
|
|
e999bd0 to
9095204
Compare
|
Thanks for the pull request. Good work. I have made refactored the code to fix some issues and add improvements. It seems to be working fine on Android I have also changed the dynamic shortcuts directory to Also in future, please remove unused imports when you move around code before committing, had to spent time figuring out which import got removed when and fixing the commits. Also use same case for commit messages as being used in repo. I will merge this soon since need these changes for other work. |
|
Nice, thanks for your work. 👍🏼 |
9095204 to
9decc79
Compare
Co-authored-by: Fabian Thomas <fabian@fabianthomas.de> Co-authored-by: agnostic-apollo <agnosticapollo@gmail.com>
…le enumeration to `ShortcutUtils` Co-authored-by: Fabian Thomas <fabian@fabianthomas.de> Co-authored-by: agnostic-apollo <agnosticapollo@gmail.com>
…ctions to `ShortcutFile` and change shortcut path behaviour The `ShortcutFile` will now store the path instead of the file object This commit will also now pass absolute path of shortcuts when creating intents for shortcuts and widgets instead of canonical path. This will allow path expansion to be done during execution instead of at creation and if underlying symlink destination changes, new destination will be executed. There will still be a security check during execution to check if shortcut is under allowed directories. The shortcut label will now also be generated from absolute path instead of canonical path as mentioned in termux#59 Co-authored-by: Fabian Thomas <fabian@fabianthomas.de> Co-authored-by: agnostic-apollo <agnosticapollo@gmail.com>
Co-authored-by: agnostic-apollo <agnosticapollo@gmail.com> Co-authored-by: Fabian Thomas <fabian@fabianthomas.de>
…`Flow.Publisher` used in `TermuxWidgetControlsProviderService`
…it existed in recent apps stack and a shortcut was run from launcher
…and passing `0` in `ACTION_REFRESH_WIDGET` broadcast This also allows a way to fix occasional non-responsive widgets after app updates if `ACTION_APPWIDGET_UPDATE` was not sent/received by Termux:Widget app. This commit also adds logging to widget callbacks for debugging issues.
9decc79 to
10e3b47
Compare
|
You are welcome. Any issues that occur can be fixed in |
|
When will a new version be released that includes the feature? |
|
Sorry for the necro bump - but I do have the same question: How/Where can we obtain a new version providing the dynamic_shortcuts feature? |
|
You can use github action builds for now, github/fdroid release will be done in a few days. https://github.com/termux/termux-widget?tab=readme-ov-file#github |
|
The build artifact is not installable on my device - it claims that the FWIW: I get the same error (too old Android version) for Termux:Boot from F-Droid. Hoping its different for this then 🤞 |
Termux has to target old SDK, otherwise it would be same as any other terminal apps without packages. Newer target SDK enables stricter SELinux with withdraws ability to run executables on internal storage, which means no packages and user programs can be executed. You can dismiss dialog from Google Play Protect: tap on More details --> Install anyway |
|
Thanks for the hint. Turned out I enabled the screen password on my Onyx Boox Note Air - which was interferring with the |
This comment was marked as spam.
This comment was marked as spam.
This comment was marked as spam.
This comment was marked as spam.
|
And you decided to report it in a random PR of different plugin (unrelated to |

Closes #44
Closes termux/termux-app#1730
Current implementation:
Two new buttons in widget main view.
AOSP Android forces a limit of 10 shortcuts per app. One can change this limit with root permissions:
su -c 'settings put global shortcut_manager_constants max_shortcuts=1000'Todo:
~/.shortcuts)