overte/scripts/system/html/js/eventBridgeLoader.js

20 lines
479 B
JavaScript
Raw Permalink Normal View History

//public slots:
// void emitWebEvent(const QString& data);
// void emitScriptEvent(const QString& data);
//
//signals:
// void webEventReceived(const QString& data);
// void scriptEventReceived(const QString& data);
//
2016-01-12 20:41:57 -08:00
var EventBridge;
var WebChannel;
openEventBridge = function(callback) {
WebChannel = new QWebChannel(qt.webChannelTransport, function (channel) {
EventBridge = WebChannel.objects.eventBridge;
callback(EventBridge);
});
}