blob: bb804f4a6882535eeeeec2f46edbdc11973ccc11 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
<html>
<head>
<script type="text/javascript" src="qrc:///qwebchannel/webchannel.js"></script>
<script type="text/javascript" src="qrc:///qwebchannel/qobject.js"></script>
<script type="text/javascript">
//BEGIN SETUP
var baseUrl = (/[?&]webChannelBaseUrl=([A-Za-z0-9\-:/\.]+)/.exec(location.search)[1]);
window.channel = new QWebChannel(baseUrl, function(channel) {
setupQObjectWebChannel(channel, function() {
channel.subscribe("Qt.propertyUpdate", function() {
channel.exec({label: "gotPropertyUpdate", values: [myObj.myProperty(), myOtherObj.foo(), myOtherObj.bar()]});
});
});
});
//END SETUP
</script>
</head>
<body>
</body>
</html>
|