Stop using FeatureCounter to log navigation types
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jan 2015 00:58:42 +0000 (00:58 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jan 2015 00:58:42 +0000 (00:58 +0000)
https://bugs.webkit.org/show_bug.cgi?id=140642

Reviewed by Andreas Kling.

Stop using FeatureCounter to log navigation types now that
DiagnosticLoggingClient is working on iOS.

* loader/FrameLoader.cpp:
(WebCore::logNavigation):
* platform/FeatureCounterKeys.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@178684 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/loader/FrameLoader.cpp
Source/WebCore/platform/FeatureCounterKeys.h

index aaafbbb..5639fdd 100644 (file)
@@ -1,3 +1,17 @@
+2015-01-19  Chris Dumez  <cdumez@apple.com>
+
+        Stop using FeatureCounter to log navigation types
+        https://bugs.webkit.org/show_bug.cgi?id=140642
+
+        Reviewed by Andreas Kling.
+
+        Stop using FeatureCounter to log navigation types now that
+        DiagnosticLoggingClient is working on iOS.
+
+        * loader/FrameLoader.cpp:
+        (WebCore::logNavigation):
+        * platform/FeatureCounterKeys.h:
+
 2015-01-19  Andreas Kling  <akling@apple.com>
 
         LayoutState and subtree layout code should use RenderElement.
index a898e34..700cf54 100644 (file)
@@ -58,7 +58,6 @@
 #include "Event.h"
 #include "EventHandler.h"
 #include "EventNames.h"
-#include "FeatureCounter.h"
 #include "FloatRect.h"
 #include "FormState.h"
 #include "FormSubmission.h"
@@ -1373,35 +1372,27 @@ void FrameLoader::load(DocumentLoader* newDocumentLoader)
 
 static void logNavigation(MainFrame& frame, FrameLoadType type)
 {
-    const char* featureCounterKey;
     String navigationDescription;
     switch (type) {
     case FrameLoadType::Standard:
-        featureCounterKey = FeatureCounterNavigationStandardKey;
         navigationDescription = ASCIILiteral("standard");
         break;
     case FrameLoadType::Back:
-        featureCounterKey = FeatureCounterNavigationBackKey;
         navigationDescription = ASCIILiteral("back");
         break;
     case FrameLoadType::Forward:
-        featureCounterKey = FeatureCounterNavigationForwardKey;
         navigationDescription = ASCIILiteral("forward");
         break;
     case FrameLoadType::IndexedBackForward:
-        featureCounterKey = FeatureCounterNavigationIndexedBackForwardKey;
         navigationDescription = ASCIILiteral("indexedBackForward");
         break;
     case FrameLoadType::Reload:
-        featureCounterKey = FeatureCounterNavigationReloadKey;
         navigationDescription = ASCIILiteral("reload");
         break;
     case FrameLoadType::Same:
-        featureCounterKey = FeatureCounterNavigationSameKey;
         navigationDescription = ASCIILiteral("same");
         break;
     case FrameLoadType::ReloadFromOrigin:
-        featureCounterKey = FeatureCounterNavigationReloadFromOriginKey;
         navigationDescription = ASCIILiteral("reloadFromOrigin");
         break;
     case FrameLoadType::Replace:
@@ -1413,8 +1404,6 @@ static void logNavigation(MainFrame& frame, FrameLoadType type)
         if (auto* client = frame.diagnosticLoggingClient())
             client->logDiagnosticMessage(DiagnosticLoggingKeys::navigationKey(), navigationDescription);
     }
-    // FIXME: Remove once DiagnosticLoggingClient works on iOS.
-    FEATURE_COUNTER_INCREMENT_KEY(frame.page(), featureCounterKey);
 }
 
 void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType type, PassRefPtr<FormState> prpFormState, AllowNavigationToInvalidURL allowNavigationToInvalidURL)
index 00ae8b6..6b997ae 100644 (file)
@@ -74,15 +74,6 @@ static const char FeatureCounterMediaAudioElementLoadingKey[] = "com.apple.WebKi
 static const char FeatureCounterMediaVideoElementPlayedKey[] = "com.apple.WebKit.media.video.played";
 static const char FeatureCounterMediaAudioElementPlayedKey[] = "com.apple.WebKit.media.audio.played";
 
-// Navigation types.
-static const char FeatureCounterNavigationStandardKey[] = "com.apple.WebKit.navigation.standard";
-static const char FeatureCounterNavigationBackKey[] = "com.apple.WebKit.navigation.back";
-static const char FeatureCounterNavigationForwardKey[] = "com.apple.WebKit.navigation.forward";
-static const char FeatureCounterNavigationIndexedBackForwardKey[] = "com.apple.WebKit.navigation.indexedBackForward";
-static const char FeatureCounterNavigationReloadKey[] = "com.apple.WebKit.navigation.reload";
-static const char FeatureCounterNavigationSameKey[] = "com.apple.WebKit.navigation.same";
-static const char FeatureCounterNavigationReloadFromOriginKey[] = "com.apple.WebKit.navigation.reloadFromOrigin";
-
 // Resource types.
 static const char FeatureCounterResourceLoadedFontKey[] = "com.apple.WebKit.resource.loaded.font";
 static const char FeatureCounterResourceLoadedImageKey[] = "com.apple.WebKit.resource.loaded.image";