mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-06-27 08:28:50 +02:00
branch deleting down
This commit is contained in:
parent
1fee32879c
commit
f353fa118d
4 changed files with 39 additions and 31 deletions
12
src/tree.js
12
src/tree.js
|
@ -253,6 +253,18 @@ var VisBranch = Backbone.Model.extend({
|
|||
return gitVisuals.blendHuesFromBranchStack(this.getBranchStackArray());
|
||||
},
|
||||
|
||||
remove: function() {
|
||||
var keys = ['text', 'arrow', 'rect'];
|
||||
_.each(keys, function(key) {
|
||||
if (this.get(key)) {
|
||||
this.get(key).remove();
|
||||
}
|
||||
}, this);
|
||||
|
||||
// also need to remove from gitVisuals
|
||||
gitVisuals.removeVisBranch(this);
|
||||
},
|
||||
|
||||
genGraphics: function(paper) {
|
||||
var textPos = this.getTextPosition();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue