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

Side by Side Diff: webkit/glue/webplugin_impl.cc

Issue 164466: Merge 22431 - This fixes the npapiresponseheaders layout test, which started ... (Closed) Base URL: svn://chrome-svn/chrome/branches/195/src/
Patch Set: Created 11 years, 4 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 | « no previous file | webkit/tools/layout_tests/test_expectations.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Modified: svn:mergeinfo
Merged /trunk/src/webkit/glue/webplugin_impl.cc:r22431
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 "config.h" 5 #include "config.h"
6 6
7 #include "Document.h" 7 #include "Document.h"
8 #include "DocumentLoader.h" 8 #include "DocumentLoader.h"
9 #include "Event.h" 9 #include "Event.h"
10 #include "EventNames.h" 10 #include "EventNames.h"
(...skipping 1052 matching lines...) Expand 10 before | Expand all | Expand 10 after
1063 MultiPartResponseHandlerMap::iterator index = 1063 MultiPartResponseHandlerMap::iterator index =
1064 multi_part_response_map_.find(client_info->client); 1064 multi_part_response_map_.find(client_info->client);
1065 if (index != multi_part_response_map_.end()) { 1065 if (index != multi_part_response_map_.end()) {
1066 delete (*index).second; 1066 delete (*index).second;
1067 multi_part_response_map_.erase(index); 1067 multi_part_response_map_.erase(index);
1068 1068
1069 WebView* web_view = webframe_->GetView(); 1069 WebView* web_view = webframe_->GetView();
1070 web_view->GetDelegate()->DidStopLoading(web_view); 1070 web_view->GetDelegate()->DidStopLoading(web_view);
1071 } 1071 }
1072 loader->setDefersLoading(true); 1072 loader->setDefersLoading(true);
1073 client_info->client->DidFinishLoading(); 1073 WebPluginResourceClient* resource_client = client_info->client;
1074 // The WebPluginResourceClient pointer gets deleted soon after a call to 1074 // The ClientInfo can get deleted in the call to DidFinishLoading below.
1075 // DidFinishLoading. 1075 // It is not safe to access this structure after that.
1076 client_info->client = NULL; 1076 client_info->client = NULL;
1077 resource_client->DidFinishLoading();
1077 } 1078 }
1078 } 1079 }
1079 1080
1080 void WebPluginImpl::didFail(WebURLLoader* loader, 1081 void WebPluginImpl::didFail(WebURLLoader* loader,
1081 const WebURLError&) { 1082 const WebURLError&) {
1082 ClientInfo* client_info = GetClientInfoFromLoader(loader); 1083 ClientInfo* client_info = GetClientInfoFromLoader(loader);
1083 if (client_info && client_info->client) { 1084 if (client_info && client_info->client) {
1084 loader->setDefersLoading(true); 1085 loader->setDefersLoading(true);
1085 client_info->client->DidFail(); 1086 WebPluginResourceClient* resource_client = client_info->client;
1086 // The WebPluginResourceClient pointer gets deleted soon after a call to 1087 // The ClientInfo can get deleted in the call to DidFail below.
1087 // DidFinishLoading. 1088 // It is not safe to access this structure after that.
1088 client_info->client = NULL; 1089 client_info->client = NULL;
1090 resource_client->DidFail();
1089 } 1091 }
1090 } 1092 }
1091 1093
1092 void WebPluginImpl::RemoveClient(size_t i) { 1094 void WebPluginImpl::RemoveClient(size_t i) {
1093 clients_.erase(clients_.begin() + i); 1095 clients_.erase(clients_.begin() + i);
1094 } 1096 }
1095 1097
1096 void WebPluginImpl::RemoveClient(WebURLLoader* loader) { 1098 void WebPluginImpl::RemoveClient(WebURLLoader* loader) {
1097 for (size_t i = 0; i < clients_.size(); ++i) { 1099 for (size_t i = 0; i < clients_.size(); ++i) {
1098 if (clients_[i].loader.get() == loader) { 1100 if (clients_[i].loader.get() == loader) {
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
1459 1461
1460 WebPluginGeometry move; 1462 WebPluginGeometry move;
1461 move.window = window_; 1463 move.window = window_;
1462 move.window_rect = gfx::Rect(); 1464 move.window_rect = gfx::Rect();
1463 move.clip_rect = gfx::Rect(); 1465 move.clip_rect = gfx::Rect();
1464 move.rects_valid = false; 1466 move.rects_valid = false;
1465 move.visible = widget_->isVisible(); 1467 move.visible = widget_->isVisible();
1466 1468
1467 webview->delegate()->DidMovePlugin(move); 1469 webview->delegate()->DidMovePlugin(move);
1468 } 1470 }
OLDNEW
« no previous file with comments | « no previous file | webkit/tools/layout_tests/test_expectations.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698