3 <title>XWalk Remote Debugging</title>
6 background-color: rgb(245, 245, 245);
7 font-family: Helvetica, Arial, sans-serif;
8 text-shadow: rgba(255, 255, 255, 0.496094) 0px 1px 0px;
25 -webkit-box-orient: horizontal;
26 -webkit-box-lines: multiple;
31 text-decoration: initial;
35 background-attachment: scroll;
36 background-origin: padding-box;
37 background-repeat: no-repeat;
38 border: 4px solid rgba(184, 184, 184, 1);
42 -webkit-background-size: cover;
43 -webkit-transition-property: background-color, border-color;
44 -webkit-transition: background-color 0.15s, 0.15s;
45 -webkit-transition-delay: 0, 0;
49 background-color: rgba(242, 242, 242, 1);
50 border-color: rgba(110, 116, 128, 1);
54 .thumbnail.connected {
58 .thumbnail.connected:hover {
59 border-color: rgba(184, 184, 184, 1);
60 color: rgb(110, 116, 128);
64 display: inline-block;
73 background: no-repeat 0;
74 background-size: 16px;
76 margin: 4px 0px 0px 4px;
78 padding: 2px 0px 0px 20px;
80 text-overflow: ellipsis;
88 var appListRequest = new XMLHttpRequest();
89 appListRequest.open("GET", "/json/list?t=" + new Date().getTime(), true);
90 appListRequest.onreadystatechange = onReady;
91 appListRequest.send();
95 if (this.readyState == 4 && this.status == 200) {
96 if (this.response != null)
97 var responseJSON = JSON.parse(this.response);
98 for (var i = 0; i < responseJSON.length; ++i)
99 appendItem(responseJSON[i]);
103 function appendItem(itemObject) {
105 if (itemObject.devtoolsFrontendUrl) {
106 frontendRef = document.createElement("a");
107 frontendRef.href = itemObject.devtoolsFrontendUrl;
108 frontendRef.title = itemObject.title;
110 frontendRef = document.createElement("div");
111 frontendRef.title = "The app already has active debugging session";
113 frontendRef.className = 'frontend_ref';
115 var thumbnail = document.createElement('div');
116 thumbnail.className = itemObject.devtoolsFrontendUrl ?
117 'thumbnail' : 'thumbnail connected';
118 if (itemObject.thumbnailUrl === undefined)
119 itemObject.thumbnailUrl = "/thumb/" + itemObject.id;
120 thumbnail.style.cssText = 'background-image:url(' +
121 itemObject.thumbnailUrl +
123 frontendRef.appendChild(thumbnail);
125 var text = document.createElement("div");
126 text.className = 'text';
127 if (frontendRef.title)
128 text.innerText = frontendRef.title;
130 text.innerText = "(untitled)";
131 text.style.cssText = "background-image:url(" + itemObject.faviconUrl + ")";
132 frontendRef.appendChild(text);
134 var item = document.createElement("p");
135 item.className = 'item';
136 item.appendChild(frontendRef);
138 document.getElementById("items").appendChild(item);
142 <body onload='onLoad()'>
143 <div id='caption'>Inspectable App</div>
144 <div id='items'></div>