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
415fe8d3
Commit
415fe8d3
authored
Apr 02, 2014
by
Andy Armstrong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clean up the logic for the edit modal's title
parent
dce075a8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
12 deletions
+6
-12
cms/static/js/views/modals/edit_xblock.js
+6
-4
cms/static/js/views/xblock_editor.js
+0
-8
No files found.
cms/static/js/views/modals/edit_xblock.js
View file @
415fe8d3
...
...
@@ -53,10 +53,7 @@ define(["jquery", "underscore", "gettext", "js/views/modals/base_modal",
onDisplayXBlock
:
function
()
{
var
editorView
=
this
.
editorView
,
displayName
,
title
;
displayName
=
editorView
.
getDisplayName
();
title
=
interpolate
(
gettext
(
"Editing: %(title)s"
),
{
title
:
displayName
},
true
);
title
=
this
.
getTitle
();
if
(
editorView
.
hasCustomTabs
())
{
// Hide the modal's header as the custom editor provides its own
this
.
$
(
'.modal-header'
).
hide
();
...
...
@@ -72,6 +69,11 @@ define(["jquery", "underscore", "gettext", "js/views/modals/base_modal",
}
},
getTitle
:
function
()
{
var
displayName
=
this
.
xblockElement
.
find
(
'.component-header'
).
text
().
trim
();
return
interpolate
(
gettext
(
"Editing: %(title)s"
),
{
title
:
displayName
},
true
);
},
addDefaultModes
:
function
()
{
var
defaultModes
=
this
.
editorView
.
getDefaultModes
(),
i
,
...
...
cms/static/js/views/xblock_editor.js
View file @
415fe8d3
...
...
@@ -117,14 +117,6 @@ define(["jquery", "underscore", "gettext", "js/views/feedback_notification", "js
return
data
;
},
getDisplayName
:
function
()
{
var
metadataEditor
=
this
.
getMetadataEditor
();
if
(
metadataEditor
)
{
return
metadataEditor
.
getDisplayName
();
}
return
"How do we get the display name now?"
;
},
/**
* Returns the metadata that has changed in the editor. This is a combination of the metadata
* modified in the "Settings" editor, as well as any custom metadata provided by the component.
...
...
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