diff --git a/cef/cef-browser-window-views-framework.go b/cef/cef-browser-window-views-framework.go index 6dc37a84..d429f622 100644 --- a/cef/cef-browser-window-views-framework.go +++ b/cef/cef-browser-window-views-framework.go @@ -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)