diff options
author | Ananya Sen | 2012-05-18 16:57:27 -0700 |
---|---|---|
committer | Ananya Sen | 2012-05-18 16:57:27 -0700 |
commit | bddbcd15c165ac0731de204b023a1e60d71b5d79 (patch) | |
tree | 727997cc71d5e9c951c1089dfbdeb90cd3b68e6f /js/components/layout/bread-crumb.reel/bread-crumb.js | |
parent | 7a22f7b368ef549a5b30c58a0f3900685b764bdb (diff) | |
parent | e7c288fe8f5d3a9e5c9f0eb0a045c6c195a0e7b8 (diff) | |
download | ninja-bddbcd15c165ac0731de204b023a1e60d71b5d79.tar.gz |
Merge branch 'refs/heads/master-dom-architecture' into dom-architecture
Diffstat (limited to 'js/components/layout/bread-crumb.reel/bread-crumb.js')
-rwxr-xr-x | js/components/layout/bread-crumb.reel/bread-crumb.js | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/js/components/layout/bread-crumb.reel/bread-crumb.js b/js/components/layout/bread-crumb.reel/bread-crumb.js index c1b021a3..d2a6b1e4 100755 --- a/js/components/layout/bread-crumb.reel/bread-crumb.js +++ b/js/components/layout/bread-crumb.reel/bread-crumb.js | |||
@@ -60,30 +60,18 @@ exports.Breadcrumb = Montage.create(Component, { | |||
60 | value: function() { | 60 | value: function() { |
61 | var parentNode; | 61 | var parentNode; |
62 | 62 | ||
63 | this.containerElements.length = 0; | 63 | // delete this.containerElements; |
64 | this.containerElements = []; | ||
64 | 65 | ||
65 | parentNode = this.container; | 66 | parentNode = this.container; |
66 | 67 | ||
67 | // This is for the old template support. | 68 | while(parentNode !== this.application.ninja.currentDocument.documentRoot) { |
68 | // TODO: Remove marker for old template: NINJA-STAGE-REWORK | ||
69 | if(this.application.ninja.currentDocument.documentRoot.id === "UserContent") { | ||
70 | while(parentNode.id !== "UserContent") { | ||
71 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); | ||
72 | parentNode = parentNode.parentNode; | ||
73 | } | ||
74 | |||
75 | // This is always the top container which is now hardcoded to body | ||
76 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": "Body"}); | ||
77 | } else { | ||
78 | while(parentNode !== this.application.ninja.currentDocument.documentRoot) { | ||
79 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); | ||
80 | parentNode = parentNode.parentNode; | ||
81 | } | ||
82 | |||
83 | // This is always the top container which is now hardcoded to body | ||
84 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); | 69 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); |
70 | parentNode = parentNode.parentNode; | ||
85 | } | 71 | } |
86 | 72 | ||
73 | // This is always the top container which is now hardcoded to body | ||
74 | this.containerElements.unshift({"node": parentNode, "nodeUuid":parentNode.uuid, "label": parentNode.nodeName}); | ||
87 | } | 75 | } |
88 | }, | 76 | }, |
89 | 77 | ||