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

Side by Side Diff: chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.cc

Issue 9391024: Custom frame UI for platform apps on Windows. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: "Transparent" -> "Clickthrough", fix patchset Created 8 years, 10 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.h" 5 #include "chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.h"
6 6
7 #include "chrome/browser/tab_contents/web_drop_target_win.h" 7 #include "chrome/browser/tab_contents/web_drop_target_win.h"
8 #include "chrome/browser/ui/views/tab_contents/native_tab_contents_view_delegate .h" 8 #include "chrome/browser/ui/views/tab_contents/native_tab_contents_view_delegate .h"
9 #include "chrome/browser/ui/views/tab_contents/tab_contents_drag_win.h" 9 #include "chrome/browser/ui/views/tab_contents/tab_contents_drag_win.h"
10 #include "content/public/browser/render_widget_host_view.h" 10 #include "content/public/browser/render_widget_host_view.h"
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
276 // to receive scroll messages from ThinkPad touch-pad driver. Suppress 276 // to receive scroll messages from ThinkPad touch-pad driver. Suppress
277 // painting of scrollbars by returning 0 size for them. 277 // painting of scrollbars by returning 0 size for them.
278 return 0; 278 return 0;
279 } 279 }
280 280
281 void NativeTabContentsViewWin::OnNCPaint(HRGN rgn) { 281 void NativeTabContentsViewWin::OnNCPaint(HRGN rgn) {
282 // Suppress default WM_NCPAINT handling. We don't need to do anything 282 // Suppress default WM_NCPAINT handling. We don't need to do anything
283 // here since the view will draw everything correctly. 283 // here since the view will draw everything correctly.
284 } 284 }
285 285
286 LRESULT NativeTabContentsViewWin::OnNCHitTest(const CPoint& point) {
287 // Allow hit tests to fall through to the parent window.
288 SetMsgHandled(true);
289 return HTTRANSPARENT;
290 }
291
286 //////////////////////////////////////////////////////////////////////////////// 292 ////////////////////////////////////////////////////////////////////////////////
287 // NativeTabContentsViewWin, private: 293 // NativeTabContentsViewWin, private:
288 294
289 void NativeTabContentsViewWin::ScrollCommon(UINT message, int scroll_type, 295 void NativeTabContentsViewWin::ScrollCommon(UINT message, int scroll_type,
290 short position, HWND scrollbar) { 296 short position, HWND scrollbar) {
291 // This window can receive scroll events as a result of the ThinkPad's 297 // This window can receive scroll events as a result of the ThinkPad's
292 // touch-pad scroll wheel emulation. 298 // touch-pad scroll wheel emulation.
293 if (!ScrollZoom(scroll_type)) { 299 if (!ScrollZoom(scroll_type)) {
294 // Reflect scroll message to the view() to give it a chance 300 // Reflect scroll message to the view() to give it a chance
295 // to process scrolling. 301 // to process scrolling.
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 } 337 }
332 338
333 //////////////////////////////////////////////////////////////////////////////// 339 ////////////////////////////////////////////////////////////////////////////////
334 // NativeTabContentsView, public: 340 // NativeTabContentsView, public:
335 341
336 // static 342 // static
337 NativeTabContentsView* NativeTabContentsView::CreateNativeTabContentsView( 343 NativeTabContentsView* NativeTabContentsView::CreateNativeTabContentsView(
338 internal::NativeTabContentsViewDelegate* delegate) { 344 internal::NativeTabContentsViewDelegate* delegate) {
339 return new NativeTabContentsViewWin(delegate); 345 return new NativeTabContentsViewWin(delegate);
340 } 346 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/tab_contents/native_tab_contents_view_win.h ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698