Jump to content

HTML full screen


Danoon

Recommended Posts

Posted
showCursor 

To inject to browser:

addEventHandler("onClientClick", root, 
    function(button, state) 
        if state == "down" then 
            injectBrowserMouseDown(browser, button) 
        else 
            injectBrowserMouseUp(browser, button) 
        end 
    end 
) 

Posted
showCursor 

To inject to browser:

addEventHandler("onClientClick", root, 
    function(button, state) 
        if state == "down" then 
            injectBrowserMouseDown(browser, button) 
        else 
            injectBrowserMouseUp(browser, button) 
        end 
    end 
) 

I got that but that does not work.

showCursor (true) 
  
addEventHandler("onClientClick", root, 
    function(button, state) 
        if state == "down" then 
            injectBrowserMouseDown(browser, button) 
        else 
            injectBrowserMouseUp(browser, button) 
        end 
    end 
) 
  
--In order to render the browser on the full screen, we need to know the dimensions. 
local screenWidth, screenHeight = guiGetScreenSize() 
  
--Let's create a new browser in local mode. We will not be able to load an external URL. 
local webBrowser = createBrowser(screenWidth, screenHeight, true, false) 
  
--This is the function to render the browser. 
function webBrowserRender() 
    --Render the browser on the full size of the screen. 
    dxDrawImage(0, 0, screenWidth, screenHeight, webBrowser, 0, 0, 0, tocolor(255,255,255,255), true) 
end 
  
--The event onClientBrowserCreated will be triggered, after the browser has been initialized. 
--After this event has been triggered, we will be able to load our URL and start drawing. 
addEventHandler("onClientBrowserCreated", webBrowser,  
    function() 
        --After the browser has been initialized, we can load our file. 
        loadBrowserURL(webBrowser, "login/index.html") 
        --Now we can start to render the browser. 
        addEventHandler("onClientRender", root, webBrowserRender) 
    end 
) 
  

Posted
--In order to render the browser on the full screen, we need to know the dimensions. 
local screenWidth, screenHeight = guiGetScreenSize() 
  
--Let's create a new browser in local mode. We will not be able to load an external URL. 
local webBrowser = createBrowser(screenWidth, screenHeight, true, false) 
  
--This is the function to render the browser. 
function webBrowserRender() 
    --Render the browser on the full size of the screen. 
    dxDrawImage(0, 0, screenWidth, screenHeight, webBrowser, 0, 0, 0, tocolor(255,255,255,255), true) 
end 
  
--The event onClientBrowserCreated will be triggered, after the browser has been initialized. 
--After this event has been triggered, we will be able to load our URL and start drawing. 
addEventHandler("onClientBrowserCreated", webBrowser, 
    function() 
        --After the browser has been initialized, we can load our file. 
        loadBrowserURL(webBrowser, "login/index.html") 
        --Now we can start to render the browser. 
        addEventHandler("onClientRender", root, webBrowserRender) 
        showCursor(true) 
        addEventHandler("onClientClick", root, 
            function(button, state) 
                if state == "down" then 
                    injectBrowserMouseDown(webBrowser, button) 
                else 
                    injectBrowserMouseUp(webBrowser, button) 
                end 
            end 
        ) 
    end 
) 

Posted
--In order to render the browser on the full screen, we need to know the dimensions. 
local screenWidth, screenHeight = guiGetScreenSize() 
  
--Let's create a new browser in local mode. We will not be able to load an external URL. 
local webBrowser = createBrowser(screenWidth, screenHeight, true, false) 
  
--This is the function to render the browser. 
function webBrowserRender() 
    --Render the browser on the full size of the screen. 
    dxDrawImage(0, 0, screenWidth, screenHeight, webBrowser, 0, 0, 0, tocolor(255,255,255,255), true) 
end 
  
--The event onClientBrowserCreated will be triggered, after the browser has been initialized. 
--After this event has been triggered, we will be able to load our URL and start drawing. 
addEventHandler("onClientBrowserCreated", webBrowser, 
    function() 
        --After the browser has been initialized, we can load our file. 
        loadBrowserURL(webBrowser, "login/index.html") 
        --Now we can start to render the browser. 
        addEventHandler("onClientRender", root, webBrowserRender) 
        showCursor(true) 
        addEventHandler("onClientClick", root, 
            function(button, state) 
                if state == "down" then 
                    injectBrowserMouseDown(webBrowser, button) 
                else 
                    injectBrowserMouseUp(webBrowser, button) 
                end 
            end 
        ) 
    end 
) 

Still does not work.

Posted
That doesn't help me. I need more details.

Everything works, the cursor and the browser. But you cannot use the browser. Like click or type.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...