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

Side by Side Diff: chrome/browser/cocoa/notifications/balloon_view_host_mac.h

Issue 668125: Basic DragImage implementation.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 9 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 | chrome/browser/extensions/extension_host.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ 5 #ifndef CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_
6 #define CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ 6 #define CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_
7 7
8 #include "app/gfx/native_widget_types.h" 8 #include "app/gfx/native_widget_types.h"
9 #include "chrome/browser/notifications/balloon.h" 9 #include "chrome/browser/notifications/balloon.h"
10 #include "chrome/browser/renderer_host/render_view_host_delegate.h" 10 #include "chrome/browser/renderer_host/render_view_host_delegate.h"
11 #import "chrome/browser/renderer_host/render_widget_host_view_mac.h" 11 #import "chrome/browser/renderer_host/render_widget_host_view_mac.h"
12 #include "chrome/browser/renderer_host/site_instance.h" 12 #include "chrome/browser/renderer_host/site_instance.h"
13 #include "chrome/browser/tab_contents/render_view_host_delegate_helper.h" 13 #include "chrome/browser/tab_contents/render_view_host_delegate_helper.h"
14 #include "webkit/glue/webpreferences.h" 14 #include "webkit/glue/webpreferences.h"
15 15
16 class Profile; 16 class Profile;
17 class RenderViewHost; 17 class RenderViewHost;
18 class SkBitmap;
19 namespace gfx {
20 class Point;
21 }
18 22
19 // BalloonViewHost class is a delegate to the renderer host for the HTML 23 // BalloonViewHost class is a delegate to the renderer host for the HTML
20 // notification. When initialized it creates a new RenderViewHost and loads 24 // notification. When initialized it creates a new RenderViewHost and loads
21 // the contents of the toast into it. It also handles links within the toast, 25 // the contents of the toast into it. It also handles links within the toast,
22 // loading them into a new tab. 26 // loading them into a new tab.
23 class BalloonViewHost : public RenderViewHostDelegate, 27 class BalloonViewHost : public RenderViewHostDelegate,
24 public RenderViewHostDelegate::View { 28 public RenderViewHostDelegate::View {
25 public: 29 public:
26 explicit BalloonViewHost(Balloon* balloon); 30 explicit BalloonViewHost(Balloon* balloon);
27 31
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 virtual void CreateNewWindow(int route_id); 73 virtual void CreateNewWindow(int route_id);
70 virtual void CreateNewWidget(int route_id, bool activatable) {} 74 virtual void CreateNewWidget(int route_id, bool activatable) {}
71 virtual void ShowCreatedWindow(int route_id, 75 virtual void ShowCreatedWindow(int route_id,
72 WindowOpenDisposition disposition, 76 WindowOpenDisposition disposition,
73 const gfx::Rect& initial_pos, 77 const gfx::Rect& initial_pos,
74 bool user_gesture); 78 bool user_gesture);
75 virtual void ShowCreatedWidget(int route_id, 79 virtual void ShowCreatedWidget(int route_id,
76 const gfx::Rect& initial_pos) {} 80 const gfx::Rect& initial_pos) {}
77 virtual void ShowContextMenu(const ContextMenuParams& params) {} 81 virtual void ShowContextMenu(const ContextMenuParams& params) {}
78 virtual void StartDragging(const WebDropData& drop_data, 82 virtual void StartDragging(const WebDropData& drop_data,
79 WebKit::WebDragOperationsMask allowed_ops) {} 83 WebKit::WebDragOperationsMask allowed_ops,
84 const SkBitmap& image,
85 const gfx::Point& image_offset) {}
80 virtual void UpdateDragCursor(WebKit::WebDragOperation operation) {} 86 virtual void UpdateDragCursor(WebKit::WebDragOperation operation) {}
81 virtual void GotFocus() {} 87 virtual void GotFocus() {}
82 virtual void TakeFocus(bool reverse) {} 88 virtual void TakeFocus(bool reverse) {}
83 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, 89 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event,
84 bool* is_keyboard_shortcut) { 90 bool* is_keyboard_shortcut) {
85 return false; 91 return false;
86 } 92 }
87 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) {} 93 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) {}
88 virtual void HandleMouseEvent() {} 94 virtual void HandleMouseEvent() {}
89 virtual void HandleMouseLeave() {} 95 virtual void HandleMouseLeave() {}
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 // which this class frees in its destructor. 127 // which this class frees in its destructor.
122 RenderWidgetHostViewMac* render_widget_host_view_; 128 RenderWidgetHostViewMac* render_widget_host_view_;
123 129
124 // Common implementations of some RenderViewHostDelegate::View methods. 130 // Common implementations of some RenderViewHostDelegate::View methods.
125 RenderViewHostDelegateViewHelper delegate_view_helper_; 131 RenderViewHostDelegateViewHelper delegate_view_helper_;
126 132
127 DISALLOW_COPY_AND_ASSIGN(BalloonViewHost); 133 DISALLOW_COPY_AND_ASSIGN(BalloonViewHost);
128 }; 134 };
129 135
130 #endif // CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ 136 #endif // CHROME_BROWSER_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698