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

Side by Side Diff: content/browser/renderer_host/render_widget_host_impl.h

Issue 1999423002: tyrbot test for commitText (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: SetHasCompositionTextToTrue Created 4 years, 3 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 // (on Windows); 361 // (on Windows);
362 // * when it receives a "preedit_changed" signal of GtkIMContext (on Linux); 362 // * when it receives a "preedit_changed" signal of GtkIMContext (on Linux);
363 // * when markedText of NSTextInput is called (on Mac). 363 // * when markedText of NSTextInput is called (on Mac).
364 void ImeSetComposition( 364 void ImeSetComposition(
365 const base::string16& text, 365 const base::string16& text,
366 const std::vector<blink::WebCompositionUnderline>& underlines, 366 const std::vector<blink::WebCompositionUnderline>& underlines,
367 const gfx::Range& replacement_range, 367 const gfx::Range& replacement_range,
368 int selection_start, 368 int selection_start,
369 int selection_end); 369 int selection_end);
370 370
371 // Finishes an ongoing composition with the specified text. 371 // Deletes the ongoing composition if any, inserts the specified text, and
372 // A browser should call this function: 372 // moves the cursor.
373 // A browser should call this function or ImeFinishComposingText:
373 // * when it receives a WM_IME_COMPOSITION message with a GCS_RESULTSTR flag 374 // * when it receives a WM_IME_COMPOSITION message with a GCS_RESULTSTR flag
374 // (on Windows); 375 // (on Windows);
375 // * when it receives a "commit" signal of GtkIMContext (on Linux); 376 // * when it receives a "commit" signal of GtkIMContext (on Linux);
376 // * when insertText of NSTextInput is called (on Mac). 377 // * when insertText of NSTextInput is called (on Mac).
377 void ImeConfirmComposition(const base::string16& text, 378 void ImeCommitText(const base::string16& text,
378 const gfx::Range& replacement_range, 379 const gfx::Range& replacement_range,
379 bool keep_selection); 380 int relative_cursor_pos);
381
382 // Finishes an ongoing composition.
383 // A browser should call this function or ImeCommitText:
384 // * when it receives a WM_IME_COMPOSITION message with a GCS_RESULTSTR flag
385 // (on Windows);
386 // * when it receives a "commit" signal of GtkIMContext (on Linux);
387 // * when insertText of NSTextInput is called (on Mac).
388 void ImeFinishComposingText(bool keep_selection);
380 389
381 // Cancels an ongoing composition. 390 // Cancels an ongoing composition.
382 void ImeCancelComposition(); 391 void ImeCancelComposition();
383 392
384 bool ignore_input_events() const { 393 bool ignore_input_events() const {
385 return ignore_input_events_; 394 return ignore_input_events_;
386 } 395 }
387 396
388 // Whether forwarded WebInputEvents should be dropped. 397 // Whether forwarded WebInputEvents should be dropped.
389 bool ShouldDropInputEvents() const; 398 bool ShouldDropInputEvents() const;
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after
841 #endif 850 #endif
842 851
843 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_; 852 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_;
844 853
845 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); 854 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);
846 }; 855 };
847 856
848 } // namespace content 857 } // namespace content
849 858
850 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 859 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/ime_adapter_android.cc ('k') | content/browser/renderer_host/render_widget_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698