diff options
author | Andreas Kling <kling@serenityos.org> | 2020-05-21 19:52:04 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-05-21 19:55:44 +0200 |
commit | 2adb0a07e53695e1f636384a3323aba828d48e52 (patch) | |
tree | d1affc27e33ec70daaa4d317d39ee2c6c781415b /MenuApplets/ClipboardHistory | |
parent | c666c251c89f9d63a4855494cc2cf0f92e524db0 (diff) | |
download | serenity-2adb0a07e53695e1f636384a3323aba828d48e52.zip |
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.
Diffstat (limited to 'MenuApplets/ClipboardHistory')
-rw-r--r-- | MenuApplets/ClipboardHistory/ClipboardHistoryModel.cpp | 12 | ||||
-rw-r--r-- | MenuApplets/ClipboardHistory/ClipboardHistoryModel.h | 1 |
2 files changed, 0 insertions, 13 deletions
diff --git a/MenuApplets/ClipboardHistory/ClipboardHistoryModel.cpp b/MenuApplets/ClipboardHistory/ClipboardHistoryModel.cpp index a6c0179c47..84f89cc764 100644 --- a/MenuApplets/ClipboardHistory/ClipboardHistoryModel.cpp +++ b/MenuApplets/ClipboardHistory/ClipboardHistoryModel.cpp @@ -47,18 +47,6 @@ String ClipboardHistoryModel::column_name(int column) const } } -GUI::Model::ColumnMetadata ClipboardHistoryModel::column_metadata(int column) const -{ - switch (column) { - case Column::Data: - return { 200 }; - case Column::Type: - return { 100 }; - default: - ASSERT_NOT_REACHED(); - } -} - GUI::Variant ClipboardHistoryModel::data(const GUI::ModelIndex& index, Role) const { auto& data_and_type = m_history_items[index.row()]; diff --git a/MenuApplets/ClipboardHistory/ClipboardHistoryModel.h b/MenuApplets/ClipboardHistory/ClipboardHistoryModel.h index 5f1357563f..6229234e55 100644 --- a/MenuApplets/ClipboardHistory/ClipboardHistoryModel.h +++ b/MenuApplets/ClipboardHistory/ClipboardHistoryModel.h @@ -48,7 +48,6 @@ public: private: virtual int row_count(const GUI::ModelIndex&) const override { return m_history_items.size(); } virtual String column_name(int) const override; - virtual GUI::Model::ColumnMetadata column_metadata(int column) const override; virtual int column_count(const GUI::ModelIndex&) const override { return Column::__Count; } virtual GUI::Variant data(const GUI::ModelIndex&, Role = Role::Display) const override; virtual void update() override; |