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

Side by Side Diff: ui/base/ime/remote_input_method_win_unittest.cc

Issue 29943002: Limit display of the virtual keyboard to state changes triggered from a user gesture. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix ash_unittests Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « ui/base/ime/remote_input_method_win.cc ('k') | ui/keyboard/keyboard_controller.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "ui/base/ime/remote_input_method_win.h" 5 #include "ui/base/ime/remote_input_method_win.h"
6 6
7 #include <InputScope.h> 7 #include <InputScope.h>
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 virtual void OnBlur() OVERRIDE { 250 virtual void OnBlur() OVERRIDE {
251 } 251 }
252 virtual void OnCaretBoundsChanged(const TextInputClient* client) OVERRIDE { 252 virtual void OnCaretBoundsChanged(const TextInputClient* client) OVERRIDE {
253 } 253 }
254 virtual void OnTextInputStateChanged(const TextInputClient* client) OVERRIDE { 254 virtual void OnTextInputStateChanged(const TextInputClient* client) OVERRIDE {
255 ++on_text_input_state_changed_; 255 ++on_text_input_state_changed_;
256 } 256 }
257 virtual void OnInputMethodDestroyed(const InputMethod* client) OVERRIDE { 257 virtual void OnInputMethodDestroyed(const InputMethod* client) OVERRIDE {
258 ++on_input_method_destroyed_changed_; 258 ++on_input_method_destroyed_changed_;
259 } 259 }
260 virtual void OnShowImeIfNeeded() {
261 }
260 262
261 size_t on_text_input_state_changed_; 263 size_t on_text_input_state_changed_;
262 size_t on_input_method_destroyed_changed_; 264 size_t on_input_method_destroyed_changed_;
263 DISALLOW_COPY_AND_ASSIGN(MockInputMethodObserver); 265 DISALLOW_COPY_AND_ASSIGN(MockInputMethodObserver);
264 }; 266 };
265 267
266 typedef ScopedObserver<InputMethod, InputMethodObserver> 268 typedef ScopedObserver<InputMethod, InputMethodObserver>
267 InputMethodScopedObserver; 269 InputMethodScopedObserver;
268 270
269 TEST(RemoteInputMethodWinTest, RemoteInputMethodPrivateWin) { 271 TEST(RemoteInputMethodWinTest, RemoteInputMethodPrivateWin) {
(...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after
842 scoped_ptr<InputMethod> input_method(CreateRemoteInputMethodWin(&delegate_)); 844 scoped_ptr<InputMethod> input_method(CreateRemoteInputMethodWin(&delegate_));
843 input_method->AddObserver(&input_method_observer); 845 input_method->AddObserver(&input_method_observer);
844 846
845 EXPECT_EQ(0u, input_method_observer.on_input_method_destroyed_changed()); 847 EXPECT_EQ(0u, input_method_observer.on_input_method_destroyed_changed());
846 input_method.reset(); 848 input_method.reset();
847 EXPECT_EQ(1u, input_method_observer.on_input_method_destroyed_changed()); 849 EXPECT_EQ(1u, input_method_observer.on_input_method_destroyed_changed());
848 } 850 }
849 851
850 } // namespace 852 } // namespace
851 } // namespace ui 853 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/ime/remote_input_method_win.cc ('k') | ui/keyboard/keyboard_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698