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

Side by Side Diff: third_party/WebKit/Source/web/WebViewImpl.cpp

Issue 2151933003: Change WTF::TemporaryChange to be an alias for AutoReset (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 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 2154 matching lines...) Expand 10 before | Expand all | Expand 10 after
2165 2165
2166 if (InspectorOverlay* overlay = inspectorOverlay()) { 2166 if (InspectorOverlay* overlay = inspectorOverlay()) {
2167 if (overlay->handleInputEvent(inputEvent)) 2167 if (overlay->handleInputEvent(inputEvent))
2168 return WebInputEventResult::HandledSuppressed; 2168 return WebInputEventResult::HandledSuppressed;
2169 } 2169 }
2170 2170
2171 // Report the event to be NOT processed by WebKit, so that the browser can h andle it appropriately. 2171 // Report the event to be NOT processed by WebKit, so that the browser can h andle it appropriately.
2172 if (m_ignoreInputEvents) 2172 if (m_ignoreInputEvents)
2173 return WebInputEventResult::NotHandled; 2173 return WebInputEventResult::NotHandled;
2174 2174
2175 TemporaryChange<const WebInputEvent*> currentEventChange(m_currentInputEvent , &inputEvent); 2175 TemporaryChange<const WebInputEvent*> currentEventChange(&m_currentInputEven t, &inputEvent);
2176 UIEventWithKeyState::clearNewTabModifierSetFromIsolatedWorld(); 2176 UIEventWithKeyState::clearNewTabModifierSetFromIsolatedWorld();
2177 2177
2178 bool isPointerLocked = false; 2178 bool isPointerLocked = false;
2179 if (WebFrameWidget* widget = mainFrameImpl()->frameWidget()) { 2179 if (WebFrameWidget* widget = mainFrameImpl()->frameWidget()) {
2180 if (WebWidgetClient* client = widget->client()) 2180 if (WebWidgetClient* client = widget->client())
2181 isPointerLocked = client->isPointerLocked(); 2181 isPointerLocked = client->isPointerLocked();
2182 } 2182 }
2183 2183
2184 if (isPointerLocked && WebInputEvent::isMouseEventType(inputEvent.type)) { 2184 if (isPointerLocked && WebInputEvent::isMouseEventType(inputEvent.type)) {
2185 pointerLockMouseEvent(inputEvent); 2185 pointerLockMouseEvent(inputEvent);
(...skipping 2387 matching lines...) Expand 10 before | Expand all | Expand 10 after
4573 { 4573 {
4574 // TODO(oshima): Investigate if this should return the ScreenInfo's scale fa ctor rather than 4574 // TODO(oshima): Investigate if this should return the ScreenInfo's scale fa ctor rather than
4575 // page's scale factor, which can be 1 in use-zoom-for-dsf mode. 4575 // page's scale factor, which can be 1 in use-zoom-for-dsf mode.
4576 if (!page()) 4576 if (!page())
4577 return 1; 4577 return 1;
4578 4578
4579 return page()->deviceScaleFactor(); 4579 return page()->deviceScaleFactor();
4580 } 4580 }
4581 4581
4582 } // namespace blink 4582 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698