<?xml version="1.0" encoding="UTF-8"?>
<Module>
  <!--
   Copyright 2008 Google Inc.
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at
       http:
   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
  -->
  <ModulePrefs title="Developer Application for OpenSocial"
               description="This gadget provides the ability to write and save 
                            JavaScript code samples to execute against
                            OpenSocial containers. This helps rapidly test
                            sample OpenSocial code."
               directory_title="Developer Application for OpenSocial"
               screenshot="http://dafos.appspot.com/img/gadget-screenshot.png"
               thumbnail="http://dafos.appspot.com/img/gadget-thumbnail.png"
               title_url="http://dafos.appspot.com"
               author_email="opensocial.coderunner@gmail.com"
               author_affiliation="Google Inc."
               author_location="Mountain View, CA, USA"
               scaling="true"
               scrolling="false"
               singleton="false">
    <Require feature="opensocial-0.7" />
    <Require feature="dynamic-height" />
    <Require feature="views" />
    <Require feature="tabs" />
    <Preload href="http://dafos.appspot.com/gadgetapi/cansave" authz="signed" />
    <Preload href="http://dafos.appspot.com/gadgetapi/samples" sign_viewer="false" authz="signed" />
    <Optional feature="flash" />
  </ModulePrefs>
  <Content type="html" view="default,canvas,profile,home" >
    <![CDATA[
      <style type="text/css">
#wrap{width:99%;}
.tablib_emptyTab,.tablib_unselected,.tablib_spacerTab{border-bottom:1px solid #ccc;}
.tablib_selected{border-color:#ccc;}
#controls{font:14px Arial,sans;padding:0;margin:0;}
#toolbar{background:#eee;border:1px solid #ccc;border-bottom:1px solid #999;border-right:1px solid #999;border-top-width:0;}
#toolbar table{width:99%;border-collapse:collapse;margin:0;}
#toolbar table td{padding:2px;}
#code_controls{text-align:right;padding:2px 4px;}
#filename{background:#ddd;padding:3px;border:1px solid #ccc;border-top:1px solid #eee;border-bottom:1px solid #999;border-right:1px solid #999;}
#controls a,#filename a,#filename span,#filename code{font:14px Arial,sans!important;cursor:pointer;height:16px;}
#filename span code a{font:16px Georgia,serif!important;}
#filename span{color:#111;}
#dom_handle{margin:10px 0;}
#toolbar select{border:1px solid #ccc;font:11px Arial;padding:2px;width:15em;}
#toolbar a img,#filename a img{height:16px;width:16px;padding:0;margin:0;vertical-align:middle;}
.dafos-notice{font:11px Arial;color:#ccc;text-align:center;}
.dafos-button{margin-left:8px;}
.dafos-tools-cachetable,.dafos-tools-cachetable button,.dafos-tools-cachetable input{width:100%;}
.dafos-tools-cachetable td.inputcell{width:80%;}
.dom_handle_label{font:13px Courier New;background:#eee;color:#999;}
p,div,span{font:12px Verdana;}
code,var,.code,#output{font:13px Courier New;}
code{color:#090;}
var{color:#00d;}
.code{font-weight:bold;background:#fffeee;color:#000;padding:5px;border-top:2px solid #666;border-left:2px solid #666;border-bottom:2px solid #ccc;border-right:2px solid #ccc;}
p,.code{margin:2px,0;}
.dafos-message{text-align:center;padding:2px;margin-bottom:4px;background:#36b;color:#fff;}
#output{background:#333;color:#fff;padding:5px;margin:5px 0;}
.status{color:#999;}
#link_container{background:#e0ecff;font:14px Arial;margin:10px;padding:5px;}
textarea{width:100%;height:auto;}
#code_exec{height:400px;}
      </style>
      <script type="text/javascript">
var dafos={};dafos.bind=function(D,E){var C=[];for(var A=2,B;B=arguments[A];A++){C.push(B)}return function(){var F=C.slice();for(var G=0,H;H=arguments[G];G++){F.push(H)}D.apply(E,F)}};var ark={};dafos.OpenSocial=function(){this.viewer={};this.owner={};this.peopledata={}};dafos.OpenSocial.prototype.getDataOr=function(C,A,B){return(C&&C.get(A)&&!C.get(A).hadError()&&C.get(A).getData())||B};dafos.OpenSocial.prototype.getOpenSocialData=function(B,C){var A=opensocial.newDataRequest();A.add(A.newFetchPersonAppDataRequest(opensocial.DataRequest.PersonId.OWNER,B),"peopledata");A.add(A.newFetchPersonRequest(opensocial.DataRequest.PersonId.OWNER),"owner");A.add(A.newFetchPersonRequest(opensocial.DataRequest.PersonId.VIEWER),"viewer");A.send(dafos.bind(this.closeGetOpenSocialData(C),this))};dafos.OpenSocial.prototype.closeGetOpenSocialData=function(A){return function(E){var B=null,D=null,C=null;this.viewer=this.getDataOr(E,"viewer",this.viewer);this.owner=this.getDataOr(E,"owner",this.owner);B=this.getDataOr(E,"peopledata",{});this.mergePersonAppData.apply(this,[B]);if(A&&typeof (A)=="function"){A()}}};dafos.OpenSocial.prototype.mergePersonAppData=function(A){for(personkey in A){if(A.hasOwnProperty(personkey)){this.peopledata[personkey]=this.peopledata[personkey]||{};for(datakey in A[personkey]){if(A[personkey].hasOwnProperty(datakey)){this.peopledata[personkey][datakey]=A[personkey][datakey]}}}}};dafos.OpenSocial.prototype.viewerIsOwner=function(){return(this.viewer.getId&&this.viewer.getId()||-1)===(this.owner.getId&&this.owner.getId()||-2)};dafos.OpenSocial.prototype.setAppData=function(C,A,D){var B=opensocial.newDataRequest();C=gadgets.json.stringify(C);B.add(B.newUpdatePersonAppDataRequest(opensocial.DataRequest.PersonId.VIEWER,A,C),"updatedata");B.add(B.newFetchPersonAppDataRequest(opensocial.DataRequest.PersonId.OWNER,A,C),"peopledata");B.send(dafos.bind(this.closeSetAppData(D),this))};dafos.OpenSocial.prototype.closeSetAppData=function(A){return function(D){var B=null,C=null;B=this.getDataOr(D,"peopledata",{});this.mergePersonAppData.apply(this,[B]);if(A&&typeof (A)=="function"){A()}}};dafos.OpenSocial.prototype.getPersonData=function(A){return(A&&this.peopledata[A])||{}};dafos.OpenSocial.prototype.getViewerData=function(){return(this.viewer&&this.viewer.getId&&this.peopledata[this.viewer.getId()])||{}};dafos.OpenSocial.prototype.getOwnerData=function(){return(this.owner&&this.owner.getId&&this.peopledata[this.owner.getId()])||{}};ark.AggregateCallback=function(B,A){this.current_=0;this.total_=A||0;this.onfinished_=B};ark.AggregateCallback.prototype.getCallback=function(){var A=this;this.total_++;return function(){A.callback()}};ark.AggregateCallback.prototype.callback=function(){this.current_++;if(this.current_==this.total_){this.onfinished_();this.onfinished_=null}};var w23={e:function(E,A){var F=document.createElement(E),D=0,C=0,B=0;if(A){for(C in A){if(A.hasOwnProperty(C)){if(C!="style"){F[C]=A[C]}else{for(B in A[C]){if(A[C].hasOwnProperty(B)){F[C][B]=A[C][B]}}}}}}if(arguments.length>2){for(D=2;D<arguments.length;D++){if(typeof (arguments[D])=="string"){F.appendChild(w23.t(arguments[D]))}else{F.appendChild(arguments[D])}}}return F},t:function(A){return document.createTextNode(A)},append:function(B){if(arguments.length>1){for(var A=1;A<arguments.length;A++){if(typeof (arguments[A])=="string"){B.appendChild(w23.t(arguments[A]))}else{B.appendChild(arguments[A])}}}}};dafos.AppEngine=function(){};dafos.AppEngine.prototype.saveSample=function(B,E,F){var D={};var C={dafos_sample_name:B,dafos_sample_text:E};D[gadgets.io.RequestParameters.AUTHORIZATION]=gadgets.io.AuthorizationType.SIGNED;D[gadgets.io.RequestParameters.CONTENT_TYPE]=gadgets.io.ContentType.JSON;D[gadgets.io.RequestParameters.METHOD]=gadgets.io.MethodType.POST;D[gadgets.io.RequestParameters.POST_DATA]=gadgets.io.encodeValues(C);var A="http://dafos.appspot.com/gadgetapi/save";gadgets.io.makeRequest(A,dafos.bind(this.saveResponse,this,F),D)};dafos.AppEngine.prototype.deleteSample=function(E,D){var C={};var B={dafos_sample_id:E};C[gadgets.io.RequestParameters.AUTHORIZATION]=gadgets.io.AuthorizationType.SIGNED;C[gadgets.io.RequestParameters.CONTENT_TYPE]=gadgets.io.ContentType.JSON;C[gadgets.io.RequestParameters.METHOD]=gadgets.io.MethodType.POST;C[gadgets.io.RequestParameters.POST_DATA]=gadgets.io.encodeValues(B);var A="http://dafos.appspot.com/gadgetapi/delete";gadgets.io.makeRequest(A,dafos.bind(this.saveResponse,this,D),C)};dafos.AppEngine.prototype.canSave=function(C){var B={};B[gadgets.io.RequestParameters.AUTHORIZATION]=gadgets.io.AuthorizationType.SIGNED;B[gadgets.io.RequestParameters.CONTENT_TYPE]=gadgets.io.ContentType.JSON;var A="http://dafos.appspot.com/gadgetapi/cansave";gadgets.io.makeRequest(A,dafos.bind(this.saveResponse,this,C),B)};dafos.AppEngine.prototype.getOwnerSamples=function(C){var B={};B[gadgets.io.RequestParameters.AUTHORIZATION]=gadgets.io.AuthorizationType.SIGNED;B[gadgets.io.RequestParameters.CONTENT_TYPE]=gadgets.io.ContentType.JSON;var A="http://dafos.appspot.com/gadgetapi/samples";gadgets.io.makeRequest(A,dafos.bind(this.saveResponse,this,C),B)};dafos.AppEngine.prototype.getSample=function(D,C){var B={};B[gadgets.io.RequestParameters.AUTHORIZATION]=gadgets.io.AuthorizationType.SIGNED;B[gadgets.io.RequestParameters.CONTENT_TYPE]=gadgets.io.ContentType.JSON;var A="http://dafos.appspot.com/gadgetapi/sample/"+D;gadgets.io.makeRequest(A,dafos.bind(this.saveResponse,this,C),B)};dafos.AppEngine.prototype.saveResponse=function(B,A){if(typeof B=="function"){if(A.data){B(A.data)}else{B(null)}}};dafos.CodeTab=function(A,B){this.appengine=new dafos.AppEngine();this.gadgetui=B;this.codetabui=new dafos.CodeTabUI(A);this.opensocial=new dafos.OpenSocial();this.cansave=false;this.samples={};this.init_callback=new ark.AggregateCallback(dafos.bind(this.onLoaded,this),3);this.gadgetui.showLoading("opensocial");this.opensocial.getOpenSocialData("",dafos.bind(this.onOpenSocialData,this));this.gadgetui.showLoading("capabilities");this.appengine.canSave(dafos.bind(this.onCanSave,this));this.gadgetui.showLoading("samples");this.appengine.getOwnerSamples(dafos.bind(this.onSamplesLoaded,this))};dafos.CodeTab.prototype.onOpenSocialData=function(A){this.gadgetui.hideLoading("opensocial");this.init_callback.callback()};dafos.CodeTab.prototype.onCanSave=function(A){this.gadgetui.hideLoading("capabilities");this.cansave=(A.status=="success");this.init_callback.callback()};dafos.CodeTab.prototype.onSamplesLoaded=function(B){this.gadgetui.hideLoading("samples");this.gadgetui.setMessage(B.message);if(B.status=="success"){for(var A=0;A<B.payload.length;A++){this.samples[B.payload[A].id]=B.payload[A]}}this.init_callback.callback()};dafos.CodeTab.prototype.onLoaded=function(){var B={save:dafos.bind(this.saveCode,this),saveas:dafos.bind(this.saveCodeAs,this),loadfile:dafos.bind(this.loadCode,this),deletefile:dafos.bind(this.deleteCode,this),execute:dafos.bind(this.runCode,this)};var A=this.cansave&&this.opensocial.viewerIsOwner();this.codetabui.renderToolbar(this.opensocial,B,A);this.drawSamples()};dafos.CodeTab.prototype.drawSamples=function(){this.codetabui.clearSamplesList();for(var A in this.samples){if(this.samples.hasOwnProperty(A)){this.codetabui.addSample(this.samples[A].name,this.samples[A].id)}}};dafos.CodeTab.prototype.runCode=function(){eval(this.codetabui.getCodeText())};dafos.CodeTab.prototype.saveCodeAs=function(){var A=prompt("Save code as?");if(A){this.current_file_name=A;this.saveCode.apply(this)}};dafos.CodeTab.prototype.saveCode=function(){if(!this.current_file_name){this.saveCodeAs.apply(this)}else{this.gadgetui.showLoading("save");this.appengine.saveSample(this.current_file_name,this.codetabui.getCodeText(),dafos.bind(this.onCodeSaved,this))}};dafos.CodeTab.prototype.onCodeSaved=function(A){this.gadgetui.hideLoading("save");this.gadgetui.setMessage(A.message);if(A.status=="success"){this.current_file_name=A.payload.name;this.current_file_key=A.payload.id;this.samples[A.payload.id]=A.payload;this.drawSamples();this.codetabui.renderCurrentFile(this.current_file_name,this.current_file_key)}};dafos.CodeTab.prototype.deleteCode=function(){if(this.current_file_name){this.gadgetui.showLoading("delete");this.appengine.deleteSample(this.current_file_key,dafos.bind(this.onCodeDeleted,this));delete this.samples[this.current_file_name]}};dafos.CodeTab.prototype.onCodeDeleted=function(A){this.gadgetui.hideLoading("delete");this.gadgetui.setMessage(A.message);if(A.status=="success"){this.codetabui.clearUserOutput();this.codetabui.setCodeText("");delete this.samples[this.current_file_key];this.drawSamples();this.current_file_name="";this.current_file_key="";this.codetabui.renderCurrentFile("","")}};dafos.CodeTab.prototype.loadCode=function(){this.current_file_name=this.codetabui.getSelectedLoadText();this.current_file_key=this.codetabui.getSelectedLoadValue();this.gadgetui.showLoading("load");this.appengine.getSample(this.current_file_key,dafos.bind(this.onCodeLoaded,this))};dafos.CodeTab.prototype.onCodeLoaded=function(A){this.gadgetui.hideLoading("load");this.gadgetui.setMessage(A.message);if(A.status=="success"){this.codetabui.clearUserOutput();this.codetabui.setCodeText(A.payload.text);this.codetabui.renderCurrentFile(this.current_file_name,this.current_file_key)}};dafos.CodeTabUI=function(A){this.loading_keys={};this.dom_wrap=A;this.dom_controls=document.getElementById("controls");this.dom_code_controls=document.getElementById("code_controls");this.dom_code=document.getElementById("code_exec");this.dom_filename=null;this.dom_handle=document.getElementById("dom_handle");this.dom_toolbar=w23.e("div",{id:"toolbar"});this.dom_controls.appendChild(this.dom_toolbar);this.dom_exec_button=null;this.clearUserOutput()};dafos.CodeTabUI.prototype.renderToolbar=function(D,C,A){var B=["Load one of ",D.owner.getDisplayName(),"'s samples..."].join("");this.dom_button_load=w23.e("a",{id:"button_load",onclick:C.loadfile,className:"dafos-button"},w23.e("img",{src:"http://dafos.appspot.com/img/load.png"})," Load");this.dom_button_execute=w23.e("a",{id:"button_execute",onclick:C.execute,className:"dafos-button"},w23.e("img",{src:"http://dafos.appspot.com/img/execute.png"})," Execute");this.dom_button_saveas=w23.e("a",{id:"button_saveas",onclick:C.saveas,className:"dafos-button"},w23.e("img",{src:"http://dafos.appspot.com/img/saveas.png"})," Save code as");this.dom_button_delete=w23.e("a",{id:"button_delete",onclick:C.deletefile,className:"dafos-button"},w23.e("img",{src:"http://dafos.appspot.com/img/delete.png"})," Delete");this.dom_button_save=w23.e("a",{id:"button_save",onclick:C.save,className:"dafos-button"},w23.e("img",{src:"http://dafos.appspot.com/img/save.png"})," Save code");this.dom_select=w23.e("select",{id:"select_load"},w23.e("option",null,B));this.dom_select.style.display="none";this.dom_button_load.style.display="none";if(!A){this.dom_button_save.style.display="none";this.dom_button_saveas.style.display="none";this.dom_button_delete.style.display="none"}this.dom_toolbar.appendChild(w23.e("table",null,w23.e("tbody",null,w23.e("tr",null,w23.e("td",null,this.dom_select,this.dom_button_load,this.dom_button_saveas),w23.e("td",{style:{textAlign:"right",width:"auto"}},this.dom_button_execute)))));this.renderCodeControls();this.renderLoadedFileControls(C);gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.renderLoadedFileControls=function(A){this.dom_filename=w23.e("div",{id:"filename"});this.dom_file_link=w23.e("a",{target:"_blank"});this.dom_filename.appendChild(w23.e("span",null," Currently loaded ",w23.e("code",null,this.dom_file_link)," - ",this.dom_button_save,this.dom_button_delete));this.dom_filename.style.display="none";this.dom_controls.appendChild(this.dom_filename)};dafos.CodeTabUI.prototype.renderCodeControls=function(){this.dom_code_controls.appendChild(w23.e("span",null,w23.e("a",{id:"button_code_down",onclick:dafos.bind(this.codeDown,this)},w23.e("img",{src:"http://dafos.appspot.com/img/arrow_down.png"})," Larger")," | ",w23.e("a",{id:"button_code_up",onclick:dafos.bind(this.codeUp,this)},w23.e("img",{src:"http://dafos.appspot.com/img/arrow_up.png"})," Smaller")));gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.codeDown=function(){this.dom_code.style.height=this.dom_code.offsetHeight+100+"px";gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.codeUp=function(){this.dom_code.style.height=Math.max(this.dom_code.offsetHeight-100,50)+"px";gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.clearSamplesList=function(){this.dom_select.innerHTML="";this.dom_select.style.display="none";this.dom_button_load.style.display="none";gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.addSample=function(A,B){this.dom_select.style.display="inline";this.dom_button_load.style.display="inline";params={value:B};this.dom_select.appendChild(w23.e("option",params,A));gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.getSelectedLoadValue=function(){return(this.dom_select&&this.dom_select.value)||""};dafos.CodeTabUI.prototype.getSelectedLoadText=function(){if(this.dom_select){return this.dom_select[this.dom_select.selectedIndex].innerHTML}else{return""}};dafos.CodeTabUI.prototype.clearUserOutput=function(){this.dom_handle.innerHTML=['<span class="dom_handle_label">','&lt;div id="dom_handle"&gt;</span>',"This <code>div</code> has an id of <code>dom_handle</code>"," that you can use to insert DOM elements into",'<span class="dom_handle_label">&lt;/div&gt;</span>'].join("");cls();gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.renderCurrentFile=function(B,D){var A=document.getElementById("select_load"),E=null,C=0;if(B&&B!=""){this.dom_file_link.innerHTML=gadgets.util.escapeString(B);this.dom_file_link.href="http://dafos.appspot.com/code/sample/"+D;this.dom_filename.style.display="block";for(C=0,E;E=A.childNodes[C];C++){if(E.value==D){E.selected="selected"}}}else{this.dom_filename.style.display="none"}gadgets.window.adjustHeight()};dafos.CodeTabUI.prototype.setCodeText=function(A){this.dom_code.value=A};dafos.CodeTabUI.prototype.getCodeText=function(){return this.dom_code.value};dafos.GadgetUI=function(A){this.dom_parent=A;this.loading_keys={};this.render()};dafos.GadgetUI.prototype.render=function(){var A={className:"dafos-message",style:{display:"none"}};var C={className:"dafos-notice"};var B={className:"dafos-loadbox",style:{display:"none",position:"absolute",right:"4px",top:"4px",backgroundColor:"#dd0000",padding:"4px",color:"#ffffff"}};var E={src:"http://dafos.appspot.com/img/loading.png"};this.dom_message=w23.e("div",A);this.dom_parent.parentNode.insertBefore(this.dom_message,this.dom_parent);this.dom_parent.appendChild(w23.e("div",C,this.getVersion()));var D=w23.e("img",E);this.dom_loadmessage=w23.e("span",null);this.dom_loadbox=w23.e("div",B,D," Loading... ");this.dom_loadbox.appendChild(this.dom_loadmessage);this.dom_parent.appendChild(this.dom_loadbox)};dafos.GadgetUI.prototype.getVersion=function(){return"DAfOS generic version"};dafos.GadgetUI.prototype.showLoading=function(A){if(A!=null){this.loading_keys[A]=true}var C=[];for(var B in this.loading_keys){if(this.loading_keys.hasOwnProperty(B)){C.push(B)}}this.dom_loadmessage.innerHTML=C.join(",");this.dom_loadbox.style.display="block";gadgets.window.adjustHeight()};dafos.GadgetUI.prototype.hideLoading=function(A){if(A!=null){delete this.loading_keys[A]}var C=[];for(var B in this.loading_keys){if(this.loading_keys.hasOwnProperty(B)){C.push(B)}}if(C.length==0){this.dom_loadbox.style.display="none"}else{this.dom_loadmessage.innerHTML=C.join(",")}gadgets.window.adjustHeight()};dafos.GadgetUI.prototype.setMessage=function(B){if(B&&B!=""){window.clearTimeout(this.dom_message_timeout);var A=this.dom_message;A.innerHTML=gadgets.util.escapeString(B);A.style.display="block";gadgets.window.adjustHeight();this.dom_message_timeout=window.setTimeout(function(){A.innerHTML="";A.style.display="none";gadgets.window.adjustHeight()},5000)}};var output_buffer=[];function getArgsAsArray(B){var A=[];for(var C=0;C<B.length;C++){A.push(B[C])}return A}function output(){var B=getArgsAsArray(output.arguments);var A=document.getElementById("output");if(window.console&&console.log){console.log("output",B)}output_buffer.push(B.join(" "));while(output_buffer.length>400){output_buffer.shift()}A.innerHTML=output_buffer.join("<br />");A.scrollTop=A.scrollHeight;if(A.style.display=="none"){A.style.display="block"}}function cls(){output_buffer=[];var A=document.getElementById("output");A.innerHTML="";A.style.display="none";gadgets.window.adjustHeight()}dafos.onCodeTabActivated=function(){gadgets.window.adjustHeight()};gadgets.util.registerOnLoadHandler(function(){dafos.wrap=document.getElementById("wrap");var A=new gadgets.TabSet("dafos","Code",dafos.wrap);A.alignTabs("left",10);dafos.ui=new dafos.GadgetUI(dafos.wrap);A.addTab("Code",{contentContainer:document.getElementById("codetab"),callback:dafos.onCodeTabActivated,tooltip:"Write and test JavaScript code"});dafos.codetab=new dafos.CodeTab(dafos.wrap,dafos.ui);document.getElementById("toolstab").style.display="none"});
      </script>
      <div id="wrap">
        <div id="codetab">
          <div id="sample_exec">
            <div id="controls"></div>
            <div id="code_controls"></div>
            <textarea class="code" id="code_exec">
function response(data) {
  output(data.get("req").getData().getDisplayName());
  gadgets.window.adjustHeight();
};
function request() {
  var req = opensocial.newDataRequest();
  req.add(req.newFetchPersonRequest(opensocial.DataRequest.PersonId.OWNER), "req");
  req.send(response);
};
request();
            </textarea>
          </div>
          <div id="dom_handle"></div>
          <!-- Scrolling output buffer -->
          <div id="output"></div>
          <p>
            You can type in the field above and press the button to execute
            OpenSocial code. This is a good place to copy and paste code
            examples for experimenting with the OpenSocial API.
          </p>
          <p>
            In addition to the standard JavaScript and OpenSocial methods,
            you may also call the <code>output</code> method to print output
            text. <code>output</code> can take a variable number of arguments,
            so you can print several variables on the same line without needing
            to construct the string yourself. If you have firebug installed and
            enabled, output will also echo output to the firebug console.
          </p>
        </div>
        <div id="toolstab">
          <p>Input a gadget URL below to refresh the cache:</p>
        </div>
      </div>
    ]]>
  </Content>
</Module>

