Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(78)

Side by Side Diff: chrome/browser/ui/ash/keyboard_controller_browsertest.cc

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/shell.h" 5 #include "ash/shell.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "chrome/browser/apps/app_browsertest_util.h" 8 #include "chrome/browser/apps/app_browsertest_util.h"
9 #include "chrome/browser/extensions/extension_service.h" 9 #include "chrome/browser/extensions/extension_service.h"
10 #include "chrome/browser/profiles/profile_manager.h" 10 #include "chrome/browser/profiles/profile_manager.h"
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 // Mock window.resizeTo that is expected to be called after navigate to a 72 // Mock window.resizeTo that is expected to be called after navigate to a
73 // new virtual keyboard. 73 // new virtual keyboard.
74 ui()->GetKeyboardWindow()->SetBounds(init_bounds); 74 ui()->GetKeyboardWindow()->SetBounds(init_bounds);
75 } 75 }
76 76
77 bool IsKeyboardVisible() const { 77 bool IsKeyboardVisible() const {
78 return keyboard::KeyboardController::GetInstance()->keyboard_visible(); 78 return keyboard::KeyboardController::GetInstance()->keyboard_visible();
79 } 79 }
80 80
81 private: 81 private:
82 scoped_ptr<ui::DummyTextInputClient> client; 82 std::unique_ptr<ui::DummyTextInputClient> client;
83 83
84 DISALLOW_COPY_AND_ASSIGN(VirtualKeyboardWebContentTest); 84 DISALLOW_COPY_AND_ASSIGN(VirtualKeyboardWebContentTest);
85 }; 85 };
86 86
87 // Test for crbug.com/404340. After enabling an IME in a different extension, 87 // Test for crbug.com/404340. After enabling an IME in a different extension,
88 // its virtual keyboard should not become visible if previous one is not. 88 // its virtual keyboard should not become visible if previous one is not.
89 IN_PROC_BROWSER_TEST_F(VirtualKeyboardWebContentTest, 89 IN_PROC_BROWSER_TEST_F(VirtualKeyboardWebContentTest,
90 EnableIMEInDifferentExtension) { 90 EnableIMEInDifferentExtension) {
91 gfx::Rect test_bounds(0, 0, 0, kKeyboardHeightForTest); 91 gfx::Rect test_bounds(0, 0, 0, kKeyboardHeightForTest);
92 FocusEditableNodeAndShowKeyboard(test_bounds); 92 FocusEditableNodeAndShowKeyboard(test_bounds);
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 ->GetVisibleViewportSize() 212 ->GetVisibleViewportSize()
213 .height(), 213 .height(),
214 non_ime_window_visible_height); 214 non_ime_window_visible_height);
215 // Ime window should have not be affected by virtual keyboard. 215 // Ime window should have not be affected by virtual keyboard.
216 EXPECT_EQ(ime_app_window->web_contents() 216 EXPECT_EQ(ime_app_window->web_contents()
217 ->GetRenderWidgetHostView() 217 ->GetRenderWidgetHostView()
218 ->GetVisibleViewportSize() 218 ->GetVisibleViewportSize()
219 .height(), 219 .height(),
220 ime_window_visible_height); 220 ime_window_visible_height);
221 } 221 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/chrome_shell_delegate.h ('k') | chrome/browser/ui/ash/launcher/arc_app_window_launcher_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698