| Index: views/examples/combobox_example.h
|
| diff --git a/views/examples/combobox_example.h b/views/examples/combobox_example.h
|
| index d756eb53a8c472d31120eea8096516008e388690..3aad6ebcd84f2611ca035e5239358908f16f7c7f 100644
|
| --- a/views/examples/combobox_example.h
|
| +++ b/views/examples/combobox_example.h
|
| @@ -1,4 +1,4 @@
|
| -// Copyright (c) 2009 The Chromium Authors. All rights reserved.
|
| +// Copyright (c) 2010 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.
|
|
|
| @@ -8,6 +8,7 @@
|
|
|
| #include "app/combobox_model.h"
|
| #include "base/string_util.h"
|
| +#include "base/utf_string_conversions.h"
|
| #include "views/controls/combobox/combobox.h"
|
| #include "views/examples/example_base.h"
|
| #include "views/fill_layout.h"
|
| @@ -44,8 +45,8 @@ class ComboboxExample : public ExampleBase, public views::Combobox::Listener {
|
| return 10;
|
| }
|
|
|
| - virtual std::wstring GetItemAt(int index) {
|
| - return StringPrintf(L"Item %d", index);
|
| + virtual string16 GetItemAt(int index) {
|
| + return WideToUTF16Hack(StringPrintf(L"Item %d", index));
|
| }
|
|
|
| private:
|
| @@ -57,7 +58,8 @@ class ComboboxExample : public ExampleBase, public views::Combobox::Listener {
|
| int prev_index,
|
| int new_index) {
|
| PrintStatus(L"Selected: index=%d, label=%ls",
|
| - new_index, combo_box->model()->GetItemAt(new_index).c_str());
|
| + new_index, UTF16ToWideHack(
|
| + combo_box->model()->GetItemAt(new_index)).c_str());
|
| }
|
|
|
| // This test only control.
|
|
|