Commit 5d31f64c authored by rockyl's avatar rockyl

Merge branch 'dev' into res-group

parents 21438934 77598422
......@@ -414,16 +414,28 @@ export const projectStore = {
let _node1 = node;
console.log(_node1)
copyNodeCatch = clonePureObj(_node1)
console.log("copyNodeCatch",copyNodeCatch)
if (copyState == 1) {
//复制行为
copyNodeCatch.events
} else if (copyState == 2) {
//不复制行为
delete copyNodeCatch.events
console.log(this)
deleteChildEvent(copyNodeCatch)
}
//copy(JSON.stringify(copyNodeCatch))
function deleteChildEvent(copyNodeCatch){
console.log(123)
delete copyNodeCatch.events;
if(copyNodeCatch.children){
for(let item of copyNodeCatch.children){
deleteChildEvent(item)
}
}
}
},
pasteNode(state, {node, parentNode, pasteState}) {
let _node1 = copyNodeCatch;
console.log(copyNodeCatch);
......
......@@ -348,7 +348,7 @@
//console.log(merged);
let startLine = modifiedStartLineNumber + offset;
let startLine = modifiedStartLineNumber + offset + (modifiedEndLineNumber === 0 ? 1 : 0);
mergedCodeLines.splice(startLine - 1, modifiedEndLineNumber - modifiedStartLineNumber + 1, ...merged);
offset += 3 + remotePart.length;
}
......@@ -387,10 +387,11 @@
}
break;
}
if (replacer !== undefined) {
/*if (replacer !== undefined) {
replaceText(replacer);
//this.localData = lines.join('\n');
}
}*/
replaceText(replacer);
this.delayTrack();
this.conflictIndex--;
......@@ -404,18 +405,25 @@
}
return resultLines.join('\n');
}
return null;
}
function replaceText(replacer) {
model.pushEditOperations([], [{
let op = {
range: {
startLineNumber: conflict.remoteLine + 1,
startColumn: 0,
startColumn: 1,
endLineNumber: conflict.localLine + 1,
endColumn: Number.MAX_VALUE,
},
text: replacer,
}], () => []);
};
if (replacer === null) {
op.range.startLineNumber = conflict.remoteLine;
op.range.startColumn = Number.MAX_VALUE;
}
model.pushEditOperations([], [op], () => []);
}
},
...mapMutations([
......
......@@ -8703,7 +8703,7 @@ vue-loader@^15.7.0:
"vue-monaco@http://gitlab2.dui88.com/laoqifeng/vue-monaco.git":
version "0.3.1"
resolved "http://gitlab2.dui88.com/laoqifeng/vue-monaco.git#13de23ce8ba73525cf08678227ae0c579fe2319d"
resolved "http://gitlab2.dui88.com/laoqifeng/vue-monaco.git#d8153f9d3f41eee09a7a0c05212333dea5c86712"
dependencies:
monaco-editor "^0.20.0"
nano-assign "^1.0.0"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment