Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Donald Haase
Cockatrice
Commits
2a78d157
Commit
2a78d157
authored
Jan 29, 2015
by
Matt Lowe
Browse files
Taskbar attention when mentioned
parent
739ca6a0
Changes
1
Hide whitespace changes
Inline
Side-by-side
cockatrice/src/chatview.cpp
View file @
2a78d157
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
#include
<QScrollBar>
#include
<QScrollBar>
#include
<QMouseEvent>
#include
<QMouseEvent>
#include
<QDesktopServices>
#include
<QDesktopServices>
#include
<QApplication>
#include
"chatview.h"
#include
"chatview.h"
#include
"user_level.h"
#include
"user_level.h"
#include
"user_context_menu.h"
#include
"user_context_menu.h"
...
@@ -196,6 +197,7 @@ void ChatView::appendMessage(QString message, QString sender, UserLevelFlags use
...
@@ -196,6 +197,7 @@ void ChatView::appendMessage(QString message, QString sender, UserLevelFlags use
if
(
message
.
toLower
().
startsWith
(
mention
))
{
if
(
message
.
toLower
().
startsWith
(
mention
))
{
cursor
.
insertText
(
"@"
+
userName
,
mentionFormat
);
cursor
.
insertText
(
"@"
+
userName
,
mentionFormat
);
message
=
message
.
mid
(
mention
.
size
());
message
=
message
.
mid
(
mention
.
size
());
QApplication
::
alert
(
this
);
}
}
// another user has been mentioned
// another user has been mentioned
else
{
else
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment