Coherent UI for .NET  2.5.3
A modern user interface library for games
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
Coherent.UI.BrowserView Class Reference

Class that encapsulates a browser Coherent::UI::View More...

+ Inheritance diagram for Coherent.UI.BrowserView:

Public Member Functions

override ViewType GetViewType ()
 Get The type of this view. More...
 
virtual void GoBack ()
 Navigates back to the previous URL, if any. More...
 
virtual void GoForward ()
 Navigates to the next URL, if any (i.e. available after navigating back) More...
 
virtual void GetHistory ()
 Issues a request for obtaining the navigation history for the view. BrowserViewListener::OnHistoryObtained More...
 
- Public Member Functions inherited from Coherent.UI.View
BoundEventHandle BindCall (string name, System.Delegate handler)
 Expose C++ handler to be called from UI. More...
 
BoundEventHandle RegisterForEvent (string name, System.Delegate handler)
 Expose C++ handler to be called when a specific event occurs. More...
 
void UnregisterFromEvent (BoundEventHandle handle)
 Remove a registered C++ handler. More...
 
void UnbindCall (BoundEventHandle handle)
 Remove a bound C++ handler. More...
 
void UnbindObject (object target)
 Remove all handlers bound to a specific object. More...
 
virtual ViewContext GetContext ()
 Get the view context. More...
 
virtual void Destroy ()
 Destroys this view. After a call to Destroy calling any other method except the destructor results in undefined behavior More...
 
virtual void SetFocus ()
 Sets this view on focus. More...
 
virtual void KillFocus ()
 Removes the focus from this view. More...
 
virtual void MouseEvent (MouseEventData arg0)
 Sends a mouse event to the UI renderer. More...
 
virtual void KeyEvent (KeyEventData arg0)
 Sends a key event to the UI renderer. More...
 
virtual void TouchEvent (TouchEventData events, uint count)
 Sends a touch event to the UI renderer. More...
 
virtual void MouseActivate ()
 Sends a mouse event to the UI renderer. More...
 
virtual int GetWidth ()
 Gets the width of the More...
 
virtual int GetHeight ()
 Gets the height of the More...
 
virtual void Resize (uint width, uint height)
 Send a resize event to the UI renderer. Resize will result in multiple calls to CreateBuffers and DestroyBuffers in the listener More...
 
virtual void IssueMouseOnUIQuery (float normX, float normY)
 Issues a query on the Calling IsMouseOnView while a query is in-flight is an error and will be logged - the result returned by IsMouseOnView in that case is undefined. More...
 
virtual ViewErrorType HasMouseQueryFinished ()
 Returns the status of the mouse query. More...
 
virtual void FetchMouseOnUIQuery ()
 Ends a mouse-on-UI query. Waits for the result. Should be called as far apart from IssueMouseOnUIQuery in order to maximize the chances that the query has finished at the time of this call and no waiting will be performed More...
 
virtual bool IsMouseOnView ()
 Checks if the mouse is currently on the logical view (a part of the view that has elements on it) or not (click-through). Uses the coordinates last set in IssueMouseOnUIQuery. Calling the method while a query is in-flight (between a call to IssueMouseOnUIQuery and FetchMouseOnUIQuery) results in a warning and the return result is undefined More...
 
virtual void SetClickThroughAlphaThreshold (float threshold)
 The alpha value of the pixels is used to determine if the mouse is on an element or on the background (click-through). All pixels below or equal to the alpha threshold (default = 0) are marked as not-belonging to the More...
 
virtual float GetClickThroughAlphaThreshold ()
 Get the currently set alpha threshold for click-through queries. More...
 
virtual void SetTargetFramerate (int target)
 Sets the target frame-rate for the More...
 
virtual int GetTargetFramerate ()
 Get the currently set target frame-rate for the More...
 
virtual bool IsOnDemand ()
 Tells if this is an on-demand view. Frames must be explicitly requested for on-demand views (available only in Full versions of 'Coherent::UI::View::RequestFrame' More...
 
virtual ViewErrorType RequestFrame ()
 Requests a new frame for rendering. All triggered events before this call will be accounted for in the rendered view. Only one frame per-view could be requested simultaneously (available only in Full versions of This function must be called on the ViewContext thread. This overload let's Coherent UI control the time in the view. You should have set ViewInfo::ControlTimeOnDemand to false to use it. If you need to control timing - use the other overload and create the view with ViewInfo::ControlTimeOnDemand set to true. More...
 
virtual ViewErrorType RequestFrame (double timeSinceArbitraryMoment)
 Requests a new frame for rendering. All triggered events before this call will be accounted for in the rendered view. Only one frame per-view could be requested simultaneously (available only in Full versions of This function must be called on the ViewContext thread. This overload let's Coherent UI control the time in the view. You should have set ViewInfo::ControlTimeOnDemand to false to use it. If you need to control timing - use the other overload and create the view with ViewInfo::ControlTimeOnDemand set to true. More...
 
virtual ViewErrorType PeekFrameReady ()
 Tells if the last requested frame is ready or not. Does not block. This call must always be made between calls to RequestFrame and FetchSurface. (available only in Full versions of 'Coherent::UI::View::RequestFrame' 'Coherent::UI::View::FetchSurface' More...
 
virtual ViewErrorType FetchSurface ()
 Returns the requested surface. Works only for on-demand views. All buffered view should use the context's FetchSurfaces method. This call will block until the surface is ready. (available only in Full versions of More...
 
virtual ViewErrorType DrawSurface ()
 [EXPERIMENTAL - DO NOT USE] More...
 
virtual bool UsesSharedMemory ()
 Tells if this view uses shared memory for image transport. More...
 
virtual bool IsTransparent ()
 Tells if this view is transparent or not. More...
 
virtual bool SupportsClickThrough ()
 Tells if this view supports click-through queries or not. More...
 
virtual void Redraw ()
 Request a redraw of the current view. More...
 
virtual void DownloadUrl (string path)
 Initiates a download request on the specified path. More...
 
virtual void Load (string path)
 Loads a new path in the More...
 
virtual void Reload (bool ignoreCache)
 Reloads the last requested or navigated-to path. More...
 
virtual string GetCurentViewPath ()
 Get the last requested or navigated-to path. More...
 
virtual string GetLastRequestedPath ()
 Get the last requested path to load for the More...
 
virtual string GetLastLoadedPath ()
 Get the last successfully loaded path for the More...
 
virtual string GetLastFailedPath ()
 Get the last failed path for the More...
 
virtual void ExecuteScript (string script)
 Execute arbitrary JavaScript code. More...
 
virtual void TriggerEvent (string eventName)
 Triggers a UI event. More...
 
virtual void ReplyToJavaScriptMessage (bool success, string userInput)
 Sends a reply to a javascript message triggered for the view. More...
 
virtual void AuthCredentialsResponse (string username, string password, bool success)
 Sends credentials for a pending authentication request for the view. More...
 
virtual void SetScriptError (ScriptCallErrorType error, string message)
 Sets an error for the currently executing handler. More...
 
virtual void InterceptURLRequests (bool intercept)
 Controls intercepting URL requests. For each request More...
 
virtual void IMEActivate (bool active)
 Sets if the More...
 
virtual bool IMEIsActive ()
 Tells if IME events are currently active for this view. More...
 
virtual bool IMESetComposition (string composition, uint cursorPos, uint targetStart, uint targetEnd)
 Updates the internal state of the IME composition in the More...
 
virtual bool IMEConfirmComposition (string composition)
 Confirms the current IME composition. More...
 
virtual bool IMECancelComposition ()
 Cancels the current IME composition. More...
 
virtual ImageData CreateImageData (string name, int width, int height, IntPtr data, bool flipY)
 Create an More...
 
virtual int GetAudioData (int streamId, IntPtr buffer, int bufferSize, int timeoutMs)
 Obtains audio data for the specified stream in the current view and copies it into the client-provided buffer. More...
 
virtual void SetZoomLevel (double zoomLevel)
 Sets the page zoom level. Specifying 0.0 will reset to the default zoom level. The zoom factor operates on protocol and host level, meaning that all views with the same protocol and host as the current URL will be scaled as well. More...
 
virtual void SetMasterVolume (double volume)
 Sets the master volume for all audio and video streams. More...
 

Detailed Description

Class that encapsulates a browser Coherent::UI::View

Member Function Documentation

virtual void Coherent.UI.BrowserView.GetHistory ( )
inlinevirtual

Issues a request for obtaining the navigation history for the view. BrowserViewListener::OnHistoryObtained

override ViewType Coherent.UI.BrowserView.GetViewType ( )
inlinevirtual

Get The type of this view.

Returns
the type of the view

Reimplemented from Coherent.UI.View.

virtual void Coherent.UI.BrowserView.GoBack ( )
inlinevirtual

Navigates back to the previous URL, if any.

virtual void Coherent.UI.BrowserView.GoForward ( )
inlinevirtual

Navigates to the next URL, if any (i.e. available after navigating back)