Add --message option to kdeconnect-sms to pass a message. The user only needs to choose a recepient and the message will be sent. Useful for integration with 3rd party
apps, e.g. via Purpose
Details
- Reviewers
sredman - Group Reviewers
KDE Connect - Commits
- R224:fd99d84ead88: [SMS App] Allow passing a message via args
kdeconnect-sms --message "Hello World", choose chat, message is sent
Click another chat, no message sent
kdeconnect-sms without args, no message sent
Diff Detail
- Repository
- R224 KDE Connect
- Branch
- arcpatch-D17292
- Lint
Lint OK - Unit
No Unit Test Coverage - Build Status
Buildable 6116 Build 6134: arc lint + arc unit
Maybe instead of weirdly propagating an initial message it would make sense to have a sendMessage function?
I like the idea! It is very slick
- It works for me
- I think the operation should be cancel-able, maybe with an 'X' button on the InlineMessage banner to the right of "Choose recipient"
- I think it would be better to not auto-send the message, but just populate the text box and leaving the user to push "Send" as a kind of confirmation. I click wrong buttons all the time, I would like a chance to double-check, especially in this case where there is no undo and potentially real-money cost.
smsapp/qml/ConversationList.qml | ||
---|---|---|
37 ↗ | (On Diff #46660) | Spelling mistake: "Choose recipient" |
I think it would be better to not auto-send the message...
I'd second that as a good idea. We use a similar mechanism in GSConnect when sharing links from the browser extension, but also to support sms: scheme handlers which can have a "body" field. If you were ever to support sms: scheme handlers it could be a reasonable security risk.
Maybe instead of weirdly propagating an initial message it would make sense to have a sendMessage function?
Not sure I understand you. Where would that function be and who would call it? The information on the initial message needs to be available to both the ConversationList (for the select chat message) and the conversation (to fill the input field)
These work for me! I'll let you and Aleix figure out the other part; I'm happy with how it currently looks or with whatever Aleix is happy with.
Also don't forget to fix the spelling error I put in an inline comment in my first reply 😃