Changeset 85588 in webkit


Ignore:
Timestamp:
May 3, 2011 12:54:35 AM (13 years ago)
Author:
pfeldman@chromium.org
Message:

2011-05-03 Pavel Feldman <pfeldman@chromium.org>

Reviewed by Yury Semikhatsky.

Web Inspector: combine toolbar icon images.
https://bugs.webkit.org/show_bug.cgi?id=59931

  • WebCore.gypi:
  • inspector/front-end/Images/auditsIcon.png: Removed.
  • inspector/front-end/Images/consoleIcon.png: Removed.
  • inspector/front-end/Images/elementsIcon.png: Removed.
  • inspector/front-end/Images/networkIcon.png: Removed.
  • inspector/front-end/Images/profilesIcon.png: Removed.
  • inspector/front-end/Images/resourcesIcon.png: Removed.
  • inspector/front-end/Images/scriptsIcon.png: Removed.
  • inspector/front-end/Images/timelineIcon.png: Removed.
  • inspector/front-end/Images/toolbarIcons.png: Added.
  • inspector/front-end/Images/toolbarIconsSmall.png: Added.
  • inspector/front-end/WebKit.qrc:
  • inspector/front-end/inspector.css: (.toolbar-icon): (#toolbar-dropdown .toolbar-icon): (.toolbar-item:active .toolbar-icon): (#toolbar-dropdown .toolbar-item:active .toolbar-icon): (.toolbar-item.elements .toolbar-icon): (.toolbar-item.resources .toolbar-icon): (#toolbar-dropdown .toolbar-item.resources .toolbar-icon): (.toolbar-item.network .toolbar-icon): (#toolbar-dropdown .toolbar-item.network .toolbar-icon): (.toolbar-item.scripts .toolbar-icon): (#toolbar-dropdown .toolbar-item.scripts .toolbar-icon): (.toolbar-item.timeline .toolbar-icon): (#toolbar-dropdown .toolbar-item.timeline .toolbar-icon): (.toolbar-item.profiles .toolbar-icon): (#toolbar-dropdown .toolbar-item.profiles .toolbar-icon): (.toolbar-item.audits .toolbar-icon): (#toolbar-dropdown .toolbar-item.audits .toolbar-icon): (.toolbar-item.console .toolbar-icon): (#toolbar-dropdown .toolbar-item.console .toolbar-icon): (.status-bar-item > .glyph):
Location:
trunk/Source/WebCore
Files:
2 added
8 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r85587 r85588  
     12011-05-03  Pavel Feldman  <pfeldman@chromium.org>
     2
     3        Reviewed by Yury Semikhatsky.
     4
     5        Web Inspector: combine toolbar icon images.
     6        https://bugs.webkit.org/show_bug.cgi?id=59931
     7
     8        * WebCore.gypi:
     9        * inspector/front-end/Images/auditsIcon.png: Removed.
     10        * inspector/front-end/Images/consoleIcon.png: Removed.
     11        * inspector/front-end/Images/elementsIcon.png: Removed.
     12        * inspector/front-end/Images/networkIcon.png: Removed.
     13        * inspector/front-end/Images/profilesIcon.png: Removed.
     14        * inspector/front-end/Images/resourcesIcon.png: Removed.
     15        * inspector/front-end/Images/scriptsIcon.png: Removed.
     16        * inspector/front-end/Images/timelineIcon.png: Removed.
     17        * inspector/front-end/Images/toolbarIcons.png: Added.
     18        * inspector/front-end/Images/toolbarIconsSmall.png: Added.
     19        * inspector/front-end/WebKit.qrc:
     20        * inspector/front-end/inspector.css:
     21        (.toolbar-icon):
     22        (#toolbar-dropdown .toolbar-icon):
     23        (.toolbar-item:active .toolbar-icon):
     24        (#toolbar-dropdown .toolbar-item:active .toolbar-icon):
     25        (.toolbar-item.elements .toolbar-icon):
     26        (.toolbar-item.resources .toolbar-icon):
     27        (#toolbar-dropdown .toolbar-item.resources .toolbar-icon):
     28        (.toolbar-item.network .toolbar-icon):
     29        (#toolbar-dropdown .toolbar-item.network .toolbar-icon):
     30        (.toolbar-item.scripts .toolbar-icon):
     31        (#toolbar-dropdown .toolbar-item.scripts .toolbar-icon):
     32        (.toolbar-item.timeline .toolbar-icon):
     33        (#toolbar-dropdown .toolbar-item.timeline .toolbar-icon):
     34        (.toolbar-item.profiles .toolbar-icon):
     35        (#toolbar-dropdown .toolbar-item.profiles .toolbar-icon):
     36        (.toolbar-item.audits .toolbar-icon):
     37        (#toolbar-dropdown .toolbar-item.audits .toolbar-icon):
     38        (.toolbar-item.console .toolbar-icon):
     39        (#toolbar-dropdown .toolbar-item.console .toolbar-icon):
     40        (.status-bar-item > .glyph):
     41
    1422011-05-03  Pavel Feldman  <pfeldman@chromium.org>
    243
  • trunk/Source/WebCore/WebCore.gypi

    r85587 r85588  
    62266226        'webinspector_image_files': [
    62276227            'inspector/front-end/Images/applicationCache.png',
    6228             'inspector/front-end/Images/auditsIcon.png',
    62296228            'inspector/front-end/Images/back.png',
    62306229            'inspector/front-end/Images/breakpointBorder.png',
     
    62346233            'inspector/front-end/Images/checker.png',
    62356234            'inspector/front-end/Images/closeButtons.png',
    6236             'inspector/front-end/Images/consoleIcon.png',
    62376235            'inspector/front-end/Images/cookie.png',
    62386236            'inspector/front-end/Images/database.png',
     
    62526250            'inspector/front-end/Images/disclosureTriangleSmallRightDownWhite.png',
    62536251            'inspector/front-end/Images/disclosureTriangleSmallRightWhite.png',
    6254             'inspector/front-end/Images/elementsIcon.png',
    62556252            'inspector/front-end/Images/errorIcon.png',
    62566253            'inspector/front-end/Images/errorMediumIcon.png',
     
    62666263            'inspector/front-end/Images/graphLabelCalloutRight.png',
    62676264            'inspector/front-end/Images/localStorage.png',
    6268             'inspector/front-end/Images/networkIcon.png',
    62696265            'inspector/front-end/Images/paneAddButtons.png',
    62706266            'inspector/front-end/Images/paneBottomGrow.png',
     
    62766272            'inspector/front-end/Images/profileGroupIcon.png',
    62776273            'inspector/front-end/Images/profileIcon.png',
    6278             'inspector/front-end/Images/profilesIcon.png',
    62796274            'inspector/front-end/Images/profileSmallIcon.png',
    62806275            'inspector/front-end/Images/profilesSilhouette.png',
     
    62876282            'inspector/front-end/Images/resourcePlainIcon.png',
    62886283            'inspector/front-end/Images/resourcePlainIconSmall.png',
    6289             'inspector/front-end/Images/resourcesIcon.png',
    62906284            'inspector/front-end/Images/resourcesSizeGraphIcon.png',
    62916285            'inspector/front-end/Images/resourcesTimeGraphIcon.png',
    6292             'inspector/front-end/Images/scriptsIcon.png',
    62936286            'inspector/front-end/Images/scriptsSilhouette.png',
    62946287            'inspector/front-end/Images/searchSmallBlue.png',
     
    63286321            'inspector/front-end/Images/timelineHollowPillRed.png',
    63296322            'inspector/front-end/Images/timelineHollowPillYellow.png',
    6330             'inspector/front-end/Images/timelineIcon.png',
    63316323            'inspector/front-end/Images/timelineBarBlue.png',
    63326324            'inspector/front-end/Images/timelineBarGray.png',
     
    63456337            'inspector/front-end/Images/timelinePillRed.png',
    63466338            'inspector/front-end/Images/timelinePillYellow.png',
     6339            'inspector/front-end/Images/toolbarIcons.png',
     6340            'inspector/front-end/Images/toolbarIconsSmall.png',
    63476341            'inspector/front-end/Images/toolbarItemSelected.png',
    63486342            'inspector/front-end/Images/trackHoriz.png',
  • trunk/Source/WebCore/inspector/front-end/Toolbar.js

    r79306 r85588  
    4343
    4444WebInspector.Toolbar.prototype = {
     45    set attached(attached)
     46    {
     47        if (attached)
     48            this.element.addStyleClass("toolbar-small");
     49        else
     50            this.element.removeStyleClass("toolbar-small");
     51        this._updateDropdownButtonAndHideDropdown();
     52    },
     53
    4554    resize: function()
    4655    {
     
    166175    this.element = document.createElement("div");
    167176    this.element.id = "toolbar-dropdown";
     177    this.element.className = "toolbar-small";
    168178    this._contentElement = this.element.createChild("div", "scrollable-content");
    169179    this._contentElement.tabIndex = 0;
  • trunk/Source/WebCore/inspector/front-end/WebKit.qrc

    r85587 r85588  
    139139    <file>textViewer.css</file>
    140140    <file>Images/applicationCache.png</file>
    141     <file>Images/auditsIcon.png</file>
    142141    <file>Images/back.png</file>
    143142    <file>Images/breakpointBorder.png</file>
     
    148147    <file>Images/closeButtons.png</file>
    149148    <file>Images/cookie.png</file>
    150     <file>Images/consoleIcon.png</file>
    151149    <file>Images/database.png</file>
    152150    <file>Images/databaseTable.png</file>
     
    165163    <file>Images/disclosureTriangleSmallRightDownWhite.png</file>
    166164    <file>Images/disclosureTriangleSmallRightWhite.png</file>
    167     <file>Images/elementsIcon.png</file>
    168165    <file>Images/errorIcon.png</file>
    169166    <file>Images/errorMediumIcon.png</file>
     
    179176    <file>Images/graphLabelCalloutRight.png</file>
    180177    <file>Images/localStorage.png</file>
    181     <file>Images/networkIcon.png</file>
    182178    <file>Images/paneAddButtons.png</file>
    183179    <file>Images/paneBottomGrow.png</file>
     
    189185    <file>Images/profileGroupIcon.png</file>
    190186    <file>Images/profileIcon.png</file>
    191     <file>Images/profilesIcon.png</file>
    192187    <file>Images/profileSmallIcon.png</file>
    193188    <file>Images/profilesSilhouette.png</file>
     
    200195    <file>Images/resourcePlainIcon.png</file>
    201196    <file>Images/resourcePlainIconSmall.png</file>
    202     <file>Images/resourcesIcon.png</file>
    203197    <file>Images/resourcesSizeGraphIcon.png</file>
    204198    <file>Images/resourcesTimeGraphIcon.png</file>
    205     <file>Images/scriptsIcon.png</file>
    206199    <file>Images/scriptsSilhouette.png</file>
    207200    <file>Images/searchSmallBlue.png</file>
     
    250243    <file>Images/timelineHollowPillRed.png</file>
    251244    <file>Images/timelineHollowPillYellow.png</file>
    252     <file>Images/timelineIcon.png</file>
    253245    <file>Images/timelinePillBlue.png</file>
    254246    <file>Images/timelinePillGray.png</file>
     
    258250    <file>Images/timelinePillRed.png</file>
    259251    <file>Images/timelinePillYellow.png</file>
     252    <file>Images/toolbarIcons.png</file>
     253    <file>Images/toolbarIconsSmall.png</file>
    260254    <file>Images/toolbarItemSelected.png</file>
    261255    <file>Images/trackHoriz.png</file>
  • trunk/Source/WebCore/inspector/front-end/inspector.css

    r85587 r85588  
    132132    width: 32px;
    133133    height: 32px;
    134     -webkit-background-size: 100% auto;
    135 }
    136 
    137 body.attached .toolbar-icon,
    138 #toolbar-dropdown .toolbar-icon {
     134    background-image: url(Images/toolbarIcons.png);
     135}
     136
     137.toolbar-small .toolbar-icon {
    139138    width: 24px;
    140139    height: 24px;
    141140    vertical-align: middle;
     141    background-image: url(Images/toolbarIconsSmall.png);
    142142}
    143143
    144144.toolbar-item:active .toolbar-icon {
    145     background-position: 0 32px;
    146 }
    147 
    148 body.attached .toolbar-item:active .toolbar-icon {
    149     background-position: 0 24px;
     145    background-position-y: 32px;
     146}
     147
     148.toolbar-small .toolbar-item:active .toolbar-icon {
     149    background-position-y: 24px;
    150150}
    151151
     
    160160}
    161161
    162 body.attached .toolbar-label,
    163 #toolbar-dropdown .toolbar-label {
     162.toolbar-small .toolbar-label {
    164163    display: inline-block;
    165164    margin-left: 3px;
     
    254253}
    255254
    256 #toolbar-dropdown .toolbar-item:active .toolbar-icon {
    257     background-position: 0 24px;
    258 }
    259 
    260255.scrollable-content {
    261256    position: static;
     
    314309
    315310.toolbar-item.elements .toolbar-icon {
    316     background-image: url(Images/elementsIcon.png);
     311    background-position-x: 0;
    317312}
    318313
    319314.toolbar-item.resources .toolbar-icon {
    320     background-image: url(Images/resourcesIcon.png);
     315    background-position-x: -32px;
     316}
     317
     318.toolbar-small .toolbar-item.resources .toolbar-icon {
     319    background-position-x: -24px;
    321320}
    322321
    323322.toolbar-item.network .toolbar-icon {
    324     background-image: url(Images/networkIcon.png);
     323    background-position-x: -64px;
     324}
     325
     326.toolbar-small .toolbar-item.network .toolbar-icon {
     327    background-position-x: -48px;
    325328}
    326329
    327330.toolbar-item.scripts .toolbar-icon {
    328     background-image: url(Images/scriptsIcon.png);
     331    background-position-x: -96px;
     332}
     333
     334.toolbar-small .toolbar-item.scripts .toolbar-icon {
     335    background-position-x: -72px;
    329336}
    330337
    331338.toolbar-item.timeline .toolbar-icon {
    332     background-image: url(Images/timelineIcon.png);
     339    background-position-x: -128px;
     340}
     341
     342.toolbar-small .toolbar-item.timeline .toolbar-icon {
     343    background-position-x: -96px;
    333344}
    334345
    335346.toolbar-item.profiles .toolbar-icon {
    336     background-image: url(Images/profilesIcon.png);
     347    background-position-x: -160px;
     348}
     349
     350.toolbar-small .toolbar-item.profiles .toolbar-icon {
     351    background-position-x: -120px;
    337352}
    338353
    339354.toolbar-item.audits .toolbar-icon {
    340     background-image: url(Images/auditsIcon.png);
     355    background-position-x: -192px;
     356}
     357
     358.toolbar-small .toolbar-item.audits .toolbar-icon {
     359    background-position-x: -144px;
    341360}
    342361
    343362.toolbar-item.console .toolbar-icon {
    344     background-image: url(Images/consoleIcon.png);
     363    background-position-x: -224px;
     364}
     365
     366.toolbar-small .toolbar-item.console .toolbar-icon {
     367    background-position-x: -168px;
    345368}
    346369
     
    523546
    524547.status-bar-item > .glyph {
    525     -webkit-mask-image: url(Images/statusbarButtonGlyphs.png);
     548    -webkit-mask-image: url(Images/statusBarButtonGlyphs.png);
    526549}
    527550
  • trunk/Source/WebCore/inspector/front-end/inspector.js

    r85587 r85588  
    2929 */
    3030
    31 // Keep this ; so that concatenated version of the script worked.
    32 ;(function preloadImages()
    33 {
    34     (new Image()).src = "Images/statusbarButtonGlyphs.png";
    35 })();
    36 
    3731var WebInspector = {
    3832    resources: {},
     
    206200        // This may be called before onLoadedDone, hence the bulk of inspector objects may
    207201        // not be created yet.
     202        if (WebInspector.toolbar)
     203            WebInspector.toolbar.attached = x;
     204
    208205        if (WebInspector.searchController)
    209206            WebInspector.searchController.updateSearchLabel();
     
    445442    this._panelHistory = new WebInspector.PanelHistory();
    446443    this.toolbar = new WebInspector.Toolbar();
     444    this.toolbar.attached = WebInspector.attached;
    447445
    448446    this.panelOrder = [];
Note: See TracChangeset for help on using the changeset viewer.