Author: mfranklin
Date: Tue Aug 13 13:42:41 2013
New Revision: 1513483

URL: http://svn.apache.org/r1513483
Log:
Implemented set title for Home and Canvas views (RAVE-1026)

Modified:
    
rave/trunk/rave-portal-resources/src/main/webapp/static/script/portal/rave_ui.js

Modified: 
rave/trunk/rave-portal-resources/src/main/webapp/static/script/portal/rave_ui.js
URL: 
http://svn.apache.org/viewvc/rave/trunk/rave-portal-resources/src/main/webapp/static/script/portal/rave_ui.js?rev=1513483&r1=1513482&r2=1513483&view=diff
==============================================================================
--- 
rave/trunk/rave-portal-resources/src/main/webapp/static/script/portal/rave_ui.js
 (original)
+++ 
rave/trunk/rave-portal-resources/src/main/webapp/static/script/portal/rave_ui.js
 Tue Aug 13 13:42:41 2013
@@ -557,6 +557,7 @@ define(["jquery", "underscore", "rave",
                 this.$menuItemRate = $("#widget-" + regionWidgetId + 
"-menu-rate-item");
                 this.$menuItemEditPrefs = $("#widget-" + regionWidgetId + 
"-menu-editprefs-item");
                 this.$widgetSite = $("#widget-" + regionWidgetId + "-body");
+                this.$title = $("#widget-" + regionWidgetId + "-title");
             }
 
             HomeView.prototype.render = function (widget) {
@@ -726,13 +727,17 @@ define(["jquery", "underscore", "rave",
             HomeView.prototype.collapse = function () {
                 this.$chrome.hide();
             }
+            HomeView.prototype.setTitle = function(title) {
+                this.$title.html(title);
+            }
 
             rave.registerView('home', HomeView);
         }
 
         function registerCanvasView() {
-            var CanvasView = function () {
-                this.widget;
+            var CanvasView = function (widget) {
+                this.widget = widget;
+                this.$title = $("#widget-" + widget.regionWidgetId + "-title");
             }
             CanvasView.prototype.render = function (widget) {
                 this.widget = widget;
@@ -792,6 +797,9 @@ define(["jquery", "underscore", "rave",
                 // otherwise execute the minimize function
                 return false;
             }
+            CanvasView.prototype.setTitle  = function(title) {
+                this.$title.html(title);
+            }
 
             rave.registerView('canvas', CanvasView);
         }


Reply via email to