mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-24 02:09:28 +00:00
LibGUI: Get rid of Model::ColumnMetadata and always use auto-sizing
Auto-sizing of view columns is now enabled by default. This removes the last remaining need for ColumnMetadata, so this patch gets rid of it.
This commit is contained in:
@@ -59,9 +59,6 @@ void AbstractTableView::select_all()
|
||||
|
||||
void AbstractTableView::update_column_sizes()
|
||||
{
|
||||
if (!m_size_columns_to_fit_content)
|
||||
return;
|
||||
|
||||
if (!model())
|
||||
return;
|
||||
|
||||
@@ -249,13 +246,7 @@ int AbstractTableView::column_width(int column_index) const
|
||||
{
|
||||
if (!model())
|
||||
return 0;
|
||||
auto& column_data = this->column_data(column_index);
|
||||
if (!column_data.has_initialized_width) {
|
||||
ASSERT(!m_size_columns_to_fit_content);
|
||||
column_data.has_initialized_width = true;
|
||||
column_data.width = model()->column_metadata(column_index).preferred_width;
|
||||
}
|
||||
return column_data.width;
|
||||
return column_data(column_index).width;
|
||||
}
|
||||
|
||||
void AbstractTableView::mousemove_event(MouseEvent& event)
|
||||
|
||||
Reference in New Issue
Block a user