| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "core/frame/Deprecation.h" | 5 #include "core/frame/Deprecation.h" |
| 6 | 6 |
| 7 #include "core/dom/Document.h" | 7 #include "core/dom/Document.h" |
| 8 #include "core/dom/ExecutionContext.h" | 8 #include "core/dom/ExecutionContext.h" |
| 9 #include "core/frame/FrameConsole.h" | 9 #include "core/frame/FrameConsole.h" |
| 10 #include "core/frame/FrameHost.h" | 10 #include "core/frame/FrameHost.h" |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 | 98 |
| 99 void Deprecation::countDeprecationIfNotPrivateScript(v8::Isolate* isolate, Execu
tionContext* context, UseCounter::Feature feature) | 99 void Deprecation::countDeprecationIfNotPrivateScript(v8::Isolate* isolate, Execu
tionContext* context, UseCounter::Feature feature) |
| 100 { | 100 { |
| 101 if (DOMWrapperWorld::current(isolate).isPrivateScriptIsolatedWorld()) | 101 if (DOMWrapperWorld::current(isolate).isPrivateScriptIsolatedWorld()) |
| 102 return; | 102 return; |
| 103 Deprecation::countDeprecation(context, feature); | 103 Deprecation::countDeprecation(context, feature); |
| 104 } | 104 } |
| 105 | 105 |
| 106 static const char* milestoneString(int milestone) | 106 static const char* milestoneString(int milestone) |
| 107 { | 107 { |
| 108 // These are the Estimated Stable Dates: |
| 109 // https://www.chromium.org/developers/calendar |
| 110 |
| 108 switch (milestone) { | 111 switch (milestone) { |
| 109 case 50: | 112 case 50: |
| 110 return "M50, around April 2016"; | 113 return "M50, around April 2016"; |
| 111 case 51: | 114 case 51: |
| 112 return "M51, around June 2016"; | 115 return "M51, around May 2016"; |
| 113 case 52: | 116 case 52: |
| 114 return "M52, around August 2016"; | 117 return "M52, around July 2016"; |
| 115 case 53: | 118 case 53: |
| 116 return "M53, around September 2016"; | 119 return "M53, around September 2016"; |
| 117 } | 120 } |
| 118 | 121 |
| 119 ASSERT_NOT_REACHED(); | 122 ASSERT_NOT_REACHED(); |
| 120 return nullptr; | 123 return nullptr; |
| 121 } | 124 } |
| 122 | 125 |
| 123 static String replacedBy(const char* feature, const char* replacement) | 126 static String replacedBy(const char* feature, const char* replacement) |
| 124 { | 127 { |
| (...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 317 case UseCounter::RTCPeerConnectionCreateOfferLegacyNoFailureCallback: | 320 case UseCounter::RTCPeerConnectionCreateOfferLegacyNoFailureCallback: |
| 318 return "RTCPeerConnection.CreateOffer without a failure callback is depr
ecated. The failure callback will be a required parameter in M50. See https://ww
w.chromestatus.com/feature/5663288008376320 for more details"; | 321 return "RTCPeerConnection.CreateOffer without a failure callback is depr
ecated. The failure callback will be a required parameter in M50. See https://ww
w.chromestatus.com/feature/5663288008376320 for more details"; |
| 319 | 322 |
| 320 case UseCounter::ObjectObserve: | 323 case UseCounter::ObjectObserve: |
| 321 return willBeRemoved("'Object.observe'", 50, "6147094632988672"); | 324 return willBeRemoved("'Object.observe'", 50, "6147094632988672"); |
| 322 | 325 |
| 323 case UseCounter::SVGZoomEvent: | 326 case UseCounter::SVGZoomEvent: |
| 324 return willBeRemoved("'SVGZoomEvent'", 52, "5760883808534528"); | 327 return willBeRemoved("'SVGZoomEvent'", 52, "5760883808534528"); |
| 325 | 328 |
| 326 case UseCounter::BorderImageWithBorderStyleNone: | 329 case UseCounter::BorderImageWithBorderStyleNone: |
| 327 return "Elements using the 'border-image' CSS property with no 'border-s
tyle' set should have no border, but currently do. Setting 'border-style' will b
e required in M51, around June 2016. See https://www.chromestatus.com/features/5
542503914668032 for more details."; | 330 return "Elements using the 'border-image' CSS property with no 'border-s
tyle' set should have no border, but currently do. Setting 'border-style' will b
e required in M51, around May 2016. See https://www.chromestatus.com/features/55
42503914668032 for more details."; |
| 328 | 331 |
| 329 case UseCounter::WebAnimationHyphenatedProperty: | 332 case UseCounter::WebAnimationHyphenatedProperty: |
| 330 return replacedWillBeRemoved("Hyphenated naming in Web Animations keyfra
mes", "camelCase", 51, "5650817352728576"); | 333 return replacedWillBeRemoved("Hyphenated naming in Web Animations keyfra
mes", "camelCase", 51, "5650817352728576"); |
| 331 | 334 |
| 332 // Features that aren't deprecated don't have a deprecation message. | 335 // Features that aren't deprecated don't have a deprecation message. |
| 333 default: | 336 default: |
| 334 return String(); | 337 return String(); |
| 335 } | 338 } |
| 336 } | 339 } |
| 337 | 340 |
| 338 } // namespace blink | 341 } // namespace blink |
| OLD | NEW |