BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
cc066314
Unverified
Commit
cc066314
authored
May 09, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed empty editors in the IDE
Closes #46153
parent
9a54cb36
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
model.js
app/assets/javascripts/ide/lib/common/model.js
+3
-3
file.js
app/assets/javascripts/ide/stores/actions/file.js
+2
-0
No files found.
app/assets/javascripts/ide/lib/common/model.js
View file @
cc066314
...
...
@@ -14,12 +14,12 @@ export default class Model {
(
this
.
originalModel
=
this
.
monaco
.
editor
.
createModel
(
head
?
head
.
content
:
this
.
file
.
raw
,
undefined
,
new
this
.
monaco
.
Uri
(
null
,
null
,
`original/
${
this
.
file
.
key
}
`
),
new
this
.
monaco
.
Uri
(
null
,
null
,
`original/
${
this
.
path
}
`
),
)),
(
this
.
model
=
this
.
monaco
.
editor
.
createModel
(
this
.
content
,
undefined
,
new
this
.
monaco
.
Uri
(
null
,
null
,
this
.
file
.
key
),
new
this
.
monaco
.
Uri
(
null
,
null
,
this
.
path
),
)),
);
if
(
this
.
file
.
mrChange
)
{
...
...
@@ -27,7 +27,7 @@ export default class Model {
(
this
.
baseModel
=
this
.
monaco
.
editor
.
createModel
(
this
.
file
.
baseRaw
,
undefined
,
new
this
.
monaco
.
Uri
(
null
,
null
,
`target/
${
this
.
file
.
path
}
`
),
new
this
.
monaco
.
Uri
(
null
,
null
,
`target/
${
this
.
path
}
`
),
)),
);
}
...
...
app/assets/javascripts/ide/stores/actions/file.js
View file @
cc066314
...
...
@@ -196,6 +196,8 @@ export const unstageChange = ({ commit }, path) => {
};
export
const
openPendingTab
=
({
commit
,
getters
,
dispatch
,
state
},
{
file
,
keyPrefix
})
=>
{
if
(
getters
.
activeFile
&&
getters
.
activeFile
.
key
===
`
${
keyPrefix
}
-
${
file
.
key
}
`
)
return
false
;
state
.
openFiles
.
forEach
(
f
=>
eventHub
.
$emit
(
`editor.update.model.dispose.
${
f
.
key
}
`
));
commit
(
types
.
ADD_PENDING_TAB
,
{
file
,
keyPrefix
});
...
...
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