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

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

Issue 1089813002: Change beforeinstallprompt event to take an array of platforms. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Update test expectations Created 5 years, 8 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
« no previous file with comments | « Source/web/WebLocalFrameImpl.h ('k') | public/web/WebLocalFrame.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 /* 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 2012 matching lines...) Expand 10 before | Expand all | Expand 10 after
2023 2023
2024 // Screen Orientation API 2024 // Screen Orientation API
2025 if (ScreenOrientationController::from(*frame())) 2025 if (ScreenOrientationController::from(*frame()))
2026 ScreenOrientationController::from(*frame())->notifyOrientationChanged(); 2026 ScreenOrientationController::from(*frame())->notifyOrientationChanged();
2027 2027
2028 // Legacy window.orientation API 2028 // Legacy window.orientation API
2029 if (RuntimeEnabledFeatures::orientationEventEnabled() && frame()->domWindow( )) 2029 if (RuntimeEnabledFeatures::orientationEventEnabled() && frame()->domWindow( ))
2030 frame()->localDOMWindow()->sendOrientationChangeEvent(); 2030 frame()->localDOMWindow()->sendOrientationChangeEvent();
2031 } 2031 }
2032 2032
2033 void WebLocalFrameImpl::willShowInstallBannerPrompt(const WebString& platform, W ebAppBannerPromptReply* reply) 2033 void WebLocalFrameImpl::willShowInstallBannerPrompt(const WebVector<WebString>& platforms, WebAppBannerPromptReply* reply)
2034 { 2034 {
2035 if (!RuntimeEnabledFeatures::appBannerEnabled() || !frame()) 2035 if (!RuntimeEnabledFeatures::appBannerEnabled() || !frame())
2036 return; 2036 return;
2037 2037
2038 AppBannerController::willShowInstallBannerPrompt(frame(), platform, reply); 2038 AppBannerController::willShowInstallBannerPrompt(frame(), platforms, reply);
2039 }
2040
2041
2042 void WebLocalFrameImpl::willShowInstallBannerPrompt(const WebString& platform, W ebAppBannerPromptReply* reply)
2043 {
2044 WebVector<WebString> platforms(&platform, 1);
2045 willShowInstallBannerPrompt(platforms, reply);
2039 } 2046 }
2040 2047
2041 void WebLocalFrameImpl::requestRunTask(WebSuspendableTask* task) const 2048 void WebLocalFrameImpl::requestRunTask(WebSuspendableTask* task) const
2042 { 2049 {
2043 ASSERT(frame()); 2050 ASSERT(frame());
2044 ASSERT(frame()->document()); 2051 ASSERT(frame()->document());
2045 frame()->document()->postSuspendableTask(WebSuspendableTaskWrapper::create(a doptPtr(task))); 2052 frame()->document()->postSuspendableTask(WebSuspendableTaskWrapper::create(a doptPtr(task)));
2046 } 2053 }
2047 2054
2048 void WebLocalFrameImpl::willBeDetached() 2055 void WebLocalFrameImpl::willBeDetached()
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
2111 { 2118 {
2112 m_frameWidget = frameWidget; 2119 m_frameWidget = frameWidget;
2113 } 2120 }
2114 2121
2115 WebFrameWidgetImpl* WebLocalFrameImpl::frameWidget() const 2122 WebFrameWidgetImpl* WebLocalFrameImpl::frameWidget() const
2116 { 2123 {
2117 return m_frameWidget; 2124 return m_frameWidget;
2118 } 2125 }
2119 2126
2120 } // namespace blink 2127 } // namespace blink
OLDNEW
« no previous file with comments | « Source/web/WebLocalFrameImpl.h ('k') | public/web/WebLocalFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698