mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-06-28 00:40:07 +02:00
WOW REALLY NICE with level switching
This commit is contained in:
parent
9460c4b4c6
commit
8e98c4d457
7 changed files with 154 additions and 61 deletions
|
@ -38,6 +38,12 @@ function GitVisuals(options) {
|
|||
this.branchCollection.on('remove', this.removeBranch, this);
|
||||
this.deferred = [];
|
||||
|
||||
// eventually have origin support here
|
||||
this.posBoundaries = {
|
||||
min: 0,
|
||||
max: 1
|
||||
};
|
||||
|
||||
var Main = require('../app');
|
||||
Main.getEvents().on('refreshTree', this.refreshTree, this);
|
||||
}
|
||||
|
@ -453,7 +459,11 @@ GitVisuals.prototype.calcBranchStacks = function() {
|
|||
GitVisuals.prototype.calcWidth = function() {
|
||||
this.maxWidthRecursive(this.rootCommit);
|
||||
|
||||
this.assignBoundsRecursive(this.rootCommit, 0, 1);
|
||||
this.assignBoundsRecursive(
|
||||
this.rootCommit,
|
||||
this.posBoundaries.min,
|
||||
this.posBoundaries.max
|
||||
);
|
||||
};
|
||||
|
||||
GitVisuals.prototype.maxWidthRecursive = function(commit) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue