After detecting NodeWebkit, Issue`s saw this stream: https://github.com/rogerwang/node-webkit/issues/542
It describes a method with IFrames NodeWebkit: my code is as follows:
var def = $.Deferred(); var $iframe = $('<iframe nwfaketop nwdisable></iframe>') .attr('src', SoundCloud.ConnectUrl) .load(function(e) { var parser = document.createElement('a'); parser.href = this.contentWindow.location.href; var search = parser.search.substr(1, parser.search.length); var result = URLToArray(search); if (result.error !== void 0) { $iframe.remove(); def.reject(result.error_description); } if (result.code !== void 0) { SoundCloud.LoginCode = result.code; $iframe.remove(); def.resolve(); } }) .appendTo($(opts.iframe)); return def;
Hope this helps others with the same problem.
source share