From 6509162911c0ceb3658f6a7ece1a1d82c97b577e Mon Sep 17 00:00:00 2001 From: Shane Synan Date: Thu, 16 Jun 2016 21:16:40 -0400 Subject: [PATCH] Calculate senderHash for Action messages Fixes stylesheets not being able to reference sender hashes in Qss selectors. Allows the following to work: ChatLine::nick#action[sender="00"] { foreground: #e90d7f; } Just like this currently works: ChatLine::nick#plain[sender="00"] { foreground: #e90d7f; } --- src/uisupport/uistyle.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/uisupport/uistyle.cpp b/src/uisupport/uistyle.cpp index cba2edaf..f55b1831 100644 --- a/src/uisupport/uistyle.cpp +++ b/src/uisupport/uistyle.cpp @@ -667,10 +667,11 @@ QString UiStyle::mircToInternal(const QString &mirc_) UiStyle::StyledMessage::StyledMessage(const Message &msg) : Message(msg) { - if (type() == Message::Plain) + if (type() == Message::Plain || type() == Message::Action) _senderHash = 0xff; else - _senderHash = 0x00; // this means we never compute the hash for msgs that aren't plain + _senderHash = 0x00; + // This means we never compute the hash for msgs that aren't Plain or Action } -- 2.20.1