From e3df816fb979497ce6638dea0d394bab555c2a4f Mon Sep 17 00:00:00 2001 From: Jason White Date: Sat, 24 Oct 2015 13:10:43 -0500 Subject: [PATCH] #41 omitted on earlier commit --- .../webapp/js/goatApp/controller/MenuController.js | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/webgoat-container/src/main/webapp/js/goatApp/controller/MenuController.js b/webgoat-container/src/main/webapp/js/goatApp/controller/MenuController.js index d9df4e021..933a0a05c 100644 --- a/webgoat-container/src/main/webapp/js/goatApp/controller/MenuController.js +++ b/webgoat-container/src/main/webapp/js/goatApp/controller/MenuController.js @@ -11,15 +11,22 @@ define(['jquery', _.extend(Controller.prototype,Backbone.Events); options = options || {}; this.menuView = options.menuView; + this.titleView = options.titleView; - this.initMenu = function() { - //this.listenTo(this.menuView,'lesson:click',this.renderTitle); - } + // this.initMenu = function() { + // this.listenTo(this.menuView,'lesson:click',this.renderTitle); + // } this.updateMenu = function(){ this.menuView.updateMenu(); + }, + + //TODO: move title rendering into lessonContent/View pipeline once data can support it + this.renderTitle = function(title) { + this.titleView.render(title); } + }; return Controller;