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

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

Issue 10965048: [BrowserTag] Send dib info with NavigateGuest message, (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments from Fady + remove commented code. Created 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_plugin/browser_plugin_host_browsertest.cc
diff --git a/content/browser/browser_plugin/browser_plugin_host_browsertest.cc b/content/browser/browser_plugin/browser_plugin_host_browsertest.cc
index de9022177f288df2f74df58c6af6d36a4cf671ae..b10dececf32b7c2f37fc550846c9b69759be14fe 100644
--- a/content/browser/browser_plugin/browser_plugin_host_browsertest.cc
+++ b/content/browser/browser_plugin/browser_plugin_host_browsertest.cc
@@ -234,10 +234,9 @@ IN_PROC_BROWSER_TEST_F(BrowserPluginHostTest, NavigateAfterResize) {
RenderViewHostImpl* rvh = static_cast<RenderViewHostImpl*>(
embedder_web_contents->GetRenderViewHost());
- int nxt_width = 100;
- int nxt_height = 200;
+ const gfx::Size nxt_size = gfx::Size(100, 200);
rvh->ExecuteJavascriptAndGetValue(string16(), ASCIIToUTF16(
- StringPrintf("SetSize(%d, %d);", nxt_width, nxt_height)));
+ StringPrintf("SetSize(%d, %d);", nxt_size.width(), nxt_size.height())));
rvh->ExecuteJavascriptAndGetValue(string16(), ASCIIToUTF16(
StringPrintf("SetSrc('%s');", kHTMLForGuest)));
@@ -261,10 +260,9 @@ IN_PROC_BROWSER_TEST_F(BrowserPluginHostTest, NavigateAfterResize) {
TestBrowserPluginGuest* test_guest = static_cast<TestBrowserPluginGuest*>(
test_guest_web_contents->GetBrowserPluginGuest());
-
- // Wait for the guest to send an UpdateRectMsg, the dimensions should be
- // 100 x 200.
- test_guest->WaitForUpdateRectMsgWithSize(nxt_width, nxt_height);
+ // Wait for the guest to receive a damage buffer of size 100x200.
+ // This means the guest will be painted properly at that size.
+ test_guest->WaitForDamageBufferWithSize(nxt_size);
}
IN_PROC_BROWSER_TEST_F(BrowserPluginHostTest, AdvanceFocus) {

Powered by Google App Engine
This is Rietveld 408576698