| Index: ui/base/models/simple_combobox_model.cc
|
| diff --git a/ui/base/models/simple_combobox_model.cc b/ui/base/models/simple_combobox_model.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..1b62e345b4eaadd99c772f2456410e5f7e5b67bc
|
| --- /dev/null
|
| +++ b/ui/base/models/simple_combobox_model.cc
|
| @@ -0,0 +1,30 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "ui/base/models/simple_combobox_model.h"
|
| +
|
| +namespace ui {
|
| +
|
| +SimpleComboboxModel::SimpleComboboxModel(
|
| + const std::vector<base::string16>& items)
|
| + : items_(items) {
|
| +}
|
| +
|
| +int SimpleComboboxModel::GetItemCount() const {
|
| + return items_.size();
|
| +}
|
| +
|
| +base::string16 SimpleComboboxModel::GetItemAt(int index) {
|
| + return items_[index];
|
| +}
|
| +
|
| +bool SimpleComboboxModel::IsItemSeparatorAt(int index) {
|
| + return items_[index].empty();
|
| +}
|
| +
|
| +int SimpleComboboxModel::GetDefaultIndex() const {
|
| + return 0;
|
| +}
|
| +
|
| +} // namespace ui
|
|
|