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

Unified Diff: content/browser/browser_plugin/browser_plugin_guest.cc

Issue 1889313002: Revert of Browser Side Text Input State Tracking for OOPIF (Manual). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_plugin/browser_plugin_guest.cc
diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc
index 2b8e20dd248232d50bffe0bdf94a5d5457d210d7..3fc47c34c2e7d67e675a880cc84f8f091f5a5679 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.cc
+++ b/content/browser/browser_plugin/browser_plugin_guest.cc
@@ -36,7 +36,6 @@
#include "content/common/host_shared_bitmap_manager.h"
#include "content/common/input_messages.h"
#include "content/common/site_isolation_policy.h"
-#include "content/common/text_input_state.h"
#include "content/common/view_messages.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_plugin_guest_manager.h"
@@ -777,14 +776,6 @@ void BrowserPluginGuest::OnDetach(int browser_plugin_instance_id) {
if (!attached())
return;
- // The BrowserPluginGuest loses the link to |owner_web_contents_|. Therefore,
- // the RenderWidgetHostViewGuest will not get a chance to update its text
- // input state which is tracked by |owner_web_contents_|.
- // TODO(ekaramad): We should perform detaching through WebContentsImpl (
- // inner WebContents detaching from outer WebContents). After this is fixed,
- // we can remove this call to OnTextInputStateChanged (crbug.com/602640).
- OnTextInputStateChanged(TextInputState());
-
// This tells BrowserPluginGuest to queue up all IPCs to BrowserPlugin until
// it's attached again.
attached_ = false;
@@ -988,9 +979,10 @@ void BrowserPluginGuest::OnTakeFocus(bool reverse) {
new BrowserPluginMsg_AdvanceFocus(browser_plugin_instance_id(), reverse));
}
-void BrowserPluginGuest::OnTextInputStateChanged(const TextInputState& params) {
+void BrowserPluginGuest::OnTextInputStateChanged(
+ const ViewHostMsg_TextInputState_Params& params) {
// Save the state of text input so we can restore it on focus.
- last_text_input_state_.reset(new TextInputState(params));
+ last_text_input_state_.reset(new ViewHostMsg_TextInputState_Params(params));
SendTextInputTypeChangedToView(
static_cast<RenderWidgetHostViewBase*>(
« no previous file with comments | « content/browser/browser_plugin/browser_plugin_guest.h ('k') | content/browser/frame_host/interstitial_page_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698