]>
git.wh0rd.org - tt-rss.git/blob - lib/dojo/robotx.js
2 Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved.
3 Available via Academic Free License >= 2.1 OR the modified BSD license.
4 see: http://dojotoolkit.org/license for details
8 if(!dojo
._hasResource
["dojo.robotx"]){
9 dojo
._hasResource
["dojo.robotx"]=true;
10 dojo
.provide("dojo.robotx");
11 dojo
.require("dojo.robot");
12 dojo
.experimental("dojo.robotx");
14 doh
.robot
._runsemaphore
.lock
.push("dojo.robotx.lock");
15 var _1
=document
.getElementById("robotapplication");
16 var _2
=dojo
.connect(doh
,"_groupStarted",function(){
18 _1
.style
.visibility
="visible";
21 doh
.robot
._updateDocument();
23 var _4
=(document
.compatMode
=="BackCompat")?document
.body
:document
.documentElement
;
24 var _5
=document
.getElementById("robotconsole").offsetHeight
;
26 _1
.style
.height
=(_4
.clientHeight
-_5
)+"px";
34 var _7
=dojo
.connect(dojo
.body(),"onunload",function(){
40 dojo
.config
.debugContainerId
="robotconsole";
41 dojo
.config
.debugHeight
=dojo
.config
.debugHeight
||200;
42 document
.write("<div id=\"robotconsole\" style=\"position:absolute;left:0px;bottom:0px;width:100%;\"></div>");
43 _1
=document
.createElement("iframe");
44 _1
.setAttribute("ALLOWTRANSPARENCY","true");
45 _1
.scrolling
=dojo
.isIE
?"yes":"auto";
46 dojo
.style(_1
,{visibility
:"hidden",border
:"0px none",padding
:"0px",margin
:"0px",position
:"absolute",left
:"0px",top
:"0px",width
:"100%",height
:"100%"});
47 if(_1
["attachEvent"]!==undefined){
48 _1
.attachEvent("onload",_6
);
50 dojo
.connect(_1
,"onload",_6
);
52 dojo
.mixin(doh
.robot
,{_updateDocument:function(){
53 dojo
.setContext(_1
.contentWindow
,_1
.contentWindow
.document
);
56 dojo
._topics
=_8
.dojo
._topics
;
58 },initRobot:function(_9
){
60 dojo
.addOnLoad(function(){
61 var _a
={overflow
:dojo
.isWebKit
?"hidden":"visible",margin
:"0px",borderWidth
:"0px",height
:"100%",width
:"100%"};
62 dojo
.style(document
.documentElement
,_a
);
63 dojo
.style(document
.body
,_a
);
64 document
.body
.appendChild(_1
);
65 var _b
=document
.createElement("base");
67 document
.getElementsByTagName("head")[0].appendChild(_b
);
69 },waitForPageToLoad:function(_c
){
70 var d
=new doh
.Deferred();
73 doh
.robot
._updateDocument();