finscn / Ejecta

A Fast, Open Source JavaScript, Canvas & Audio Implementation for iOS
42 stars 6 forks source link

webview ? #11

Open matrixreal opened 9 years ago

matrixreal commented 9 years ago

@finscn hi i would like to try webview in order to test some multiplayer plugin can you provide me an example ? how to lunch a webview

finscn commented 9 years ago

it's here : https://github.com/finscn/Ejecta/blob/master/example/index.js

the key of the code :

if (Ejecta.WebView) {

    window.webview = new Ejecta.WebView();
    webview.hide();
    webview.src = "webview.html";

    webview.addEventListener("load", function() {
        webview.show();
    });

}
matrixreal commented 9 years ago

i'm sorry i don't understand well i have an game with index.js so i have to add the lines of your index.js to mine ? that is ?

matrixreal commented 9 years ago

@finscn its okay i did it but i got message "exported games won't work until you upload them on protocol ..... for security reason

matrixreal commented 8 years ago

@finscn is it possible to use full screen with webview and set the width and height to screen widht and height ? i mean that foe example when i lunch my app and i move by touch to up or down it scroll to up or down i would like that it lock to full screen and do'nt move see the picture attached thanks ejecta

finscn commented 8 years ago

@matrixreal do it via script in your html page.

window.addEventListener("touchmove", function(event) {
    event.preventDefault();
}, false);
matrixreal commented 8 years ago

@finscn this not work but this work perfectly

matrixreal commented 8 years ago

@finscn just one question please ... iAd and admob don't work on web view?

matrixreal commented 8 years ago

@finscn any news ?i just have one question ? does admob and iad work on webview ? thanks for reply

finscn commented 8 years ago

I've no idea ...
I think iAd doesn't support web , Admob may could , but I don't know how to do