| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) IBM Corp. 2009 All rights reserved. | 2 * Copyright (C) IBM Corp. 2009 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 349 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 360 this._result = result; | 360 this._result = result; |
| 361 | 361 |
| 362 var headerElement = createElementWithClass("div", "watch-expression-head
er"); | 362 var headerElement = createElementWithClass("div", "watch-expression-head
er"); |
| 363 var deleteButton = headerElement.createChild("button", "watch-expression
-delete-button"); | 363 var deleteButton = headerElement.createChild("button", "watch-expression
-delete-button"); |
| 364 deleteButton.title = WebInspector.UIString("Delete watch expression"); | 364 deleteButton.title = WebInspector.UIString("Delete watch expression"); |
| 365 deleteButton.addEventListener("click", this._deleteWatchExpression.bind(
this), false); | 365 deleteButton.addEventListener("click", this._deleteWatchExpression.bind(
this), false); |
| 366 | 366 |
| 367 var titleElement = headerElement.createChild("div", "watch-expression-ti
tle"); | 367 var titleElement = headerElement.createChild("div", "watch-expression-ti
tle"); |
| 368 this._nameElement = WebInspector.ObjectPropertiesSection.createNameEleme
nt(this._expression); | 368 this._nameElement = WebInspector.ObjectPropertiesSection.createNameEleme
nt(this._expression); |
| 369 if (!!exceptionDetails || !result) { | 369 if (!!exceptionDetails || !result) { |
| 370 this._valueElement = createElementWithClass("span", "error-message v
alue"); | 370 this._valueElement = createElementWithClass("span", "watch-expressio
n-error value"); |
| 371 titleElement.classList.add("dimmed"); | 371 titleElement.classList.add("dimmed"); |
| 372 this._valueElement.textContent = WebInspector.UIString("<not availab
le>"); | 372 this._valueElement.textContent = WebInspector.UIString("<not availab
le>"); |
| 373 } else { | 373 } else { |
| 374 this._valueElement = WebInspector.ObjectPropertiesSection.createValu
eElementWithCustomSupport(result, !!exceptionDetails, titleElement, this._linkif
ier); | 374 this._valueElement = WebInspector.ObjectPropertiesSection.createValu
eElementWithCustomSupport(result, !!exceptionDetails, titleElement, this._linkif
ier); |
| 375 } | 375 } |
| 376 var separatorElement = createElementWithClass("span", "watch-expressions
-separator"); | 376 var separatorElement = createElementWithClass("span", "watch-expressions
-separator"); |
| 377 separatorElement.textContent = ": "; | 377 separatorElement.textContent = ": "; |
| 378 titleElement.appendChildren(this._nameElement, separatorElement, this._v
alueElement); | 378 titleElement.appendChildren(this._nameElement, separatorElement, this._v
alueElement); |
| 379 | 379 |
| 380 this._element.removeChildren(); | 380 this._element.removeChildren(); |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 450 contextMenu.appendApplicableItems(this._result); | 450 contextMenu.appendApplicableItems(this._result); |
| 451 }, | 451 }, |
| 452 | 452 |
| 453 _copyValueButtonClicked: function() | 453 _copyValueButtonClicked: function() |
| 454 { | 454 { |
| 455 InspectorFrontendHost.copyText(this._valueElement.textContent); | 455 InspectorFrontendHost.copyText(this._valueElement.textContent); |
| 456 }, | 456 }, |
| 457 | 457 |
| 458 __proto__: WebInspector.Object.prototype | 458 __proto__: WebInspector.Object.prototype |
| 459 } | 459 } |
| OLD | NEW |