Closed
Bug 740805
Opened 14 years ago
Closed 14 years ago
Treat JSM files as JS scripts in the debugger
Categories
(DevTools :: Debugger, defect, P2)
DevTools
Debugger
Tracking
(Not tracked)
RESOLVED
FIXED
Firefox 14
People
(Reporter: past, Assigned: past)
References
Details
(Whiteboard: [chrome-debug][fixed-in-fx-team])
Attachments
(1 file, 1 obsolete file)
|
1.04 KB,
patch
|
rcampbell
:
review+
|
Details | Diff | Splinter Review |
When displaying JS module files we need to have the editor use the JavaScript highlighting mode, not the HTML one.
| Assignee | ||
Comment 1•14 years ago
|
||
The patch from the remote-debug repo.
Attachment #610878 -
Flags: review?(rcampbell)
| Assignee | ||
Updated•14 years ago
|
Status: NEW → ASSIGNED
Comment 2•14 years ago
|
||
Comment on attachment 610878 [details] [diff] [review]
Working patch
you're using a regex above this. What about:
if (/\.jsm?$/.test(this._trimUrlQuery(aUrl))) {
window.editor.setMode(SourceEditor.MODES.JAVASCRIPT);
}
?
It doesn't exactly help readability (so a comment describing the regexp could be helpful) but it does cut down on an extra call to _trimUrlQuery() and .slice().
Attachment #610878 -
Flags: review?(rcampbell)
| Assignee | ||
Comment 3•14 years ago
|
||
(In reply to Rob Campbell [:rc] (:robcee) from comment #2)
> Comment on attachment 610878 [details] [diff] [review]
> Working patch
>
> you're using a regex above this. What about:
>
> if (/\.jsm?$/.test(this._trimUrlQuery(aUrl))) {
> window.editor.setMode(SourceEditor.MODES.JAVASCRIPT);
> }
>
> ?
>
> It doesn't exactly help readability (so a comment describing the regexp
> could be helpful) but it does cut down on an extra call to _trimUrlQuery()
> and .slice().
Yes, that's a good idea!
| Assignee | ||
Comment 5•14 years ago
|
||
Updated to use a regex.
Attachment #610878 -
Attachment is obsolete: true
Attachment #613659 -
Flags: review?(rcampbell)
Comment 6•14 years ago
|
||
(In reply to Panos Astithas [:past] from comment #5)
> Created attachment 613659 [details] [diff] [review]
> Working patch v2
>
> Updated to use a regex.
This needs a quick and easy rebase.
Comment 7•14 years ago
|
||
Comment on attachment 613659 [details] [diff] [review]
Working patch v2
rebasing is easy!
Attachment #613659 -
Flags: review?(rcampbell) → review+
| Assignee | ||
Comment 8•14 years ago
|
||
Rebased and landed:
https://hg.mozilla.org/integration/fx-team/rev/0319eb7b084a
Whiteboard: [chrome-debug] → [chrome-debug][fixed-in-fx-team]
Comment 9•14 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 14
Updated•7 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•