Class WebBrowserUtils

Provides Utils to be used by the web browser

Inheritance
WebBrowserUtils
Namespace: VoltstroStudios.UnityWebBrowser.Helper
Assembly: .dll
Syntax
public static class WebBrowserUtils

Methods

| Edit this page View Source

GetAdditionFilesDirectory()

Gets the main directory where logs and cache may be stored

Declaration
public static string GetAdditionFilesDirectory()
Returns
TypeDescription
string
| Edit this page View Source

GetBrowserEnginePath(Engine)

Gets the folder that the UWB process application lives in

Declaration
public static string GetBrowserEnginePath(Engine engine)
Parameters
TypeNameDescription
Engineengine
Returns
TypeDescription
string
| Edit this page View Source

GetBrowserEngineProcessPath(Engine)

Get a direct path to the UWB process application

Declaration
public static string GetBrowserEngineProcessPath(Engine engine)
Parameters
TypeNameDescription
Engineengine
Returns
TypeDescription
string
| Edit this page View Source

GetScreenPointToLocalPositionDeltaOnImage(Graphic, Vector2, out Vector2)

Gets the local position delta (0 -> 1) from a screen position on a Graphic from a top-left origin point

To calculate the pixel position, do Vector2.x * [Desired height] and Vector2.y * [Desired Width]

Declaration
public static bool GetScreenPointToLocalPositionDeltaOnImage(Graphic graphic, Vector2 screenPosition, out Vector2 position)
Parameters
TypeNameDescription
Graphicgraphic

Graphic that you want to calculate the local position on

Vector2screenPosition

The screen position

Vector2position

The local delta position

Returns
TypeDescription
bool
Exceptions
TypeCondition
ArgumentNullException

Thrown if the graphic is null

| Edit this page View Source

IsRunningOnSupportedPlatform()

Checks if UWB is running on a supported platform

Declaration
public static bool IsRunningOnSupportedPlatform()
Returns
TypeDescription
bool