Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
550f9d7e
Commit
550f9d7e
authored
Apr 08, 2014
by
Christina Roberts
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3244 from edx/christina/latex-bug-release
Fix source editor for the case of no CodeMirror editor.
parents
d296eea6
e008de88
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletions
+10
-1
cms/templates/widgets/source-edit.html
+10
-1
No files found.
cms/templates/widgets/source-edit.html
View file @
550f9d7e
...
...
@@ -123,7 +123,16 @@ require(["jquery", "jquery.leanModal", "codemirror/stex"], function($) {
if
(
xml
.
length
==
0
)
{
alert
(
'Conversion failed! error:'
+
data
.
message
);
}
else
{
el
.
closest
(
'.component'
).
find
(
'.CodeMirror-wrap'
)[
0
].
CodeMirror
.
setValue
(
xml
);
// If a parent CodeMirror editor is open (LaTeX problem being edited), set the text
// there. Otherwise, set the text in the active TinyMCE Editor for the case
// of an HTML component being edited.
var
parentCodemirrorEditor
=
el
.
closest
(
'.component'
).
find
(
'.CodeMirror-wrap'
);
if
(
parentCodemirrorEditor
.
length
>
0
)
{
parentCodemirrorEditor
[
0
].
CodeMirror
.
setValue
(
xml
);
}
else
if
(
window
.
tinyMCE
!==
undefined
&&
window
.
tinyMCE
.
activeEditor
!==
undefined
)
{
window
.
tinyMCE
.
activeEditor
.
setContent
(
xml
);
}
save_hls
(
el
);
}
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment