mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-27 23:09:08 +00:00
LibGUI: Rename GTableModel => GModel.
This commit is contained in:
parent
9d4b4c2689
commit
994cf10b3e
Notes:
sideshowbarker
2024-07-19 14:58:14 +09:00
Author: https://github.com/awesomekling
Commit: 994cf10b3e
23 changed files with 105 additions and 105 deletions
|
@ -1,5 +1,5 @@
|
|||
#include <LibGUI/GTableView.h>
|
||||
#include <LibGUI/GTableModel.h>
|
||||
#include <LibGUI/GModel.h>
|
||||
#include <LibGUI/GScrollBar.h>
|
||||
#include <SharedGraphics/Painter.h>
|
||||
#include <Kernel/KeyCode.h>
|
||||
|
@ -13,7 +13,7 @@ GTableView::~GTableView()
|
|||
{
|
||||
}
|
||||
|
||||
void GTableView::set_model(RetainPtr<GTableModel>&& model)
|
||||
void GTableView::set_model(RetainPtr<GModel>&& model)
|
||||
{
|
||||
if (model.ptr() == m_model.ptr())
|
||||
return;
|
||||
|
@ -162,7 +162,7 @@ void GTableView::paint_event(GPaintEvent& event)
|
|||
if (is_selected_row)
|
||||
text_color = Color::White;
|
||||
else
|
||||
text_color = m_model->data(cell_index, GTableModel::Role::ForegroundColor).to_color(Color::Black);
|
||||
text_color = m_model->data(cell_index, GModel::Role::ForegroundColor).to_color(Color::Black);
|
||||
painter.draw_text(cell_rect, data.to_string(), font, column_metadata.text_alignment, text_color);
|
||||
}
|
||||
x_offset += column_width + horizontal_padding() * 2;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue