Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/workspace/UISourceCode.js

Issue 1954423002: DevTools: introduce CSSStyleSheetHeader.originalContentProvider() method (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@simplify-network-project
Patch Set: address comments Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/sources/ScriptFormatterEditorAction.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 /** 547 /**
548 * @override 548 * @override
549 * @param {string} query 549 * @param {string} query
550 * @param {boolean} caseSensitive 550 * @param {boolean} caseSensitive
551 * @param {boolean} isRegex 551 * @param {boolean} isRegex
552 * @param {function(!Array.<!WebInspector.ContentProvider.SearchMatch>)} cal lback 552 * @param {function(!Array.<!WebInspector.ContentProvider.SearchMatch>)} cal lback
553 */ 553 */
554 searchInContent: function(query, caseSensitive, isRegex, callback) 554 searchInContent: function(query, caseSensitive, isRegex, callback)
555 { 555 {
556 var content = this.content(); 556 var content = this.content();
557 if (content) { 557 if (!content) {
558 WebInspector.StaticContentProvider.searchInContent(content, query, c aseSensitive, isRegex, callback); 558 this._project.searchInFileContent(this, query, caseSensitive, isRege x, callback);
559 return; 559 return;
560 } 560 }
561 561
562 this._project.searchInFileContent(this, query, caseSensitive, isRegex, c allback); 562 // searchInContent should call back later.
563 setTimeout(doSearch.bind(null, content), 0);
564
565 /**
566 * @param {string} content
567 */
568 function doSearch(content)
569 {
570 callback(WebInspector.ContentProvider.performSearchInContent(content , query, caseSensitive, isRegex));
571 }
563 }, 572 },
564 573
565 /** 574 /**
566 * @param {?string} content 575 * @param {?string} content
567 */ 576 */
568 _fireContentAvailable: function(content) 577 _fireContentAvailable: function(content)
569 { 578 {
570 this._contentLoaded = true; 579 this._contentLoaded = true;
571 this._content = content; 580 this._content = content;
572 581
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after
966 }, 975 },
967 976
968 /** 977 /**
969 * @return {*} 978 * @return {*}
970 */ 979 */
971 data: function() 980 data: function()
972 { 981 {
973 return this._data; 982 return this._data;
974 } 983 }
975 } 984 }
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/sources/ScriptFormatterEditorAction.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698