mirror of
https://github.com/wailsapp/wails.git
synced 2026-03-14 14:45:49 +01:00
Update execjs signature
This commit is contained in:
parent
e6805707d8
commit
8d234cc842
2 changed files with 4 additions and 4 deletions
|
|
@ -500,7 +500,7 @@ func (w *WebviewWindow) SetMaxSize(maxWidth, maxHeight int) Window {
|
|||
}
|
||||
|
||||
// ExecJS executes the given javascript in the context of the window.
|
||||
func (w *WebviewWindow) ExecJS(_callID, js string) {
|
||||
func (w *WebviewWindow) ExecJS(js string) {
|
||||
if w.impl == nil && !w.isDestroyed() {
|
||||
return
|
||||
}
|
||||
|
|
@ -657,7 +657,7 @@ func (w *WebviewWindow) HandleMessage(message string) {
|
|||
w.runtimeLoaded = true
|
||||
w.SetResizable(!w.options.DisableResize)
|
||||
for _, js := range w.pendingJS {
|
||||
w.ExecJS("", js)
|
||||
w.ExecJS(js)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1042,7 +1042,7 @@ func (w *WebviewWindow) SetFrameless(frameless bool) Window {
|
|||
|
||||
func (w *WebviewWindow) DispatchWailsEvent(event *WailsEvent) {
|
||||
msg := fmt.Sprintf("_wails.dispatchWailsEvent(%s);", event.ToJSON())
|
||||
w.ExecJS("", msg)
|
||||
w.ExecJS(msg)
|
||||
}
|
||||
|
||||
func (w *WebviewWindow) dispatchWindowEvent(id uint) {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ type Window interface {
|
|||
DispatchWailsEvent(event *WailsEvent)
|
||||
EnableSizeConstraints()
|
||||
Error(message string, args ...any)
|
||||
ExecJS(callID, js string)
|
||||
ExecJS(js string)
|
||||
Focus()
|
||||
ForceReload()
|
||||
Fullscreen() Window
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue