SEBWIN-141: Made workaround for initial touch activation of browser control permanent, as there appears to be no other way to fix the issue.
This commit is contained in:
parent
41d2345405
commit
0bca109ad8
1 changed files with 12 additions and 0 deletions
|
@ -6,6 +6,7 @@
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
using System;
|
||||||
using CefSharp;
|
using CefSharp;
|
||||||
using CefSharp.WinForms;
|
using CefSharp.WinForms;
|
||||||
using SafeExamBrowser.Contracts.UserInterface.Browser;
|
using SafeExamBrowser.Contracts.UserInterface.Browser;
|
||||||
|
@ -107,5 +108,16 @@ namespace SafeExamBrowser.Browser
|
||||||
{
|
{
|
||||||
GetBrowser().SetZoomLevel(level);
|
GetBrowser().SetZoomLevel(level);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected override IWindowInfo CreateBrowserWindowInfo(IntPtr handle)
|
||||||
|
{
|
||||||
|
const uint WS_EX_NOACTIVATE = 0x8000000;
|
||||||
|
var windowInfo = base.CreateBrowserWindowInfo(handle);
|
||||||
|
|
||||||
|
// Ensures that input elements within the browser control actually receive input when activated via touch.
|
||||||
|
windowInfo.ExStyle &= ~WS_EX_NOACTIVATE;
|
||||||
|
|
||||||
|
return windowInfo;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue