| OLD | NEW |
| 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 1505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1516 provideGeolocationTo(*m_frame, m_geolocationClientProxy.get()); | 1516 provideGeolocationTo(*m_frame, m_geolocationClientProxy.get()); |
| 1517 m_geolocationClientProxy->setController(GeolocationController::from(m_frame.
get())); | 1517 m_geolocationClientProxy->setController(GeolocationController::from(m_frame.
get())); |
| 1518 provideMIDITo(*m_frame, MIDIClientProxy::create(m_client ? m_client->webMIDI
Client() : nullptr)); | 1518 provideMIDITo(*m_frame, MIDIClientProxy::create(m_client ? m_client->webMIDI
Client() : nullptr)); |
| 1519 provideLocalFileSystemTo(*m_frame, LocalFileSystemClient::create()); | 1519 provideLocalFileSystemTo(*m_frame, LocalFileSystemClient::create()); |
| 1520 provideNavigatorContentUtilsTo(*m_frame, NavigatorContentUtilsClientImpl::cr
eate(this)); | 1520 provideNavigatorContentUtilsTo(*m_frame, NavigatorContentUtilsClientImpl::cr
eate(this)); |
| 1521 | 1521 |
| 1522 // Always provided so that availability of the API can be controlled by | 1522 // Always provided so that availability of the API can be controlled by |
| 1523 // OriginTrials::webUSBEnabled(). | 1523 // OriginTrials::webUSBEnabled(). |
| 1524 USBController::provideTo(*m_frame, m_client ? m_client->usbClient() : nullpt
r); | 1524 USBController::provideTo(*m_frame, m_client ? m_client->usbClient() : nullpt
r); |
| 1525 | 1525 |
| 1526 bool enableWebBluetooth = RuntimeEnabledFeatures::webBluetoothEnabled(); | 1526 if (RuntimeEnabledFeatures::webBluetoothEnabled()) |
| 1527 #if OS(CHROMEOS) || OS(ANDROID) | |
| 1528 enableWebBluetooth = true; | |
| 1529 #endif | |
| 1530 | |
| 1531 if (enableWebBluetooth) | |
| 1532 BluetoothSupplement::provideTo(*m_frame, m_client ? m_client->bluetooth(
) : nullptr); | 1527 BluetoothSupplement::provideTo(*m_frame, m_client ? m_client->bluetooth(
) : nullptr); |
| 1533 | |
| 1534 if (RuntimeEnabledFeatures::screenOrientationEnabled()) | 1528 if (RuntimeEnabledFeatures::screenOrientationEnabled()) |
| 1535 ScreenOrientationController::provideTo(*m_frame, m_client ? m_client->we
bScreenOrientationClient() : nullptr); | 1529 ScreenOrientationController::provideTo(*m_frame, m_client ? m_client->we
bScreenOrientationClient() : nullptr); |
| 1536 if (RuntimeEnabledFeatures::presentationEnabled()) | 1530 if (RuntimeEnabledFeatures::presentationEnabled()) |
| 1537 PresentationController::provideTo(*m_frame, m_client ? m_client->present
ationClient() : nullptr); | 1531 PresentationController::provideTo(*m_frame, m_client ? m_client->present
ationClient() : nullptr); |
| 1538 if (RuntimeEnabledFeatures::permissionsEnabled()) | 1532 if (RuntimeEnabledFeatures::permissionsEnabled()) |
| 1539 PermissionController::provideTo(*m_frame, m_client ? m_client->permissio
nClient() : nullptr); | 1533 PermissionController::provideTo(*m_frame, m_client ? m_client->permissio
nClient() : nullptr); |
| 1540 if (RuntimeEnabledFeatures::webVREnabled()) | 1534 if (RuntimeEnabledFeatures::webVREnabled()) |
| 1541 VRController::provideTo(*m_frame, m_client ? m_client->webVRClient() : n
ullptr); | 1535 VRController::provideTo(*m_frame, m_client ? m_client->webVRClient() : n
ullptr); |
| 1542 if (RuntimeEnabledFeatures::wakeLockEnabled()) | 1536 if (RuntimeEnabledFeatures::wakeLockEnabled()) |
| 1543 ScreenWakeLock::provideTo(*m_frame, m_client ? m_client->wakeLockClient(
) : nullptr); | 1537 ScreenWakeLock::provideTo(*m_frame, m_client ? m_client->wakeLockClient(
) : nullptr); |
| (...skipping 626 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2170 return WebSandboxFlags::None; | 2164 return WebSandboxFlags::None; |
| 2171 return static_cast<WebSandboxFlags>(frame()->loader().effectiveSandboxFlags(
)); | 2165 return static_cast<WebSandboxFlags>(frame()->loader().effectiveSandboxFlags(
)); |
| 2172 } | 2166 } |
| 2173 | 2167 |
| 2174 void WebLocalFrameImpl::forceSandboxFlags(WebSandboxFlags flags) | 2168 void WebLocalFrameImpl::forceSandboxFlags(WebSandboxFlags flags) |
| 2175 { | 2169 { |
| 2176 frame()->loader().forceSandboxFlags(static_cast<SandboxFlags>(flags)); | 2170 frame()->loader().forceSandboxFlags(static_cast<SandboxFlags>(flags)); |
| 2177 } | 2171 } |
| 2178 | 2172 |
| 2179 } // namespace blink | 2173 } // namespace blink |
| OLD | NEW |