v2.4.2 VF Popup URL

This commit is contained in:
yanghy 2023-01-31 19:44:03 +08:00
parent f6c1c25c95
commit 72b29b471c

View File

@ -137,7 +137,9 @@ func (m *ViewsFrameworkBrowserWindow) registerPopupEvent() {
if !api.GoBool(BrowserWindow.Config.chromiumConfig.enableWindowPopup) {
return true
}
var vfbw = NewViewsFrameworkBrowserWindow(BrowserWindow.Config.ChromiumConfig(), BrowserWindow.Config.WindowProperty, BrowserWindow.MainWindow().AsViewsFrameworkBrowserWindow().Component())
wp := BrowserWindow.Config.WindowProperty
wp.Url = beforePopupInfo.TargetUrl
var vfbw = NewViewsFrameworkBrowserWindow(BrowserWindow.Config.ChromiumConfig(), wp, BrowserWindow.MainWindow().AsViewsFrameworkBrowserWindow().Component())
var result = false
if bwEvent.onBeforePopup != nil {
result = bwEvent.onBeforePopup(sender, browser, frame, beforePopupInfo, vfbw, noJavascriptAccess)