Notification quick reply DBus API
Zander Brown
zbrown at gnome.org
Wed Feb 5 16:21:49 UTC 2020
Hey
> You mean I add an "inline-reply" action with an appropriate label and
> then add this hint which then tells it to actually really make it an
> inline reply?
No, you just don't have an action because you don't need one
> I think we also should have an inline-reply-placeholder-text or similar
hint which governs what the text field should say, e.g. "Type a reply...".
Well instead of "quick-reply": 1 you could do "quick-reply": "Type a reply..."
as the presence of the hint already sets it if-you-see-what-i-mean
> Everybody does that anyway.
Have you got an example? I have never seen that done anywhere (what are these
actions even doing?)
> Sure, you'd have to update your app either way, so changing action
> handling or adding a new handler doesn't really make a difference, does it?
Right, but I was meaning the platform libraries rather than apps (i.e.
GNotification doesn't have a can-inline-replay property)
> * Add an action named inline-reply like normal.
> * Add a hint "inline-reply: true" which will tell the server to treat
> this action special
These where two different approaches really
> * If the server doesn't support it, it will just invoke it as a regular
> action
Right if you've added some magic action and the server doesn't know it's magic
it will just be presented as a button (and possibly clicked) like any other
> * If the server supports it, it will invoke it as "inline-reply::Reply
> text goes here" which the app will then have to fish out the text, which
> it will do since it was explicitly coded to send this hint?
... if we go for the magic action approach yes
Really we have two different proposals here
Proposal 1: Magic Action
* Add "inline-reply" capability
* When "inline-reply" supported
* Add the magic ("inline-reply", "Type a reply...") action
* User submits reply
* Application gets ActionInvoked(id, "inline-reply::the-entered-text")
Proposal 2: Hint
* Add "inline-reply" capability
* Add org.freedesktop.Notification.Reply(id, message)
* Regardless of "inline-reply" support
* Add the "inline-reply": "Type a reply..." hint
* User submits reply
* Application gets Reply(id, "the-entered-text")
Must admit I'm starting to favour the hint
--
Zander Brown <zbrown at gnome.org>
Maintainer:
Dia Diagram Editor
King's Cross / KGX
GNOME Design Tooling (Icon Preview, Colour Palette)
Co-Maintainer:
GNOME Clocks
en_GB Translation Team
Me ≢ GNOME
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/xdg/attachments/20200205/cfce38ad/attachment.sig>
More information about the xdg
mailing list