Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
| 4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
| 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 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 367 this._searchResults = new Array(resultCount); | 367 this._searchResults = new Array(resultCount); |
| 368 this._currentSearchResultIndex = -1; | 368 this._currentSearchResultIndex = -1; |
| 369 if (shouldJump) | 369 if (shouldJump) |
| 370 this.jumpToNextSearchResult(); | 370 this.jumpToNextSearchResult(); |
| 371 } | 371 } |
| 372 WebInspector.domAgent.performSearch(whitespaceTrimmedQuery, resultCountC allback.bind(this)); | 372 WebInspector.domAgent.performSearch(whitespaceTrimmedQuery, resultCountC allback.bind(this)); |
| 373 }, | 373 }, |
| 374 | 374 |
| 375 _contextMenuEventFired: function(event) | 375 _contextMenuEventFired: function(event) |
| 376 { | 376 { |
| 377 function toggleWordWrap() | |
| 378 { | |
| 379 WebInspector.settings.domWordWrap.set(!WebInspector.settings.domWord Wrap.get()); | |
| 380 } | |
| 381 | |
| 382 var contextMenu = new WebInspector.ContextMenu(event); | 377 var contextMenu = new WebInspector.ContextMenu(event); |
| 383 this.treeOutline.populateContextMenu(contextMenu, event); | 378 this.treeOutline.populateContextMenu(contextMenu, event); |
| 384 | |
| 385 contextMenu.appendSeparator(); | |
| 386 contextMenu.appendCheckboxItem(WebInspector.UIString(WebInspector.useLow erCaseMenuTitles() ? "Word wrap" : "Word Wrap"), toggleWordWrap, WebInspector.se ttings.domWordWrap.get()); | |
|
vsevik
2014/03/20 13:31:09
Why do you remove it? This might be useful.
Anyway
| |
| 387 | |
| 388 contextMenu.show(); | 379 contextMenu.show(); |
| 389 }, | 380 }, |
| 390 | 381 |
| 391 _domWordWrapSettingChanged: function(event) | 382 _domWordWrapSettingChanged: function(event) |
| 392 { | 383 { |
| 393 if (event.data) | 384 if (event.data) |
| 394 this.contentElement.classList.remove("nowrap"); | 385 this.contentElement.classList.remove("nowrap"); |
| 395 else | 386 else |
| 396 this.contentElement.classList.add("nowrap"); | 387 this.contentElement.classList.add("nowrap"); |
| 397 | 388 |
| (...skipping 948 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1346 return; | 1337 return; |
| 1347 | 1338 |
| 1348 if (WebInspector.inspectElementModeController && WebInspector.inspectEle mentModeController.enabled()) { | 1339 if (WebInspector.inspectElementModeController && WebInspector.inspectEle mentModeController.enabled()) { |
| 1349 InspectorFrontendHost.bringToFront(); | 1340 InspectorFrontendHost.bringToFront(); |
| 1350 WebInspector.inspectElementModeController.disable(); | 1341 WebInspector.inspectElementModeController.disable(); |
| 1351 } | 1342 } |
| 1352 | 1343 |
| 1353 /** @type {!WebInspector.ElementsPanel} */ (WebInspector.inspectorView.p anel("elements")).revealAndSelectNode(node.id); | 1344 /** @type {!WebInspector.ElementsPanel} */ (WebInspector.inspectorView.p anel("elements")).revealAndSelectNode(node.id); |
| 1354 } | 1345 } |
| 1355 } | 1346 } |
| OLD | NEW |