Add ability to import otpauth uri from clipboard#1766
Merged
alexbakker merged 1 commit intobeemdevelopment:masterfrom Jan 21, 2026
Merged
Add ability to import otpauth uri from clipboard#1766alexbakker merged 1 commit intobeemdevelopment:masterfrom
alexbakker merged 1 commit intobeemdevelopment:masterfrom
Conversation
alexbakker
requested changes
Jan 21, 2026
Member
alexbakker
left a comment
There was a problem hiding this comment.
Looks good to me apart from 2 nitpicks!
Comment on lines
+12
to
+22
| if (clipboard == null) return null; | ||
|
|
||
| ClipData clip = clipboard.getPrimaryClip(); | ||
| if (clip == null || clip.getItemCount() == 0) return null; | ||
|
|
||
| ClipData.Item item = clip.getItemAt(0); | ||
| CharSequence cs = item.coerceToText(context); | ||
| if (cs == null) return null; | ||
|
|
||
| String text = cs.toString().trim(); | ||
| return text.isEmpty() ? null : text; |
Member
There was a problem hiding this comment.
I don't think we use this one line if statement style anywhere in the codebase. I'd prefer to keep it consistent.
app/src/main/java/com/beemdevelopment/aegis/ui/MainActivity.java
Outdated
Show resolved
Hide resolved
7a19cf9 to
170cd93
Compare
alexbakker
approved these changes
Jan 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds the ability to automatically prefill the EditEntryActivity if you have an otpauth uri on your clipboard. It works nicely, however the short "Aegis pasted from clipboard" toast sounds intrusive but there's nothing we can do about it.
Closes #950.