Updating to latest code.
This commit is contained in:
Родитель
6e823bb45f
Коммит
8b1f8e341c
|
@ -4,39 +4,17 @@
|
||||||
<script src="//www.gstatic.com/cast/sdk/libs/receiver/2.0.0/cast_receiver.js"></script>
|
<script src="//www.gstatic.com/cast/sdk/libs/receiver/2.0.0/cast_receiver.js"></script>
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
color: white;
|
color: yellow;
|
||||||
|
background-color: white;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<script src="adapter.js"></script>
|
<script src="adapter.js?1"></script>
|
||||||
<script src="mozdemo.js?5"></script>
|
<script src="mozdemo.js?1"></script>
|
||||||
<link rel='stylesheet' href="demostyle.css"></link>
|
<link rel='stylesheet' href="demostyle.css?3"></link>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<span>hello</span>
|
<video id="video" autoplay="TRUE"></video><br/>
|
||||||
<span style="color:red">world 5</span>
|
|
||||||
<div id="header"><h2>TabCast: You are the sender</h2></div>
|
|
||||||
<div id="status"></div>
|
|
||||||
<div id="sender_inst">
|
|
||||||
<div>Open this link in another tab or browser</div>
|
|
||||||
<div> <a id="link">right click here</a></div>
|
|
||||||
<div>That other tab or browser will have text in a red box that you'll paste here:</div>
|
|
||||||
<textarea id="answer"></textarea>
|
|
||||||
<button onclick="answer_click()">submit answer</button>
|
|
||||||
</div>
|
|
||||||
<div style="display:none" id="receiver_inst">
|
|
||||||
<div>Copy this text and paste it into the input box of the sender tab</div>
|
|
||||||
<div style="border:thin red solid" id="answer_json"> </div>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
|
|
||||||
<div id="remote">
|
|
||||||
<div id="remote-caption"><h2>Remote</h1></div>
|
|
||||||
<div>
|
|
||||||
<video style="border:thin blue solid" id="video" width="320" height="240" autoplay="TRUE"></video><br/>
|
|
||||||
</div><br/>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div style="color:green; font-size: xx-small;" id="logwindow"></div>
|
<div style="color:green; font-size: xx-small;" id="logwindow"></div>
|
||||||
|
|
||||||
|
|
||||||
|
@ -45,10 +23,6 @@
|
||||||
var me = "castee";
|
var me = "castee";
|
||||||
var them = "caster";
|
var them = "caster";
|
||||||
var start = false;
|
var start = false;
|
||||||
document.getElementById("sender_inst").style.display = "none";
|
|
||||||
document.getElementById("receiver_inst").style.display = "block";
|
|
||||||
document.getElementById("header").firstChild.innerHTML = "TabCast: You are the reciever";
|
|
||||||
|
|
||||||
var extra = {};
|
var extra = {};
|
||||||
if (true ) {
|
if (true ) {
|
||||||
extra.video=true;
|
extra.video=true;
|
||||||
|
@ -91,7 +65,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
window.messageBus = window.castReceiverManager.getCastMessageBus('urn:x-cast:org.mozilla.castin');
|
window.messageBus = window.castReceiverManager.getCastMessageBus('urn:x-cast:org.mozilla.mirror');
|
||||||
ui_log("bus: " + messageBus);
|
ui_log("bus: " + messageBus);
|
||||||
//window.messageBus.broadcast("broadcast");
|
//window.messageBus.broadcast("broadcast");
|
||||||
window.messageBus.onMessage = function(event) {
|
window.messageBus.onMessage = function(event) {
|
||||||
|
|
|
@ -31,3 +31,10 @@ html, body {
|
||||||
clear:both;
|
clear:both;
|
||||||
display:none;
|
display:none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#video {
|
||||||
|
width:100%;
|
||||||
|
height:100%;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
|
@ -21,11 +21,6 @@ var color_log = function(msg, color) {
|
||||||
var out_queue = []
|
var out_queue = []
|
||||||
var in_queue = null;
|
var in_queue = null;
|
||||||
|
|
||||||
function answer_click() {
|
|
||||||
var textarea = document.getElementById("answer");
|
|
||||||
in_queue = JSON.parse(textarea.value);
|
|
||||||
console.log("got " + in_queue.length + " messages");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче