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

Side by Side Diff: Source/web/WebPopupMenuImpl.cpp

Issue 298803009: Remove no-op did(De)activateCompositor calls (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 6 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 | « Source/web/WebPagePopupImpl.cpp ('k') | Source/web/WebViewImpl.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 98
99 if (!m_client) 99 if (!m_client)
100 return; 100 return;
101 m_client->setWindowRect(bounds); 101 m_client->setWindowRect(bounds);
102 m_client->show(WebNavigationPolicy()); // Policy is ignored. 102 m_client->show(WebNavigationPolicy()); // Policy is ignored.
103 103
104 m_client->initializeLayerTreeView(); 104 m_client->initializeLayerTreeView();
105 m_layerTreeView = m_client->layerTreeView(); 105 m_layerTreeView = m_client->layerTreeView();
106 if (m_layerTreeView) { 106 if (m_layerTreeView) {
107 m_layerTreeView->setVisible(true); 107 m_layerTreeView->setVisible(true);
108 m_client->didActivateCompositor();
109 m_layerTreeView->setDeviceScaleFactor(m_client->deviceScaleFactor()); 108 m_layerTreeView->setDeviceScaleFactor(m_client->deviceScaleFactor());
110 m_rootLayer = adoptPtr(Platform::current()->compositorSupport()->createC ontentLayer(this)); 109 m_rootLayer = adoptPtr(Platform::current()->compositorSupport()->createC ontentLayer(this));
111 m_rootLayer->layer()->setBounds(m_size); 110 m_rootLayer->layer()->setBounds(m_size);
112 m_layerTreeView->setRootLayer(*m_rootLayer->layer()); 111 m_layerTreeView->setRootLayer(*m_rootLayer->layer());
113 } else {
114 m_client->didDeactivateCompositor();
115 } 112 }
116 } 113 }
117 114
118 void WebPopupMenuImpl::handleMouseMove(const WebMouseEvent& event) 115 void WebPopupMenuImpl::handleMouseMove(const WebMouseEvent& event)
119 { 116 {
120 // Don't send mouse move messages if the mouse hasn't moved. 117 // Don't send mouse move messages if the mouse hasn't moved.
121 if (event.x != m_lastMousePosition.x || event.y != m_lastMousePosition.y) { 118 if (event.x != m_lastMousePosition.x || event.y != m_lastMousePosition.y) {
122 m_lastMousePosition = WebPoint(event.x, event.y); 119 m_lastMousePosition = WebPoint(event.x, event.y);
123 m_widget->handleMouseMoveEvent(PlatformMouseEventBuilder(m_widget, event )); 120 m_widget->handleMouseMoveEvent(PlatformMouseEventBuilder(m_widget, event ));
124 121
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 ASSERT(widget == m_widget); 418 ASSERT(widget == m_widget);
422 if (m_widget) { 419 if (m_widget) {
423 m_widget->setClient(0); 420 m_widget->setClient(0);
424 m_widget = 0; 421 m_widget = 0;
425 } 422 }
426 if (m_client) 423 if (m_client)
427 m_client->closeWidgetSoon(); 424 m_client->closeWidgetSoon();
428 } 425 }
429 426
430 } // namespace blink 427 } // namespace blink
OLDNEW
« no previous file with comments | « Source/web/WebPagePopupImpl.cpp ('k') | Source/web/WebViewImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698