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

Side by Side Diff: content/browser/renderer_host/render_view_host.cc

Issue 7055004: File upload API in chromedriver (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Fixed according to the code review Created 9 years, 7 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "content/browser/renderer_host/render_view_host.h" 5 #include "content/browser/renderer_host/render_view_host.h"
6 6
7 #include <string> 7 #include <string>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 IPC_MESSAGE_HANDLER(ViewHostMsg_OpenURL, OnMsgOpenURL) 652 IPC_MESSAGE_HANDLER(ViewHostMsg_OpenURL, OnMsgOpenURL)
653 IPC_MESSAGE_HANDLER(ViewHostMsg_DidContentsPreferredSizeChange, 653 IPC_MESSAGE_HANDLER(ViewHostMsg_DidContentsPreferredSizeChange,
654 OnMsgDidContentsPreferredSizeChange) 654 OnMsgDidContentsPreferredSizeChange)
655 IPC_MESSAGE_HANDLER(ViewHostMsg_SetTooltipText, OnMsgSetTooltipText) 655 IPC_MESSAGE_HANDLER(ViewHostMsg_SetTooltipText, OnMsgSetTooltipText)
656 IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_RunJavaScriptMessage, 656 IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_RunJavaScriptMessage,
657 OnMsgRunJavaScriptMessage) 657 OnMsgRunJavaScriptMessage)
658 IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_RunBeforeUnloadConfirm, 658 IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_RunBeforeUnloadConfirm,
659 OnMsgRunBeforeUnloadConfirm) 659 OnMsgRunBeforeUnloadConfirm)
660 IPC_MESSAGE_HANDLER(DragHostMsg_StartDragging, OnMsgStartDragging) 660 IPC_MESSAGE_HANDLER(DragHostMsg_StartDragging, OnMsgStartDragging)
661 IPC_MESSAGE_HANDLER(DragHostMsg_UpdateDragCursor, OnUpdateDragCursor) 661 IPC_MESSAGE_HANDLER(DragHostMsg_UpdateDragCursor, OnUpdateDragCursor)
662 IPC_MESSAGE_HANDLER(DragHostMsg_TargetDrop, OnTargetDropACK)
662 IPC_MESSAGE_HANDLER(ViewHostMsg_TakeFocus, OnTakeFocus) 663 IPC_MESSAGE_HANDLER(ViewHostMsg_TakeFocus, OnTakeFocus)
663 IPC_MESSAGE_HANDLER(ViewHostMsg_AddMessageToConsole, OnAddMessageToConsole) 664 IPC_MESSAGE_HANDLER(ViewHostMsg_AddMessageToConsole, OnAddMessageToConsole)
664 IPC_MESSAGE_HANDLER(ViewHostMsg_ShouldClose_ACK, OnMsgShouldCloseACK) 665 IPC_MESSAGE_HANDLER(ViewHostMsg_ShouldClose_ACK, OnMsgShouldCloseACK)
665 IPC_MESSAGE_HANDLER(ViewHostMsg_ClosePage_ACK, OnMsgClosePageACK) 666 IPC_MESSAGE_HANDLER(ViewHostMsg_ClosePage_ACK, OnMsgClosePageACK)
666 IPC_MESSAGE_HANDLER(ViewHostMsg_SelectionChanged, OnMsgSelectionChanged) 667 IPC_MESSAGE_HANDLER(ViewHostMsg_SelectionChanged, OnMsgSelectionChanged)
667 IPC_MESSAGE_HANDLER(ViewHostMsg_AccessibilityNotifications, 668 IPC_MESSAGE_HANDLER(ViewHostMsg_AccessibilityNotifications,
668 OnAccessibilityNotifications) 669 OnAccessibilityNotifications)
669 IPC_MESSAGE_HANDLER(ViewHostMsg_ScriptEvalResponse, OnScriptEvalResponse) 670 IPC_MESSAGE_HANDLER(ViewHostMsg_ScriptEvalResponse, OnScriptEvalResponse)
670 IPC_MESSAGE_HANDLER(ViewHostMsg_DidZoomURL, OnDidZoomURL) 671 IPC_MESSAGE_HANDLER(ViewHostMsg_DidZoomURL, OnDidZoomURL)
671 #if defined(OS_MACOSX) 672 #if defined(OS_MACOSX)
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
1029 if (view) 1030 if (view)
1030 view->StartDragging(drop_data, drag_operations_mask, image, image_offset); 1031 view->StartDragging(drop_data, drag_operations_mask, image, image_offset);
1031 } 1032 }
1032 1033
1033 void RenderViewHost::OnUpdateDragCursor(WebDragOperation current_op) { 1034 void RenderViewHost::OnUpdateDragCursor(WebDragOperation current_op) {
1034 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate(); 1035 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate();
1035 if (view) 1036 if (view)
1036 view->UpdateDragCursor(current_op); 1037 view->UpdateDragCursor(current_op);
1037 } 1038 }
1038 1039
1040 void RenderViewHost::OnTargetDropACK() {
1041 NotificationService::current()->Notify(
1042 NotificationType::RENDER_VIEW_HOST_DID_RECEIVE_DRAG_TARGET_DROP_ACK,
1043 Source<RenderViewHost>(this),
1044 NotificationService::NoDetails());
1045 }
1046
1039 void RenderViewHost::OnTakeFocus(bool reverse) { 1047 void RenderViewHost::OnTakeFocus(bool reverse) {
1040 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate(); 1048 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate();
1041 if (view) 1049 if (view)
1042 view->TakeFocus(reverse); 1050 view->TakeFocus(reverse);
1043 } 1051 }
1044 1052
1045 void RenderViewHost::OnAddMessageToConsole(int32 level, 1053 void RenderViewHost::OnAddMessageToConsole(int32 level,
1046 const std::wstring& message, 1054 const std::wstring& message,
1047 int32 line_no, 1055 int32 line_no,
1048 const std::wstring& source_id) { 1056 const std::wstring& source_id) {
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
1279 if (view) { 1287 if (view) {
1280 view->ShowPopupMenu(params.bounds, 1288 view->ShowPopupMenu(params.bounds,
1281 params.item_height, 1289 params.item_height,
1282 params.item_font_size, 1290 params.item_font_size,
1283 params.selected_item, 1291 params.selected_item,
1284 params.popup_items, 1292 params.popup_items,
1285 params.right_aligned); 1293 params.right_aligned);
1286 } 1294 }
1287 } 1295 }
1288 #endif 1296 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698