Have you seen these password managers like Lastpass ? They allow you to copy-paste via Notification bar in Android. Typically, the sequence is like this..
- User in Lastpass presses a button, that puts two notifications in Notification Bar.
- User switches to any other application say a browser and when he has to insert username and password
- He opens notification bar, selecting the notifications from Lastpass pastes the username or password into the textfield of the browser.
Can anyone break this down into steps and guide me how I can implement this kind of a structure...
Thanks
Step #1: Raise a
Notification
, with agetBroadcast()
PendingIntent
pointing to aBroadcastReceiver
of yours.Step #2: In that
BroadcastReceiver
, copy the data to the clipboard usingClipboardManager
.