Changeset 288533 in webkit


Ignore:
Timestamp:
Jan 24, 2022 7:21:04 PM (6 months ago)
Author:
Devin Rousso
Message:

Web Inspector: Network: give the Ignore Caches button a label so it's more visible and immediately understandable
https://bugs.webkit.org/show_bug.cgi?id=235539

Reviewed by Patrick Angle.

  • UserInterface/Views/NetworkTableContentView.js:

(WI.NetworkTableContentView):
(WI.NetworkTableContentView.prototype.get navigationItems):
(WI.NetworkTableContentView.prototype._resourceCachingDisabledSettingChanged):

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Images/IgnoreCaches.svg: Deleted.
Location:
trunk/Source/WebInspectorUI
Files:
1 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebInspectorUI/ChangeLog

    r288492 r288533  
     12022-01-24  Devin Rousso  <drousso@apple.com>
     2
     3        Web Inspector: Network: give the Ignore Caches button a label so it's more visible and immediately understandable
     4        https://bugs.webkit.org/show_bug.cgi?id=235539
     5
     6        Reviewed by Patrick Angle.
     7
     8        * UserInterface/Views/NetworkTableContentView.js:
     9        (WI.NetworkTableContentView):
     10        (WI.NetworkTableContentView.prototype.get navigationItems):
     11        (WI.NetworkTableContentView.prototype._resourceCachingDisabledSettingChanged):
     12
     13        * Localizations/en.lproj/localizedStrings.js:
     14
     15        * UserInterface/Images/IgnoreCaches.svg: Deleted.
     16
    1172022-01-24  Patrick Angle  <pangle@apple.com>
    218
  • trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js

    r288470 r288533  
    489489localizedStrings["Disable Breakpoint"] = "Disable Breakpoint";
    490490localizedStrings["Disable Breakpoints"] = "Disable Breakpoints";
     491localizedStrings["Disable Caches"] = "Disable Caches";
    491492localizedStrings["Disable Descendant Breakpoints"] = "Disable Descendant Breakpoints";
    492493localizedStrings["Disable Encryption"] = "Disable Encryption";
     
    792793localizedStrings["Ignore"] = "Ignore";
    793794localizedStrings["Ignore script when debugging"] = "Ignore script when debugging";
    794 localizedStrings["Ignore the resource cache when loading resources"] = "Ignore the resource cache when loading resources";
    795795localizedStrings["Ignored"] = "Ignored";
    796796localizedStrings["Image"] = "Image";
     
    16321632localizedStrings["Use default media styles"] = "Use default media styles";
    16331633localizedStrings["Use fuzzy matching for completion suggestions"] = "Use fuzzy matching for completion suggestions";
    1634 localizedStrings["Use the resource cache when loading resources"] = "Use the resource cache when loading resources";
    16351634localizedStrings["User Agent"] = "User Agent";
    16361635localizedStrings["User Agent Style Sheet"] = "User Agent Style Sheet";
  • trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js

    r288470 r288533  
    142142        // COMPATIBILITY (iOS 10.3): Network.setDisableResourceCaching did not exist.
    143143        if (InspectorBackend.hasCommand("Network.setResourceCachingDisabled")) {
    144             let toolTipForDisableResourceCache = WI.UIString("Ignore the resource cache when loading resources");
    145             let activatedToolTipForDisableResourceCache = WI.UIString("Use the resource cache when loading resources");
    146             this._disableResourceCacheNavigationItem = new WI.ActivateButtonNavigationItem("disable-resource-cache", toolTipForDisableResourceCache, activatedToolTipForDisableResourceCache, "Images/IgnoreCaches.svg", 16, 16);
    147             this._disableResourceCacheNavigationItem.activated = WI.settings.resourceCachingDisabled.value;
    148             this._disableResourceCacheNavigationItem.visibilityPriority = WI.NavigationItem.VisibilityPriority.High;
    149             this._disableResourceCacheNavigationItem.addEventListener(WI.ButtonNavigationItem.Event.Clicked, this._toggleDisableResourceCache, this);
     144            this._disableResourceCacheNavigationItem = new WI.CheckboxNavigationItem("network-disable-resource-cache", WI.UIString("Disable Caches"), WI.settings.resourceCachingDisabled.value);
     145            this._disableResourceCacheNavigationItem.addEventListener(WI.CheckboxNavigationItem.Event.CheckedDidChange, this._toggleDisableResourceCache, this);
     146
     147            this._disableResourceCacheNavigationItemGroup = new WI.GroupNavigationItem([this._disableResourceCacheNavigationItem, new WI.DividerNavigationItem]);
     148            this._disableResourceCacheNavigationItemGroup.visibilityPriority = WI.NavigationItem.VisibilityPriority.High;
    150149
    151150            WI.settings.resourceCachingDisabled.addEventListener(WI.Setting.Event.Changed, this._resourceCachingDisabledSettingChanged, this);
     
    245244    get navigationItems()
    246245    {
    247         let items = [this._pathComponentsNavigationItemGroup, this._buttonsNavigationItemGroup];
    248         if (this._disableResourceCacheNavigationItem)
    249             items.push(this._disableResourceCacheNavigationItem);
    250         items.push(this._clearNetworkItemsNavigationItem);
     246        let items = [];
     247        if (this._disableResourceCacheNavigationItemGroup)
     248            items.push(this._disableResourceCacheNavigationItemGroup);
     249        items.push(this._pathComponentsNavigationItemGroup, this._buttonsNavigationItemGroup, this._clearNetworkItemsNavigationItem);
    251250        return items;
    252251    }
     
    16271626    _resourceCachingDisabledSettingChanged()
    16281627    {
    1629         this._disableResourceCacheNavigationItem.activated = WI.settings.resourceCachingDisabled.value;
     1628        this._disableResourceCacheNavigationItem.checked = WI.settings.resourceCachingDisabled.value;
    16301629    }
    16311630
Note: See TracChangeset for help on using the changeset viewer.