mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 09:48:11 +00:00
GTableView: Add ability to hide individual columns at view-level.
Use this in IRCClient to hide the "sender" column in the server message view since everything in that view comes from the "Server" anyway.
This commit is contained in:
parent
d17a91f185
commit
951377e93e
5 changed files with 41 additions and 3 deletions
|
@ -60,6 +60,8 @@ GVariant IRCLogBufferModel::data(const GModelIndex& index, Role role) const
|
|||
}
|
||||
}
|
||||
if (role == Role::ForegroundColor) {
|
||||
if (index.column() == Column::Timestamp)
|
||||
return Color(Color::MidGray);
|
||||
if (index.column() == Column::Text)
|
||||
return m_log_buffer->at(index.row()).color;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue