Add Android native port for OpenLessAdd Android native port for OpenLess#278
Add Android native port for OpenLessAdd Android native port for OpenLess#278ccbili30-collab wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 059b5067c6
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| if (System.currentTimeMillis() - bubble.downAt >= LONG_PRESS_CANCEL_MS) { | ||
| coordinator.cancel(); | ||
| } else { coordinator.toggle(); } |
There was a problem hiding this comment.
Record press time before deciding cancel vs toggle
A normal tap on the floating bubble will be treated as a long-press here, so coordinator.toggle() is effectively unreachable in non-drag taps. downAt is only updated in MicBubbleView.onTouchEvent, but touch events are already consumed by the OnTouchListener (setOnTouchListener(this::onBubbleTouch) returns true), so downAt remains 0 and System.currentTimeMillis() - bubble.downAt is always greater than LONG_PRESS_CANCEL_MS. This makes the main start/stop dictation interaction fail in production.
Useful? React with 👍 / 👎.
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 059b5067c6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (System.currentTimeMillis() - bubble.downAt >= LONG_PRESS_CANCEL_MS) { | ||
| coordinator.cancel(); |
There was a problem hiding this comment.
Capture press start time in bubble touch handling
A normal tap on the floating bubble is always interpreted as a long press, so coordinator.toggle() is never reached. onBubbleTouch compares System.currentTimeMillis() - bubble.downAt, but downAt is only assigned in MicBubbleView.onTouchEvent; that method does not run here because the installed OnTouchListener consumes every event (return true). As a result, downAt stays at its default (0) and every non-drag tap triggers cancel instead of start/stop dictation.
Useful? React with 👍 / 👎.
|
我们可能会把你的 PR 合并到新分支,在此之前请先解决 Codex 以及 AI agent 所提出的问题。 |
|
您好,我看到您已经很久没有继续跟进这条PR了,我认为您实现的功能质量很好,因此我决定跟进您的PR。解决了此前未能解决的问题。 |
User description
Summary
This PR adds a native Android port of OpenLess under
openless-android/.The Android implementation ports the desktop dictation pipeline into Java/Android-native components, including:
Included
openless-android/Validation
Verified locally with:
.\build.ps1.\verify.ps1Also completed one emulator validation round for:
Notes
This is a large additive PR because the Android port is introduced as a new directory rather than modifying the existing desktop implementation.
Known remaining work is mainly around:
PR Type
Enhancement, Documentation
Description
Android port with build/verify/deploy scripts and version sync
Main dictation flow: floating trigger, mic recording, streaming ASR
Polish, translation, and IME insertion with clipboard fallback
History, dictionary, settings, Q&A, and error detail screens
Diagram Walkthrough
File Walkthrough
3 files
PowerShell build script for APK generationADB deployment script for device installVersion sync script from desktop app1 files
APK verification script checking signing and permissions15 files
Main UI with dictation, history, settings, and tools sectionsQ&A panel with voice question and streaming answersLLM and ASR configuration validation utilitiesSettings screen for providers and preferencesDictionary management for hotwordsForeground service for floating dictation triggerDetail view for individual history entriesLLM model listing activityAudio recording and PCM buffer managementStreaming ASR via Volcengine WebSocketWhisper-compatible ASR via HTTPPolish/translation using OpenAI-compatible APIIME and clipboard insertion helperPersistent dictation history storageSecure settings storage with Android Keystore1 files
Error detail screen for troubleshooting36 files