diff options
Diffstat (limited to 'Applications/IRCClient/IRCWindowListModel.cpp')
-rw-r--r-- | Applications/IRCClient/IRCWindowListModel.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Applications/IRCClient/IRCWindowListModel.cpp b/Applications/IRCClient/IRCWindowListModel.cpp index b6cf241ba5..b6aa3239a8 100644 --- a/Applications/IRCClient/IRCWindowListModel.cpp +++ b/Applications/IRCClient/IRCWindowListModel.cpp @@ -43,7 +43,12 @@ GTableModel::ColumnMetadata IRCWindowListModel::column_metadata(int column) cons GVariant IRCWindowListModel::data(const GModelIndex& index, Role) const { switch (index.column()) { - case Column::Name: return m_client.window_at(index.row()).name(); + case Column::Name: { + auto& window = m_client.window_at(index.row()); + if (!window.unread_count()) + return window.name(); + return String::format("%s (%d)\n", window.name().characters(), window.unread_count()); + } } ASSERT_NOT_REACHED(); } |