https://bugs.webkit.org/show_bug.cgi?id=167542
<rdar://problem/
22746307>
Reviewed by Ryosuke Niwa.
Source/WebCore:
* page/RuntimeEnabledFeatures.h:
(WebCore::RuntimeEnabledFeatures::performanceTimelineEnabled):
* page/Performance.idl:
* page/PerformanceEntry.idl:
Make a better RuntimeEnabledFeature named "PerformanceTiming" which
is enabled if either UserTiming or ResourceTiming is enabled. This
will then expose the APIs that are only useful when at least one of
the APIs are available.
* page/PerformanceEntry.cpp:
(WebCore::PerformanceEntry::name): Deleted.
(WebCore::PerformanceEntry::entryType): Deleted.
(WebCore::PerformanceEntry::startTime): Deleted.
(WebCore::PerformanceEntry::duration): Deleted.
* page/PerformanceEntry.h:
(WebCore::PerformanceEntry::name):
(WebCore::PerformanceEntry::entryType):
(WebCore::PerformanceEntry::startTime):
(WebCore::PerformanceEntry::duration):
Inline simple accessors.
* page/PerformanceUserTiming.cpp:
(WebCore::UserTiming::measure):
Fix a bug introduced by ExceptionOr refactoring.
(WebCore::UserTiming::clearMarks):
(WebCore::UserTiming::clearMeasures):
(WebCore::clearPerformanceEntries):
(WebCore::clearPeformanceEntries): Deleted.
Fix method name typo.
Source/WebKit/mac:
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.mm:
(+[WebPreferences initialize]):
(-[WebPreferences userTimingEnabled]):
(-[WebPreferences setUserTimingEnabled:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _preferencesChanged:]):
Add setting for User Timing runtime enabled feature.
Source/WebKit/win:
* Interfaces/IWebPreferencesPrivate.idl:
* WebPreferenceKeysPrivate.h:
* WebPreferences.cpp:
(WebPreferences::initializeDefaultSettings):
(WebPreferences::setUserTimingEnabled):
(WebPreferences::userTimingEnabled):
* WebPreferences.h:
* WebView.cpp:
(WebView::notifyPreferencesChanged):
Add setting for User Timing runtime enabled feature.
Source/WebKit2:
* Shared/WebPreferencesDefinitions.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetUserTimingEnabled):
(WKPreferencesGetUserTimingEnabled):
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):
Experimental feature. Off for now while we update ResourceTiming
and NavigationTiming to be compatible with Performance Timing 2.
Tools:
* DumpRenderTree/mac/DumpRenderTree.mm:
(enableExperimentalFeatures):
(resetWebPreferencesToConsistentValues):
* DumpRenderTree/win/DumpRenderTree.cpp:
(enableExperimentalFeatures):
Websites/webkit.org:
* experimental-features.html:
LayoutTests:
* platform/efl/js/dom/global-constructors-attributes-expected.txt:
* platform/gtk/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-elcapitan/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-wk1/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-yosemite/js/dom/global-constructors-attributes-expected.txt:
* platform/mac/js/dom/global-constructors-attributes-expected.txt:
* platform/win/js/dom/global-constructors-attributes-expected.txt:
Update results now that experimental User Timing feature is enabled in tests.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@211332
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * platform/efl/js/dom/global-constructors-attributes-expected.txt:
+ * platform/gtk/js/dom/global-constructors-attributes-expected.txt:
+ * platform/mac-elcapitan/js/dom/global-constructors-attributes-expected.txt:
+ * platform/mac-wk1/js/dom/global-constructors-attributes-expected.txt:
+ * platform/mac-yosemite/js/dom/global-constructors-attributes-expected.txt:
+ * platform/mac/js/dom/global-constructors-attributes-expected.txt:
+ * platform/win/js/dom/global-constructors-attributes-expected.txt:
+ Update results now that experimental User Timing feature is enabled in tests.
+
2017-01-27 Yusuke Suzuki <utatane.tea@gmail.com>
Lift template escape sequence restrictions in tagged templates
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').hasOwnProperty('set') is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').enumerable is false
PASS Object.getOwnPropertyDescriptor(global, 'Performance').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').value is PerformanceEntry
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceEntry').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').value is PerformanceMark
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMark').configurable is true
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').value is PerformanceMeasure
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('get') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').hasOwnProperty('set') is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').enumerable is false
+PASS Object.getOwnPropertyDescriptor(global, 'PerformanceMeasure').configurable is true
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').value is PerformanceNavigation
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('get') is false
PASS Object.getOwnPropertyDescriptor(global, 'PerformanceNavigation').hasOwnProperty('set') is false
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * page/RuntimeEnabledFeatures.h:
+ (WebCore::RuntimeEnabledFeatures::performanceTimelineEnabled):
+ * page/Performance.idl:
+ * page/PerformanceEntry.idl:
+ Make a better RuntimeEnabledFeature named "PerformanceTiming" which
+ is enabled if either UserTiming or ResourceTiming is enabled. This
+ will then expose the APIs that are only useful when at least one of
+ the APIs are available.
+
+ * page/PerformanceEntry.cpp:
+ (WebCore::PerformanceEntry::name): Deleted.
+ (WebCore::PerformanceEntry::entryType): Deleted.
+ (WebCore::PerformanceEntry::startTime): Deleted.
+ (WebCore::PerformanceEntry::duration): Deleted.
+ * page/PerformanceEntry.h:
+ (WebCore::PerformanceEntry::name):
+ (WebCore::PerformanceEntry::entryType):
+ (WebCore::PerformanceEntry::startTime):
+ (WebCore::PerformanceEntry::duration):
+ Inline simple accessors.
+
+ * page/PerformanceUserTiming.cpp:
+ (WebCore::UserTiming::measure):
+ Fix a bug introduced by ExceptionOr refactoring.
+
+ (WebCore::UserTiming::clearMarks):
+ (WebCore::UserTiming::clearMeasures):
+ (WebCore::clearPerformanceEntries):
+ (WebCore::clearPeformanceEntries): Deleted.
+ Fix method name typo.
+
2017-01-27 Dan Bernstein <mitz@apple.com>
Ignore Xcode’s project.xcworkspace and userdata directories in this new project like we do
readonly attribute PerformanceTiming timing;
// https://w3c.github.io/performance-timeline/
- [EnabledAtRuntime=ResourceTiming] PerformanceEntryList getEntries();
- [EnabledAtRuntime=ResourceTiming] PerformanceEntryList getEntriesByType(DOMString entryType);
- [EnabledAtRuntime=ResourceTiming] PerformanceEntryList getEntriesByName(DOMString name, optional DOMString entryType);
+ [EnabledAtRuntime=PerformanceTimeline] PerformanceEntryList getEntries();
+ [EnabledAtRuntime=PerformanceTimeline] PerformanceEntryList getEntriesByType(DOMString entryType);
+ [EnabledAtRuntime=PerformanceTimeline] PerformanceEntryList getEntriesByName(DOMString name, optional DOMString entryType);
// https://w3c.github.io/resource-timing/
[EnabledAtRuntime=ResourceTiming] void clearResourceTimings();
{
}
-String PerformanceEntry::name() const
-{
- return m_name;
-}
-
-String PerformanceEntry::entryType() const
-{
- return m_entryType;
-}
-
-double PerformanceEntry::startTime() const
-{
- return m_startTime;
-}
-
-double PerformanceEntry::duration() const
-{
- return m_duration;
-}
-
} // namespace WebCore
#endif // ENABLE(WEB_TIMING)
public:
virtual ~PerformanceEntry();
- String name() const;
- String entryType() const;
- double startTime() const;
- double duration() const;
+ String name() const { return m_name; }
+ String entryType() const { return m_entryType; }
+ double startTime() const { return m_startTime; }
+ double duration() const { return m_duration; }
virtual bool isResource() const { return false; }
virtual bool isMark() const { return false; }
[
Conditional=WEB_TIMING,
- EnabledAtRuntime=ResourceTiming,
+ EnabledAtRuntime=PerformanceTimeline,
CustomToJSObject,
] interface PerformanceEntry {
readonly attribute DOMString name;
static NavigationTimingFunction restrictedMarkFunction(const String& markName)
{
+ // FIXME: Update this list when moving to Navigation Timing Level 2.
using MapPair = std::pair<ASCIILiteral, NavigationTimingFunction>;
static const std::array<MapPair, 21> pairs = { {
MapPair { ASCIILiteral("navigationStart"), &PerformanceTiming::navigationStart },
performanceEntryMap.set(entry->name(), Vector<RefPtr<PerformanceEntry>> { WTFMove(entry) });
}
-static void clearPeformanceEntries(PerformanceEntryMap& performanceEntryMap, const String& name)
+static void clearPerformanceEntries(PerformanceEntryMap& performanceEntryMap, const String& name)
{
if (name.isNull()) {
performanceEntryMap.clear();
void UserTiming::clearMarks(const String& markName)
{
- clearPeformanceEntries(m_marksMap, markName);
+ clearPerformanceEntries(m_marksMap, markName);
}
ExceptionOr<double> UserTiming::findExistingMarkStartTime(const String& markName)
auto startMarkResult = findExistingMarkStartTime(startMark);
if (startMarkResult.hasException())
return startMarkResult.releaseException();
- endTime = startMarkResult.releaseReturnValue();
+ startTime = startMarkResult.releaseReturnValue();
} else {
auto endMarkResult = findExistingMarkStartTime(endMark);
if (endMarkResult.hasException())
void UserTiming::clearMeasures(const String& measureName)
{
- clearPeformanceEntries(m_measuresMap, measureName);
+ clearPerformanceEntries(m_measuresMap, measureName);
}
static Vector<RefPtr<PerformanceEntry>> convertToEntrySequence(const PerformanceEntryMap& performanceEntryMap)
void setUserTimingEnabled(bool isEnabled) { m_isUserTimingEnabled = isEnabled; }
bool userTimingEnabled() const { return m_isUserTimingEnabled; }
+ bool performanceTimelineEnabled() const { return resourceTimingEnabled() || userTimingEnabled(); }
+
void setShadowDOMEnabled(bool isEnabled) { m_isShadowDOMEnabled = isEnabled; }
bool shadowDOMEnabled() const { return m_isShadowDOMEnabled; }
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * WebView/WebPreferenceKeysPrivate.h:
+ * WebView/WebPreferences.mm:
+ (+[WebPreferences initialize]):
+ (-[WebPreferences userTimingEnabled]):
+ (-[WebPreferences setUserTimingEnabled:]):
+ * WebView/WebPreferencesPrivate.h:
+ * WebView/WebView.mm:
+ (-[WebView _preferencesChanged:]):
+ Add setting for User Timing runtime enabled feature.
+
2017-01-27 Wenson Hsieh <wenson_hsieh@apple.com>
[WK1] Do not prevent the drag client from initializing on Mac
#define WebKitMediaCaptureRequiresSecureConnectionPreferenceKey @"WebKitMediaCaptureRequiresSecureConnection"
#define WebKitAttachmentElementEnabledPreferenceKey @"WebKitAttachmentElementEnabled"
#define WebKitIntersectionObserverEnabledPreferenceKey @"WebKitIntersectionObserverEnabled"
-
+#define WebKitUserTimingEnabledPreferenceKey @"WebKitUserTimingEnabled"
#if ENABLE(SUBTLE_CRYPTO)
[NSNumber numberWithBool:YES], WebKitSubtleCryptoEnabledPreferenceKey,
#endif
-
#if ENABLE(MEDIA_STREAM)
[NSNumber numberWithBool:NO], WebKitMediaStreamEnabledPreferenceKey,
#endif
-
#if ENABLE(WEB_RTC)
[NSNumber numberWithBool:NO], WebKitPeerConnectionEnabledPreferenceKey,
#endif
-
+#if ENABLE(INTERSECTION_OBSERVER)
+ @NO, WebKitIntersectionObserverEnabledPreferenceKey,
+#endif
+ @NO, WebKitUserTimingEnabledPreferenceKey,
nil];
#if !PLATFORM(IOS)
[self _setBoolValue:flag forKey:WebKitIntersectionObserverEnabledPreferenceKey];
}
+- (BOOL)userTimingEnabled
+{
+ return [self _boolValueForKey:WebKitUserTimingEnabledPreferenceKey];
+}
+
+- (void)setUserTimingEnabled:(BOOL)flag
+{
+ [self _setBoolValue:flag forKey:WebKitUserTimingEnabledPreferenceKey];
+}
+
@end
@implementation WebPreferences (WebInternal)
@property (nonatomic) BOOL attachmentElementEnabled;
@property (nonatomic) BOOL allowsInlineMediaPlaybackAfterFullscreen;
@property (nonatomic) BOOL intersectionObserverEnabled;
+@property (nonatomic) BOOL userTimingEnabled;
@end
RuntimeEnabledFeatures::sharedFeatures().setSubtleCryptoEnabled([preferences subtleCryptoEnabled]);
#endif
+ RuntimeEnabledFeatures::sharedFeatures().setUserTimingEnabled(preferences.userTimingEnabled);
+
NSTimeInterval timeout = [preferences incrementalRenderingSuppressionTimeoutInSeconds];
if (timeout > 0)
settings.setIncrementalRenderingSuppressionTimeoutInSeconds(timeout);
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * Interfaces/IWebPreferencesPrivate.idl:
+ * WebPreferenceKeysPrivate.h:
+ * WebPreferences.cpp:
+ (WebPreferences::initializeDefaultSettings):
+ (WebPreferences::setUserTimingEnabled):
+ (WebPreferences::userTimingEnabled):
+ * WebPreferences.h:
+ * WebView.cpp:
+ (WebView::notifyPreferencesChanged):
+ Add setting for User Timing runtime enabled feature.
+
2017-01-26 Chris Dumez <cdumez@apple.com>
Crash when navigating back to a page in PacheCache when one of its frames has been removed
HRESULT setApplicationId([in] BSTR applicationId);
HRESULT webAnimationsEnabled([out, retval] BOOL*);
HRESULT setWebAnimationsEnabled([in] BOOL enabled);
+ HRESULT userTimingEnabled([out, retval] BOOL*);
+ HRESULT setUserTimingEnabled([in] BOOL enabled);
}
#define WebKitModernMediaControlsEnabledPreferenceKey "WebKitModernMediaControlsEnabled"
#define WebKitWebAnimationsEnabledPreferenceKey "WebKitWebAnimationsEnabled"
+
+#define WebKitUserTimingEnabledPreferenceKey "WebKitUserTimingEnabled"
CFDictionaryAddValue(defaults, CFSTR(WebKitWebAnimationsEnabledPreferenceKey), kCFBooleanFalse);
+ CFDictionaryAddValue(defaults, CFSTR(WebKitUserTimingEnabledPreferenceKey), kCFBooleanFalse);
+
defaultSettings = defaults;
}
*enabled = boolValueForKey(WebKitWebAnimationsEnabledPreferenceKey);
return S_OK;
}
+
+HRESULT WebPreferences::setUserTimingEnabled(BOOL enabled)
+{
+ setBoolValue(WebKitUserTimingEnabledPreferenceKey, enabled);
+ return S_OK;
+}
+
+HRESULT WebPreferences::userTimingEnabled(_Out_ BOOL* enabled)
+{
+ if (!enabled)
+ return E_POINTER;
+ *enabled = boolValueForKey(WebKitUserTimingEnabledPreferenceKey);
+ return S_OK;
+}
virtual HRESULT STDMETHODCALLTYPE setApplicationId(BSTR);
virtual HRESULT STDMETHODCALLTYPE webAnimationsEnabled(_Out_ BOOL*);
virtual HRESULT STDMETHODCALLTYPE setWebAnimationsEnabled(BOOL);
+ virtual HRESULT STDMETHODCALLTYPE userTimingEnabled(_Out_ BOOL*);
+ virtual HRESULT STDMETHODCALLTYPE setUserTimingEnabled(BOOL);
// WebPreferences
RuntimeEnabledFeatures::sharedFeatures().setWebAnimationsEnabled(!!enabled);
#endif
+ hr = prefsPrivate->userTimingEnabled(&enabled);
+ if (FAILED(hr))
+ return hr;
+ RuntimeEnabledFeatures::sharedFeatures().setUserTimingEnabled(!!enabled);
+
hr = preferences->privateBrowsingEnabled(&enabled);
if (FAILED(hr))
return hr;
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * Shared/WebPreferencesDefinitions.h:
+ * UIProcess/API/C/WKPreferences.cpp:
+ (WKPreferencesSetUserTimingEnabled):
+ (WKPreferencesGetUserTimingEnabled):
+ * UIProcess/API/C/WKPreferencesRefPrivate.h:
+ * WebProcess/WebPage/WebPage.cpp:
+ (WebKit::WebPage::updatePreferences):
+ Experimental feature. Off for now while we update ResourceTiming
+ and NavigationTiming to be compatible with Performance Timing 2.
+
2017-01-28 Dan Bernstein <mitz@apple.com>
<rdar://problem/30247736> WebKit2-7604.1.5 has failed to build: error: only virtual member functions can be marked 'override'
macro(ModernMediaControlsEnabled, modernMediaControlsEnabled, Bool, bool, DEFAULT_EXPERIMENTAL_FEATURES_ENABLED, "Modern Media Controls", "Use modern media controls look") \
macro(InputEventsEnabled, inputEventsEnabled, Bool, bool, DEFAULT_EXPERIMENTAL_FEATURES_ENABLED, "Input Events", "Enable InputEvents support") \
macro(SubtleCryptoEnabled, subtleCryptoEnabled, Bool, bool, DEFAULT_EXPERIMENTAL_FEATURES_ENABLED, "SubtleCrypto", "Enable SubtleCrypto support") \
+ macro(UserTimingEnabled, userTimingEnabled, Bool, bool, false, "User Timing", "Enable UserTiming API") \
macro(WebAnimationsEnabled, webAnimationsEnabled, Bool, bool, false, "Web Animations", "Web Animations prototype") \
macro(WebGL2Enabled, webGL2Enabled, Bool, bool, DEFAULT_EXPERIMENTAL_FEATURES_ENABLED, "WebGL 2.0", "WebGL 2 prototype") \
\
return toImpl(preferencesRef)->intersectionObserverEnabled();
}
+void WKPreferencesSetUserTimingEnabled(WKPreferencesRef preferencesRef, bool flag)
+{
+ toImpl(preferencesRef)->setUserTimingEnabled(flag);
+}
+
+bool WKPreferencesGetUserTimingEnabled(WKPreferencesRef preferencesRef)
+{
+ return toImpl(preferencesRef)->userTimingEnabled();
+}
+
void WKPreferencesSetSelectionPaintingWithoutSelectionGapsEnabled(WKPreferencesRef preferencesRef, bool flag)
{
toImpl(preferencesRef)->setSelectionPaintingWithoutSelectionGapsEnabled(flag);
WK_EXPORT void WKPreferencesSetIntersectionObserverEnabled(WKPreferencesRef, bool flag);
WK_EXPORT bool WKPreferencesGetIntersectionObserverEnabled(WKPreferencesRef);
+// Defaults to false
+WK_EXPORT void WKPreferencesSetUserTimingEnabled(WKPreferencesRef, bool flag);
+WK_EXPORT bool WKPreferencesGetUserTimingEnabled(WKPreferencesRef);
+
// Defaults to true
WK_EXPORT void WKPreferencesSetSubtleCryptoEnabled(WKPreferencesRef, bool flag);
WK_EXPORT bool WKPreferencesGetSubtleCryptoEnabled(WKPreferencesRef);
RuntimeEnabledFeatures::sharedFeatures().setIntersectionObserverEnabled(store.getBoolValueForKey(WebPreferencesKey::intersectionObserverEnabledKey()));
#endif
+ RuntimeEnabledFeatures::sharedFeatures().setUserTimingEnabled(store.getBoolValueForKey(WebPreferencesKey::userTimingEnabledKey()));
+
bool processSuppressionEnabled = store.getBoolValueForKey(WebPreferencesKey::pageVisibilityBasedProcessSuppressionEnabledKey());
if (m_processSuppressionEnabled != processSuppressionEnabled) {
m_processSuppressionEnabled = processSuppressionEnabled;
2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * DumpRenderTree/mac/DumpRenderTree.mm:
+ (enableExperimentalFeatures):
+ (resetWebPreferencesToConsistentValues):
+ * DumpRenderTree/win/DumpRenderTree.cpp:
+ (enableExperimentalFeatures):
+
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
Patch Review: EWS Bubbles wrap to multiple lines but can fit on one line
https://bugs.webkit.org/show_bug.cgi?id=167519
[preferences setModernMediaControlsEnabled:YES];
// FIXME: InputEvents
[preferences setSubtleCryptoEnabled:YES];
+ [preferences setUserTimingEnabled:YES];
+ [preferences setWebAnimationsEnabled:YES];
[preferences setWebGL2Enabled:YES];
}
[preferences setMediaStreamEnabled:YES];
[preferences setPeerConnectionEnabled:YES];
- [preferences setWebAnimationsEnabled:YES];
[WebPreferences _clearNetworkLoaderSession];
[WebPreferences _setCurrentNetworkLoaderSessionCookieAcceptPolicy:NSHTTPCookieAcceptPolicyOnlyFromMainDocumentDomain];
// FIXME: ModernMediaControls
// FIXME: InputEvents
// FIXME: SubtleCrypto
+ prefsPrivate4->setUserTimingEnabled(TRUE);
prefsPrivate4->setWebAnimationsEnabled(TRUE);
// FIXME: WebGL2
}
+2017-01-28 Joseph Pecoraro <pecoraro@apple.com>
+
+ Add User Timing Experimental Feature
+ https://bugs.webkit.org/show_bug.cgi?id=167542
+ <rdar://problem/22746307>
+
+ Reviewed by Ryosuke Niwa.
+
+ * experimental-features.html:
+
2017-01-27 Dean Jackson <dino@apple.com>
Add a simple demo for Touch stylus events
return window.crypto.subtle;
}
+function testUserTiming() {
+ return window.performance.mark;
+}
+
function testWebAnimations() {
return !!window.Animation;
}
<div class="test" id="InputEvents"><p>HTML Input Events</p></div>
<div class="test" id="SubtleCrypto"><p>SubtleCrypto</p></div>
<div class="test" id="VariationFonts"><p>Variation Fonts</p></div>
+ <div class="test" id="UserTiming"><p>User Timing</p></div>
<div class="test" id="WebAnimations"><p>Web Animations</p></div>
<div class="test" id="WebGL2"><p>WebGL 2.0</p></div>
</div>