| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 * @param {!WebInspector.StylesSourceMapping} mapping | 302 * @param {!WebInspector.StylesSourceMapping} mapping |
| 303 */ | 303 */ |
| 304 WebInspector.StyleFile = function(uiSourceCode, mapping) | 304 WebInspector.StyleFile = function(uiSourceCode, mapping) |
| 305 { | 305 { |
| 306 this._uiSourceCode = uiSourceCode; | 306 this._uiSourceCode = uiSourceCode; |
| 307 this._mapping = mapping; | 307 this._mapping = mapping; |
| 308 this._eventListeners = [ | 308 this._eventListeners = [ |
| 309 this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.Wor
kingCopyChanged, this._workingCopyChanged, this), | 309 this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.Wor
kingCopyChanged, this._workingCopyChanged, this), |
| 310 this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.Wor
kingCopyCommitted, this._workingCopyCommitted, this) | 310 this._uiSourceCode.addEventListener(WebInspector.UISourceCode.Events.Wor
kingCopyCommitted, this._workingCopyCommitted, this) |
| 311 ]; | 311 ]; |
| 312 this._uiSourceCode.forceLoadOnCheckContent(); | |
| 313 this._commitThrottler = new WebInspector.Throttler(WebInspector.StyleFile.up
dateTimeout); | 312 this._commitThrottler = new WebInspector.Throttler(WebInspector.StyleFile.up
dateTimeout); |
| 314 this._terminated = false; | 313 this._terminated = false; |
| 315 } | 314 } |
| 316 | 315 |
| 317 WebInspector.StyleFile.updateTimeout = 200; | 316 WebInspector.StyleFile.updateTimeout = 200; |
| 318 | 317 |
| 319 WebInspector.StyleFile.prototype = { | 318 WebInspector.StyleFile.prototype = { |
| 320 /** | 319 /** |
| 321 * @param {!WebInspector.Event} event | 320 * @param {!WebInspector.Event} event |
| 322 */ | 321 */ |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 370 }, | 369 }, |
| 371 | 370 |
| 372 dispose: function() | 371 dispose: function() |
| 373 { | 372 { |
| 374 if (this._terminated) | 373 if (this._terminated) |
| 375 return; | 374 return; |
| 376 this._terminated = true; | 375 this._terminated = true; |
| 377 WebInspector.EventTarget.removeEventListeners(this._eventListeners); | 376 WebInspector.EventTarget.removeEventListeners(this._eventListeners); |
| 378 } | 377 } |
| 379 } | 378 } |
| OLD | NEW |