quotient-im / libQuotient

A Qt library to write cross-platform clients for Matrix
https://quotient-im.github.io/libQuotient/
GNU Lesser General Public License v2.1
132 stars 56 forks source link

@room notifications #107

Open KitsuneRal opened 6 years ago

KitsuneRal commented 6 years ago

While a naïve implementation would be dead simple (just add @room to the highlight-setting logic mentioned in #106), the proper implementation should follow the spec and Synapse/Riot behaviour described in the respective Google Doc. This implies dependency on #36 in the part of power_levels.

KitsuneRal commented 4 months ago

Now that power level events are a thing in the library, implementing this becomes as simple as checking whether the message (non-HTML) body contains @room and if it does, marking it for highlighting if and only if the event sender has the power level equal to or higher than that stated in the power level event (as returned by RoomPowerLevelsEvent::roomNotifications()).