You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wookie.apache.org by rg...@apache.org on 2012/03/28 01:47:55 UTC
svn commit: r1306061 - in /incubator/wookie/trunk/WebContent/demo: index.htm
wookie.js
Author: rgardler
Date: Tue Mar 27 23:47:55 2012
New Revision: 1306061
URL: http://svn.apache.org/viewvc?rev=1306061&view=rev
Log:
show the name and id of the widget currently being previewed
Modified:
incubator/wookie/trunk/WebContent/demo/index.htm
incubator/wookie/trunk/WebContent/demo/wookie.js
Modified: incubator/wookie/trunk/WebContent/demo/index.htm
URL: http://svn.apache.org/viewvc/incubator/wookie/trunk/WebContent/demo/index.htm?rev=1306061&r1=1306060&r2=1306061&view=diff
==============================================================================
--- incubator/wookie/trunk/WebContent/demo/index.htm (original)
+++ incubator/wookie/trunk/WebContent/demo/index.htm Tue Mar 27 23:47:55 2012
@@ -75,7 +75,9 @@
see any interaction between the two widget instances.
</p>
<!-- Preview area -->
+ <hr/>
<div id="preview">
+ <p>Previewing: <span id="preview_info">None</p>
<div id="preview_alice" class="preview">
<h1><img src="http://localhost:8080/wookie/demo/alice.png"> Alice</h1>
<div id="preview_alice_widget">Select a widget on the left</div>
Modified: incubator/wookie/trunk/WebContent/demo/wookie.js
URL: http://svn.apache.org/viewvc/incubator/wookie/trunk/WebContent/demo/wookie.js?rev=1306061&r1=1306060&r2=1306061&view=diff
==============================================================================
--- incubator/wookie/trunk/WebContent/demo/wookie.js (original)
+++ incubator/wookie/trunk/WebContent/demo/wookie.js Tue Mar 27 23:47:55 2012
@@ -88,6 +88,7 @@ function updateWidgets(widgets){
function showWidget(id){
Wookie.setCurrentUser("alice","alice","http://localhost:8080/wookie/demo/alice.png");
var widgetInstance = Wookie.getOrCreateInstance(id);
+ $('#preview_info').html('<br/>' + widgetInstance.title + '<br/>' + id);
$("#preview_alice_widget").html('');
$("#preview_alice_widget").append("<iframe src='"+widgetInstance.url+"' height='"+widgetInstance.height+"' width='"+widgetInstance.width+"'></iframe>");
$("#alice_url").html("<a href='" + widgetInstance.url + "' target='_blank'>Full Screen</a>");