OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2010 Apple Inc. All rights reserved. |
3 * Copyright (C) 2009 Joseph Pecoraro | 3 * Copyright (C) 2009 Joseph Pecoraro |
4 * Copyright (C) 2013 Samsung Electronics. All rights reserved. | 4 * Copyright (C) 2013 Samsung Electronics. All rights reserved. |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 1188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1199 }, | 1199 }, |
1200 | 1200 |
1201 /** | 1201 /** |
1202 * @override | 1202 * @override |
1203 */ | 1203 */ |
1204 onattach: function() | 1204 onattach: function() |
1205 { | 1205 { |
1206 WebInspector.BaseStorageTreeElement.prototype.onattach.call(this); | 1206 WebInspector.BaseStorageTreeElement.prototype.onattach.call(this); |
1207 | 1207 |
1208 if (this._resource.type === WebInspector.resourceTypes.Image) { | 1208 if (this._resource.type === WebInspector.resourceTypes.Image) { |
1209 var iconElement = document.createElementWithClass("div", "icon"); | 1209 var iconElement = createElementWithClass("div", "icon"); |
1210 var previewImage = iconElement.createChild("img", "image-resource-ic
on-preview"); | 1210 var previewImage = iconElement.createChild("img", "image-resource-ic
on-preview"); |
1211 this._resource.populateImageSource(previewImage); | 1211 this._resource.populateImageSource(previewImage); |
1212 this.listItemElement.replaceChild(iconElement, this.imageElement); | 1212 this.listItemElement.replaceChild(iconElement, this.imageElement); |
1213 } | 1213 } |
1214 | 1214 |
1215 this._statusElement = document.createElementWithClass("div", "status"); | 1215 this._statusElement = createElementWithClass("div", "status"); |
1216 this.listItemElement.insertBefore(this._statusElement, this.titleElement
); | 1216 this.listItemElement.insertBefore(this._statusElement, this.titleElement
); |
1217 | 1217 |
1218 this.listItemElement.draggable = true; | 1218 this.listItemElement.draggable = true; |
1219 this.listItemElement.addEventListener("dragstart", this._ondragstart.bin
d(this), false); | 1219 this.listItemElement.addEventListener("dragstart", this._ondragstart.bin
d(this), false); |
1220 this.listItemElement.addEventListener("contextmenu", this._handleContext
MenuEvent.bind(this), true); | 1220 this.listItemElement.addEventListener("contextmenu", this._handleContext
MenuEvent.bind(this), true); |
1221 | 1221 |
1222 this._updateErrorsAndWarningsBubbles(); | 1222 this._updateErrorsAndWarningsBubbles(); |
1223 }, | 1223 }, |
1224 | 1224 |
1225 /** | 1225 /** |
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2180 | 2180 |
2181 WebInspector.ResourcesPanelFactory.prototype = { | 2181 WebInspector.ResourcesPanelFactory.prototype = { |
2182 /** | 2182 /** |
2183 * @return {!WebInspector.Panel} | 2183 * @return {!WebInspector.Panel} |
2184 */ | 2184 */ |
2185 createPanel: function() | 2185 createPanel: function() |
2186 { | 2186 { |
2187 return WebInspector.ResourcesPanel._instance(); | 2187 return WebInspector.ResourcesPanel._instance(); |
2188 } | 2188 } |
2189 } | 2189 } |
OLD | NEW |