OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 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 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 // First try creating regex if user knows the / / hint. | 71 // First try creating regex if user knows the / / hint. |
72 try { | 72 try { |
73 if (/^\/.*\/$/.test(query)) | 73 if (/^\/.*\/$/.test(query)) |
74 regex = new RegExp(query.substring(1, query.length - 1)); | 74 regex = new RegExp(query.substring(1, query.length - 1)); |
75 } catch (e) { | 75 } catch (e) { |
76 // Silent catch. | 76 // Silent catch. |
77 } | 77 } |
78 | 78 |
79 // Otherwise just do case-insensitive search. | 79 // Otherwise just do case-insensitive search. |
80 if (!regex) | 80 if (!regex) |
81 regex = createSearchRegex(query); | 81 regex = createSearchRegex(query, "i"); |
82 | 82 |
83 return regex; | 83 return regex; |
84 } | 84 } |
85 | 85 |
86 | 86 |
87 WebInspector.SourceFrame.prototype = { | 87 WebInspector.SourceFrame.prototype = { |
88 show: function(parentElement) | 88 show: function(parentElement) |
89 { | 89 { |
90 WebInspector.View.prototype.show.call(this, parentElement); | 90 WebInspector.View.prototype.show.call(this, parentElement); |
91 this._ensureContentLoaded(); | 91 this._ensureContentLoaded(); |
(...skipping 904 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
996 | 996 |
997 releaseEvaluationResult: function() { }, | 997 releaseEvaluationResult: function() { }, |
998 | 998 |
999 suggestedFileName: function() { } | 999 suggestedFileName: function() { } |
1000 } | 1000 } |
1001 | 1001 |
1002 /** | 1002 /** |
1003 * Default implementation. | 1003 * Default implementation. |
1004 */ | 1004 */ |
1005 WebInspector.SourceFrameDelegate.stub = Object.create(WebInspector.SourceFrameDe
legate.prototype); | 1005 WebInspector.SourceFrameDelegate.stub = Object.create(WebInspector.SourceFrameDe
legate.prototype); |
OLD | NEW |