Changeset 49495 in webkit


Ignore:
Timestamp:
Oct 13, 2009 1:26:34 AM (14 years ago)
Author:
pfeldman@chromium.org
Message:

2009-10-12 Alexander Pavlov <apavlov@chromium.org>

Reviewed by Timothy Hatcher.
Alter profile link format to enable multiple profile types
https://bugs.webkit.org/show_bug.cgi?id=30253

The new profile URL includes the profile type along with the
profile title and uid.

  • inspector/InspectorController.cpp: (WebCore::InspectorController::addProfileFinishedMessageToConsole): (WebCore::InspectorController::addStartProfilingMessageToConsole):
  • inspector/front-end/inspector.js: (WebInspector.documentClick.followLink): (WebInspector.documentClick): (WebInspector.linkifyStringAsFragment):
Location:
trunk/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r49494 r49495  
     12009-10-12  Alexander Pavlov  <apavlov@chromium.org>
     2
     3        Reviewed by Timothy Hatcher.
     4        Alter profile link format to enable multiple profile types
     5        https://bugs.webkit.org/show_bug.cgi?id=30253
     6
     7        The new profile URL includes the profile type along with the
     8        profile title and uid.
     9
     10        * inspector/InspectorController.cpp:
     11        (WebCore::InspectorController::addProfileFinishedMessageToConsole):
     12        (WebCore::InspectorController::addStartProfilingMessageToConsole):
     13        * inspector/front-end/inspector.js:
     14        (WebInspector.documentClick.followLink):
     15        (WebInspector.documentClick):
     16        (WebInspector.linkifyStringAsFragment):
     17
    1182009-10-12  Alexander Pavlov  <apavlov@chromium.org>
    219
  • trunk/WebCore/inspector/InspectorController.cpp

    r49327 r49495  
    108108
    109109static const char* const UserInitiatedProfileName = "org.webkit.profiles.user-initiated";
     110static const char* const CPUProfileType = "CPU";
    110111static const char* const resourceTrackingEnabledSettingName = "resourceTrackingEnabled";
    111112static const char* const debuggerEnabledSettingName = "debuggerEnabled";
     
    13611362
    13621363    UString message = "Profile \"webkit-profile://";
     1364    message += encodeWithURLEscapeSequences(CPUProfileType);
     1365    message += "/";
    13631366    message += encodeWithURLEscapeSequences(profile->title());
    1364     message += "/";
     1367    message += "#";
    13651368    message += UString::from(profile->uid());
    13661369    message += "\" finished.";
     
    13711374{
    13721375    UString message = "Profile \"webkit-profile://";
     1376    message += encodeWithURLEscapeSequences(CPUProfileType);
     1377    message += "/";
    13731378    message += encodeWithURLEscapeSequences(title);
    1374     message += "/0\" started.";
     1379    message += "#0\" started.";
    13751380    addMessageToConsole(JSMessageSource, LogMessageType, LogMessageLevel, message, lineNumber, sourceURL);
    13761381}
  • trunk/WebCore/inspector/front-end/inspector.js

    r49493 r49495  
    555555            WebInspector.showResourceForURL(anchor.href, anchor.lineNumber, anchor.preferredPanel);
    556556        } else {
    557             var profileStringRegEx = new RegExp("webkit-profile://.+/([0-9]+)");
     557            var profileStringRegEx = new RegExp("webkit-profile://.+/.+#([0-9]+)");
    558558            var profileString = profileStringRegEx.exec(anchor.href);
    559559            if (profileString)
     
    13761376        container.appendChild(document.createTextNode(nonLink));
    13771377
    1378         var profileStringRegEx = new RegExp("webkit-profile://(.+)/[0-9]+");
     1378        var profileStringRegEx = new RegExp("webkit-profile://.+/(.+)#[0-9]+");
    13791379        var profileStringMatches = profileStringRegEx.exec(title);
    13801380        var profileTitle;
Note: See TracChangeset for help on using the changeset viewer.