Exemple #1
0
// 为窗口设置标题
func win_handler_setTitle(browser *cef.Browser, args []cef.V8Value) (result interface{}) {
	title := cef.V8ValueToString(args[0])

	h := win.HWND(browser.GetWindowHandle())
	win.SetWindowText(h, title)

	return
}
Exemple #2
0
// 创建窗口
func win_handler_create_window(browser *cef.Browser, args []cef.V8Value) (result interface{}) {
	fmt.Println("win_handler_create_window")

	url := cef.V8ValueToString(args[0])
	captionless := cef.V8ValueToBool(args[1])
	gApplication.CreateBrowserWindow(url, captionless)

	return
}