Closed StefanCiobanu1989 closed 1 year ago
Hi Stefan, A sample of displaying WebView in desktop form has been added to the repository. This sample changes the user agent of WebView to change the page display to desktop.
// WebViewSample.cs
public void SetUserAgent(string ua)
{
// Change user agent (Switches the browser display to the desktop form).
// WebView.SetUserAgent(string ua)
m_webView.SetUserAgent("Mozilla/5.0 (X11; Linux i686; rv:10.0) Gecko/20100101 Firefox/10.0");
}
SetUserAgent(string ua)
is a new feature added in this update, so clone the latest version of the repository when checking the operation.
See also User agent settings. mozilla user-agent
God like! Thank you!
Hi again, The websites are always displayed in their mobile form, is there a way to change that ? It tried changing TLabWebView and WebView width and height related properties to 1920x1080 and it still shows as the mobile website. Thanks!