Compare commits

..

175 Commits

Author SHA1 Message Date
Misite Bao 7670273d43 feat(website): init the website 2023-05-30 16:57:54 +08:00
Lea Anthony a15c0a5441 [v3] Website skeleton 2023-05-30 16:56:35 +08:00
Lea Anthony 19be7f61ac [v3 windows] Fix resizing. Add resize debouncing 2023-05-30 16:36:00 +08:00
Misite Bao bbf0e8cdad chore: split Taskfile (#2654) 2023-05-30 16:35:59 +08:00
Lea Anthony 7e2d2a29a1 [v3 windows] Initial webview2 working 2023-05-30 16:33:34 +08:00
Lea Anthony 671dc2aa3a [v3 windows] Implement start x/y + parent window for dialogs 2023-05-30 16:33:34 +08:00
Lea Anthony 294a2c701e [v3] Update esbuild 2023-05-30 16:33:34 +08:00
Lea Anthony 01f03c552d [v3] Improve invoke 2023-05-30 16:33:33 +08:00
Lea Anthony dc46154d94 [v3 mac] Support drag 2023-05-30 16:33:33 +08:00
Lea Anthony 87737c23eb [v3 mac] DisableWindowShadow -> DisableShadow 2023-05-30 16:33:33 +08:00
Lea Anthony 6e6f099a99 [v3 mac] Basic common event support. Taskfile refactor 2023-05-30 16:33:32 +08:00
Lea Anthony 4cb3321c39 [v3 mac] Update README 2023-05-30 16:32:02 +08:00
Lea Anthony 6a2343a1a0 [v3 mac] Add DisableWindowShadow option 2023-05-30 16:32:01 +08:00
Lea Anthony f2d6dba2cf [v3 windows] initial dialog support. Refactor button callback name 2023-05-30 16:32:01 +08:00
stffabi dd1ef7fae9 [v3 darwin] Add darwin identifier darwin only file 2023-05-30 16:32:01 +08:00
stffabi 527cff9ec3 [v3 darwin] Add darwin identifier to all C files of darwin 2023-05-30 16:32:00 +08:00
stffabi ba150eccae [v3 windows] Add close handling: HideOnClose, QuitOnLastWindowClosed and DisableQuitOnLastWindowClosed 2023-05-30 16:32:00 +08:00
Travis McLane fa74986f1e [v3 example] menu text toggle 2023-05-30 16:32:00 +08:00
Travis McLane d1085b5bea [v3 example] add menuitem.Hidden / setHidden example 2023-05-30 16:31:59 +08:00
Travis McLane 4d0a14d2eb [v3 darwin] menuitem.setHidden implementation 2023-05-30 16:31:59 +08:00
Travis McLane 8c3439b733 [dialogs] remove default title
without this removal a user would have to call `SetTitle("")` in order to
erase the default if they desire a title-less dialog.
2023-05-30 16:31:59 +08:00
stffabi a0534d527a [v3 application] Fix race conditions between starting a window/systray and starting the application
Make sure a window is never run before the windowCreated hooks have been executed.
2023-05-30 16:31:59 +08:00
Lea Anthony a5b52f2795 [v3 windows] initial systray support 2023-05-30 16:31:58 +08:00
Lea Anthony b526ebd679 [v3 mac] Update api. New template icon. 2023-05-30 16:31:58 +08:00
Lea Anthony 51b9315ae9 [v3 windows] update status 2023-05-30 16:31:58 +08:00
Lea Anthony 8edf44dc31 [v3 windows] New icons 2023-05-30 16:31:57 +08:00
Lea Anthony 9b7626e59e [v3 windows] Move icons to own package, systray dark mode icon, window.Focus(), 2023-05-30 16:31:57 +08:00
Lea Anthony 6dd092c7a9 [v3 windows] Rename systray callback handlers 2023-05-30 16:31:57 +08:00
Lea Anthony 46a0d467c0 [v3 windows] Dialogs to use invokeSync 2023-05-30 16:31:56 +08:00
Lea Anthony e3b164ae93 [v3 windows] Systray callback handlers 2023-05-30 16:31:56 +08:00
stffabi d8f58ab20f [v3 windows] Fix wndproc default case with WMMessageToString 2023-05-30 16:31:56 +08:00
stffabi 0de2bccd28 [v3 windows] Do not disable WndProc messaging for systray when updating icon 2023-05-30 16:31:55 +08:00
Lea Anthony 2eaf724710 [v3 windows] Fix systray icon size 2023-05-30 16:31:55 +08:00
Lea Anthony 58138ac09b [v3 windows] Initial systray support 2023-05-30 16:31:55 +08:00
Lea Anthony 143f090422 [v3] Use invokeSync for systray methods 2023-05-30 16:31:55 +08:00
Lea Anthony f8f466ba7e [v3 windows] Support irregular shaped windows. Centered option. 2023-05-30 16:31:54 +08:00
Lea Anthony cb28de47f8 [v3 windows] Support irregular shaped windows 2023-05-30 16:31:54 +08:00
stffabi 4ad2475ed6 [v3] Add some missing methods for darwin and windows 2023-05-30 16:31:54 +08:00
Travis McLane 0172078536 [w32] move windows specific code to impl file 2023-05-30 16:31:53 +08:00
Travis McLane 0bb1fb512a [w32] add missing build constraint 2023-05-30 16:31:53 +08:00
Lea Anthony b6940d95a2 [v3 windows] Add frameless resize 2023-05-30 16:31:53 +08:00
stffabi 75f0457375 [v3 windows] Add HiDPI awareness 2023-05-30 16:31:52 +08:00
stffabi ffe31b6265 [v3 windows] Add frameless support 2023-05-30 16:31:52 +08:00
Lea Anthony 8963610722 [v3 windows] Implement getScreen 2023-05-30 16:31:52 +08:00
Lea Anthony 66bfcf0e36 [v3] Ensure impl calls from WebvieWindow are on the main thread. Support size. 2023-05-30 16:31:52 +08:00
Lea Anthony 0b3559abfe [v3] Fix examples 2023-05-30 16:31:51 +08:00
Lea Anthony 773389ee5e [v3] Update examples to use correct options. 2023-05-30 16:31:51 +08:00
Lea Anthony 4c04991d4d [v3] Change WebviewWindow options to be a value, not a pointer. Support Un/Fullscreen. Remove main thread switching. Use parent options instead of local variables. 2023-05-30 16:31:51 +08:00
Lea Anthony d56bb59b72 [v3 Windows] Support application hide/show. Add WebviewWindow.IsVisible(). 2023-05-30 16:31:50 +08:00
Lea Anthony 6e92a4f71e [v3 Windows] Support setMin/MaxSize, setPosition 2023-05-30 16:31:50 +08:00
Lea Anthony 1f6217c0d8 [v3 Windows] Add Support for SetTitle, Center, Un/Minimise/Maximise, IsMin/Maximised, IsNormal, Show/Hide 2023-05-30 16:31:50 +08:00
Lea Anthony 17204bebd0 [v3 Breaking Change] Add NativeWindowHandle method to WebviewWindow. 2023-05-30 16:31:49 +08:00
Lea Anthony 728e2019d8 [v3 windows] Moved w32 from internal to pkg so it may be used by applications 2023-05-30 16:31:49 +08:00
Lea Anthony 7f3fdd6977 [v3 windows] Add WndProcInterceptor for custom message processing 2023-05-30 16:31:49 +08:00
Lea Anthony e8798f8371 [v3 windows] Rename options_windows.go -> options_win.go 2023-05-30 16:31:48 +08:00
Lea Anthony 402b743553 [v3 windows] Add APM Events 2023-05-30 16:31:48 +08:00
Lea Anthony f08ae2fc62 [v3] Update application.On and window.On to return functions that unregister the listener. WebviewWindow.onApplicationEvent is a helper which will manage the unregistering for you on window destroy. 2023-05-30 16:31:48 +08:00
Lea Anthony 178ea9c8c5 [windows] Split out wndProc. Generate windows events, support per-window themes 2023-05-30 16:31:48 +08:00
Lea Anthony 7c63cee9e8 [windows] Support AlwaysOnTop, EnableResize at runtime. Added Solid/Transparent/Translucent options. 2023-05-30 16:31:47 +08:00
stffabi 4a60dfc373 [v3, windows] Add MainThread dispatching and fixes the blocking window 2023-05-30 16:31:47 +08:00
Lea Anthony 829a829cb4 [windows] WIP 2023-05-30 16:31:47 +08:00
Travis McLane 34896ccb4e [darwin] add getPrimaryScreen/getScreens to impl (#2618) 2023-05-30 16:31:46 +08:00
Lea Anthony 5df5eb6a04 Fix module path for non-modified repo 2023-05-30 16:31:46 +08:00
Lea Anthony 31ba36baf3 [windows] Initial commit 2023-05-30 16:31:46 +08:00
Lea Anthony bf10f71760 [windows] Fix paths for wails init 2023-05-30 16:31:45 +08:00
Lea Anthony 8aa61fff6d Intial STATUS.md commit 2023-05-30 16:31:45 +08:00
Misite Bao d3a4d89786 chore: add Prettier as format tool (#2689) 2023-05-30 07:40:54 +10:00
Lea Anthony 84919468ba [v2 docs] Fix cli.mdx 2023-05-27 13:30:24 +10:00
Misite Bao bd5b7e5e3f feat(website): update the Crowdin branch (#2688) 2023-05-27 12:51:43 +10:00
Lea Anthony 4f3dc1b0e1 [v2 docs] Fix changelog + cli options. 2023-05-27 12:49:10 +10:00
Marvin Wendt 65c68301a0 Change style of doctor command (#2660)
* Refactor doctor command

* Refactor doctor command

* Refactor doctor command

* Refactor doctor command

* Added changelog entry
2023-05-26 17:55:53 +10:00
Misite Bao 37e43dabc0 docs: improve documentation (#2686)
* docs: fix changelog format

* fix: fix release tools

* chore: set sync translated documents as a scheduled task
2023-05-26 17:49:50 +10:00
github-actions[bot] ec19458c1b docs: sync translations (#2616)
Co-authored-by: misitebao <misitebao@users.noreply.github.com>
2023-05-25 18:43:31 +10:00
Amin Yahyaabadi 35eb1e0160 fix: avoid app crashing when the Linux GTK key is empty (#2672)
* fix: avoid app crash when the Linux GTK key is empty

Fixes this error:

```
DEBUG | Log dir is: /root/.config/surrealdb_explorer/log.txt

Overriding existing handler for signal 10. Set JSC_SIGNAL_FOR_GC if you want WebKit to use a different signal
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running, locked to thread]:
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.parseKey({0x0, 0x0})
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/keys.go:87 +0xa5
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.acceleratorToGTK(0xc0001c5f20)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/keys.go:72 +0x2c
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.processMenuItem(0x866bc0?, 0xc0001c8a80, 0xc0001c8a80?)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/menu.go:159 +0x40b
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.processSubmenu(0xc0001c8a20, 0x79a2a9?)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/menu.go:99 +0xdc
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.processMenu(0xc00021f6c0, 0x12?)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/menu.go:82 +0x46
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.(*Window).SetApplicationMenu(0xc00021f6c0, 0xc000128dc8)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/menu.go:75 +0x1b6
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.NewWindow(0xc00011ba40, 0x0)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/window.go:126 +0x37b
github.com/wailsapp/wails/v2/internal/frontend/desktop/linux.NewFrontend({0x1cea4e8?, 0xc00023b890}, 0xc00011ba40, 0xc000128e40, 0xc0001c8b40, {0x1ce7480?, 0xc000139840})
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/linux/frontend.go:182 +0x5c5
github.com/wailsapp/wails/v2/internal/frontend/desktop.NewFrontend(...)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/frontend/desktop/desktop_linux.go:16
github.com/wailsapp/wails/v2/internal/app.CreateApp(0xc00011ba40)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/internal/app/app_production.go:84 +0x5a5
github.com/wailsapp/wails/v2/pkg/application.(*Application).Run(0xc000131940)
        /home/aminya/go/pkg/mod/github.com/wailsapp/wails/v2@v2.5.1/pkg/application/application.go:57 +0x29
wails_vue/backend.BootApplication(0xc000131640, 0xc000138a40, 0xc0001c5320, 0xc0001c55c0, 0xc000128b40, 0xc00012ec30, 0xc000131880)
        /home/aminya/Documents/GitHub/teamnoon/SurrealDB-Explorer/backend/Application.go:103 +0x718
reflect.Value.call({0x874160?, 0x1c761f0?, 0xc000138a00?}, {0x8e263d, 0x4}, {0xc0001584d0, 0x7, 0x1c761f0?})
        /usr/local/go/src/reflect/value.go:586 +0xb0b
reflect.Value.Call({0x874160?, 0x1c761f0?, 0x1c761f0?}, {0xc0001584d0?, 0x0?, 0x1c761f0?})
        /usr/local/go/src/reflect/value.go:370 +0xbc
github.com/Envuso/go-ioc-container.(*Invocable).CallMethodWith(0xc000138a00, 0x1c761f0?, {0x0?, 0x1cef290?, 0x8bd180?})
        /home/aminya/go/pkg/mod/github.com/!envuso/go-ioc-container@v0.0.5/invocable.go:149 +0xad
github.com/Envuso/go-ioc-container.(*ContainerInstance).Call(0xc00011c630?, {0x874160?, 0x1c761f0?}, {0x0, 0x0, 0x0})
        /home/aminya/go/pkg/mod/github.com/!envuso/go-ioc-container@v0.0.5/container_invocation.go:30 +0x6c
main.main()
        /home/aminya/Documents/GitHub/teamnoon/SurrealDB-Explorer/main.go:34 +0x112
```

* fix: merge the key length comparison
2023-05-25 18:40:37 +10:00
github-actions[bot] 12a9ff17d6 chore: update sponsors.svg (#2683)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-05-25 17:05:48 +10:00
Lea Anthony a7116ff5e7 [website] Add windows icon troubleshooting guide 2023-05-21 17:55:38 +10:00
Lea Anthony 62d97f85ec v2.5.1 2023-05-16 19:43:41 +10:00
stffabi 496461920f [v2] DevServer improvements and fixes (#2664)
* [assetserver, darwin] Fix copying request headers by using strdup

* [assetserver, linux] Fake some basic http headers for legacy webkit2 versions to support proxying requests to other servers

This fixes the devserver on v2 for newer vite versions that use the custom
scheme.

* [v2, windows] 304 responses are going to hang the WebView2 so prevent them by removing cache related headers in the request.

* [v2, dev] Now uses the custom schemes `wails://` on macOS and Linux for all Vite versions.

Prevent missing reload after fast multiple savings on Linux and Windows.
2023-05-16 09:35:48 +02:00
stffabi 22b53192e6 [v2, webview2loader] Prevent env and registry overrides when using the go loader (#2668) 2023-05-15 21:12:16 +02:00
Lea Anthony c1a0e1338f Add PR template 2023-05-14 08:46:57 +10:00
Lea Anthony 7266f2a78a Add PR template 2023-05-14 08:42:03 +10:00
Lea Anthony 774cbdec38 Update changelog.mdx 2023-05-13 14:49:07 +10:00
Lea Anthony ba6b28b3c2 v2.5.0 2023-05-13 14:18:06 +10:00
Misite Bao 3d68ef0115 chore: update channel (#2648) 2023-05-13 13:48:11 +10:00
github-actions[bot] 0342023990 chore: update sponsors.svg (#2656)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-05-13 13:44:15 +10:00
github-actions[bot] 2922a98f7c chore: update sponsors.svg (#2650)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-05-06 11:16:28 +10:00
Misite Bao b82be31d7e chore: remove the v1 content (#2641)
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-05-04 18:36:01 +10:00
github-actions[bot] 8d7c033a66 chore: update sponsors.svg (#2643)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-05-03 19:52:34 +10:00
Misite Bao 516c4853f9 feat(cli): use Spinner instead of Print (#2637) 2023-05-01 22:57:10 +10:00
LGiki 832d6bc4d3 [v2, linux] Fix StartHidden option not working on Linux (#2624)
* fix: StartHidden option not working on Linux

* chore: add an entry to the changelog
2023-04-30 01:20:39 +10:00
dependabot[bot] fa0afe92f0 Bump yaml from 2.2.1 to 2.2.2 in /v3/internal/runtime (#2623)
Bumps [yaml](https://github.com/eemeli/yaml) from 2.2.1 to 2.2.2.
- [Release notes](https://github.com/eemeli/yaml/releases)
- [Commits](https://github.com/eemeli/yaml/compare/v2.2.1...v2.2.2)

---
updated-dependencies:
- dependency-name: yaml
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-29 20:42:50 +10:00
github-actions[bot] ea40cf8705 chore: update sponsors.svg (#2630)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-28 18:27:29 +10:00
stffabi 3853d2d1bf [v2, windows] Handle webview2 process crashes and add DisableWebViewRendererCodeIntegrity flag (#2627)
* Add flag to disable webview RendererCodeIntegrity checks
* Handle webview2 process crashes
2023-04-27 23:03:26 +02:00
Dominic Lee d249c2207b fix: parse struct references for type generation (#2552)
* fix: parse struct references for type generation

* chore: update changelog for typescript generation fix
2023-04-26 23:23:39 +10:00
stffabi 0bf41090b0 [v2, darwin] Add some missing default shortcuts (#2586)
* [v2, darwin] Add "Hide, Hide Others, Show All“ to appmenu

This also includes shortcuts support for those commands.
Arrange the menu items in the well known MacOS order.

* [v2, darwin] Add Window menu with well known shortcuts Minimize, Full-Screen and Zoom.
2023-04-20 12:38:32 +02:00
stffabi 529ec569f7 [v2, dev] Use custom schemes for in-app dev mode (#2610)
This fixes some long-standing inconsistencies between
dev mode builds and production builds but is a breaking
change. Dev mode uses custom scheme for Vite versions >= 3.0.0
and for older it still behaves in the old way.
2023-04-20 12:37:40 +02:00
stffabi 7c1490a8b1 [assetServer] Improve release/close handling of webview requests (#2612) 2023-04-20 12:06:37 +02:00
github-actions[bot] c7e5608a60 docs: sync translations (#2581)
Co-authored-by: misitebao <misitebao@users.noreply.github.com>
2023-04-17 23:48:27 +10:00
Misite Bao d8d4997532 chore: optimize website building process (#2601)
* chore: remove pnpm from dependencies

* chore: upgrade devDependencies

* chore: set Nodejs version
2023-04-17 20:54:06 +10:00
github-actions[bot] a1cc41c926 chore: update sponsors.svg (#2603)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-17 20:51:33 +10:00
stffabi 767bfcff89 [v2, windows] Make sure to open the CommonFileDialogs on the main thread (#2606)
Otherwise it might have some strange side-effects like blocking
the completion of Deferrals in WebView2 when using custom
IStreams.
2023-04-17 20:50:27 +10:00
Lea Anthony 46bcce7566 [website] Upgrade pnpm-lock.yaml 2023-04-16 20:58:19 +10:00
Lea Anthony c4609efe01 [website] Upgrade pnpm 2023-04-16 20:26:43 +10:00
Lea Anthony cc6518f984 Remove label-sponsors workflow for now 2023-04-16 20:22:56 +10:00
Lea Anthony 69d3a3f639 Remove generate-contributors workflow for now 2023-04-16 20:21:45 +10:00
Joshua Hull 489689b477 Use json.Marshal instead of strconv.Quote to correctly support unicode (#2509)
* Use json.Marshal instead of strconv.Quote to correctly support unicode

* Add fix to changelog

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-16 10:19:40 +10:00
George Wang eaca3d06f6 Update zypper.go (#2593)
Add package(webkit2gtk3-soup2-devel) for `libwebkit`.
Change environment variable before running command to query information
of the package.
2023-04-16 10:00:39 +10:00
Matthew Davis b302064f2f Feature/templates/angular15 (#2595)
* added new angular template

* removed 2-year old template

* renamed to wails-template-angular from wails-angular-template

* added previous template back
2023-04-16 09:58:36 +10:00
Lea Anthony 67063d419c Update generate-contributors.yml 2023-04-15 20:40:45 +10:00
github-actions[bot] 03cef1887f chore: update sponsors.svg (#2596)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-15 18:14:43 +10:00
Lea Anthony 929593c5b8 Update generate-contributors.yml 2023-04-14 20:16:01 +10:00
Lea Anthony 57e718af68 Update generate-contributors.yml 2023-04-14 20:10:29 +10:00
github-actions[bot] f96aab0d44 chore: update sponsors.svg (#2591)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-14 20:08:52 +10:00
Lea Anthony 140e3b5947 Update generate-contributors.yml 2023-04-14 20:05:45 +10:00
Lea Anthony a8339c9e93 Update generate-contributors.yml 2023-04-14 20:04:12 +10:00
stffabi 39a7ab5856 [assetserver, linux] Add support for WebKit2GTK 2.40+ features (#2592) 2023-04-14 11:16:27 +02:00
stffabi ec3da8b7ef [v2, darwin] Fix updating the menu on runtime (#2588) 2023-04-14 00:14:19 +10:00
stffabi b64b2a8da1 [v2, dev] Fix skipbindings flag in wails dev (#2584) 2023-04-13 07:45:49 +10:00
Misite Bao 1979bca0f5 chore: fix pnpm environment settings (#2580) 2023-04-12 22:21:25 +10:00
Misite Bao 0f791c71f4 fix: fix website build and add taskfile (#2577)
* chore: update dependencies

* docs: update source documents

* chore: use Taskfile instead of scripts
2023-04-12 21:36:01 +10:00
Travis McLane fbe7d4de6b Bugfix/remove miniaturize (#2579)
* remove duplicate 'minimize' from interface

already covered by 'minimise'

* [darwin] remove windowMiniaturize

duplicates the logic in windowMinimise

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-12 21:34:31 +10:00
stffabi c8d203d4d6 [v3, darwin] Fix leaking WebKit processes on Window close (#2574)
* [v3, darwin] Fix leaking WebKit processes on Window close

* [v3] Remove window from window map if closed
[v3] Implement `HideOnClose` and ensure it isn't removed when closed

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-12 21:33:00 +10:00
Lea Anthony f335cbd608 Update generate-contributors.yml 2023-04-12 08:44:17 +10:00
Lea Anthony b67d1e72a7 Update generate-contributors.yml 2023-04-12 08:41:28 +10:00
Misite Bao 5e3c736bee feat(cli): add Nodejs version in wails doctor (#2546)
* feat(cli): add Nodejs version in `wails doctor`

* Added check for output length

* docs: update changelog.mdx

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-12 07:11:37 +10:00
Lea Anthony abc8f71a8d Update generate-contributors.yml 2023-04-11 21:29:41 +10:00
Lea Anthony cf8bb49093 Update generate-contributors.yml 2023-04-11 21:25:36 +10:00
Lea Anthony 3f62fa0d86 Update credits.mdx 2023-04-11 20:46:45 +10:00
Lea Anthony 8b977bcab4 Update generate-contributors.yml 2023-04-11 20:46:28 +10:00
Lea Anthony 3a1aeaab94 Update generate-contributors.yml 2023-04-11 20:22:27 +10:00
Travis McLane a7bf359930 update wml events to be parseable (#2561)
* update wml events to be parseable

* [v3] Rename `CustomEvent` to `WailsEvent` to prevent clashing with the standard JS `CustomEvent` object

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-11 18:28:06 +10:00
github-actions[bot] 9574bfc054 chore: update sponsors.svg (#2566)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-11 18:26:28 +10:00
希嘉嘉 739ca98597 Update templates.mdx (#2571) 2023-04-10 22:00:04 +10:00
Lea Anthony 424e4fc2e8 [v3] Add ability to get window by name 2023-04-07 19:47:01 +10:00
Misite Bao 7f1093dc51 chore: update auto workflows (#2555)
* chore: update workflows

* chore: update Taskfile

* chore: add lable to auto-sync pr
2023-04-07 18:19:14 +10:00
Lea Anthony a998465034 [v3] Update start_at_login plugin to allow better compilation on Linux 2023-04-06 08:29:20 +10:00
Lea Anthony 755e869fe7 [v3] Add start_at_login plugin
[v3] Fix plugin startup/shutdown order
2023-04-05 21:22:02 +10:00
Lea Anthony 7ecbc846b4 [v3] Improved plugin shutdown 2023-04-04 18:01:49 +10:00
Lea Anthony 767b7d6026 Check out repo for contributors workflow 2023-04-03 08:43:57 +10:00
Lea Anthony 086953bbe9 Do not directly commit contributors sag 2023-04-03 08:39:42 +10:00
Lea Anthony c51df752a1 Create PR for contributors SVG 2023-04-03 08:37:46 +10:00
Lea Anthony ea3b7ed9dd Generate Contributors SVG 2023-04-03 08:33:55 +10:00
dependabot[bot] ef6366af61 Bump webpack from 5.75.0 to 5.76.2 in /website (#2503)
Bumps [webpack](https://github.com/webpack/webpack) from 5.75.0 to 5.76.2.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.75.0...v5.76.2)

---
updated-dependencies:
- dependency-name: webpack
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-01 22:02:24 +11:00
dependabot[bot] 488666f407 Bump undici from 5.13.0 to 5.21.0 in /scripts/sponsors (#2502)
Bumps [undici](https://github.com/nodejs/undici) from 5.13.0 to 5.21.0.
- [Release notes](https://github.com/nodejs/undici/releases)
- [Commits](https://github.com/nodejs/undici/compare/v5.13.0...v5.21.0)

---
updated-dependencies:
- dependency-name: undici
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-01 22:00:55 +11:00
Simon Shutter 34fd76617e annotated menu example and updated runtime.Quit call (#2539) 2023-04-01 21:50:29 +11:00
憧憬Licoy 1e8b938d15 fix obfuscate build param name (#2542)
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-04-01 21:48:03 +11:00
Lea Anthony 3404250ac8 [v3] Add single_instance plugin 2023-04-01 20:36:55 +11:00
Misite Bao eddc949295 fix: fix console printing (#2483) 2023-04-01 18:22:27 +11:00
Misite Bao 49bd33e642 docs: update routing.mdx (#2547) 2023-04-01 16:05:09 +11:00
github-actions[bot] 78f638a9bc docs: sync documents (#2514)
Co-authored-by: misitebao <misitebao@users.noreply.github.com>
2023-04-01 16:04:43 +11:00
github-actions[bot] fef6e2a616 chore: update sponsors.svg (#2535)
Co-authored-by: leaanthony <leaanthony@users.noreply.github.com>
2023-04-01 16:03:09 +11:00
Noah Gorstein 2a22933220 docs: fix broken link for react router HashRouter (#2544) 2023-04-01 08:43:15 +11:00
Lea Anthony eae4fe62cd Merge branch 'v3/api-package' 2023-03-31 20:39:41 +11:00
stffabi b3a9332a5b [assetserver] Add linux platform implementation (#2543) 2023-03-31 20:39:13 +11:00
Lea Anthony e91b7832ee Provide types to runtime api 2023-03-31 20:37:50 +11:00
stffabi db527c0fc2 [assetserver] Add linux platform implementation (#2543) 2023-03-31 10:08:31 +02:00
Lea Anthony 0d25edc0c4 Improved api package 2023-03-30 12:51:43 +11:00
Lea Anthony eb36258c73 Merge branch 'master' into v3/plugins 2023-03-27 20:58:00 +11:00
Misite Bao bdb138d42c chore: fix push.yml (#2530) 2023-03-27 07:37:38 +11:00
Arpit Jain abe6f520b4 Fix dates in changelog (#2527) 2023-03-26 16:19:12 +11:00
Lea Anthony 365aaf6bb1 Add sqlite plugin 2023-03-25 09:39:59 +11:00
Lea Anthony 5949e305ea Reorder startup sequence
Add plugin scripts to asset server
Add InjectJS support in plugins
2023-03-24 08:43:00 +11:00
Lea Anthony bf86b0d9c1 Add Window creation hooks
Add InjectJS() to plugins interface
2023-03-23 06:51:24 +11:00
Lea Anthony d5808fde59 Simple logging plugin 2023-03-22 20:56:45 +11:00
Lea Anthony 3ae604e474 Exported() -> CallableByJS() 2023-03-22 20:42:20 +11:00
Lea Anthony 42fb91bc73 Fix for variadic args in bound methods 2023-03-22 20:36:46 +11:00
Lea Anthony 4165caa02e Add Exported() []string to plugin API 2023-03-21 08:55:55 +11:00
Lea Anthony b656bd2194 Prevent beeps when pressing a key in Mac window 2023-03-20 20:48:22 +11:00
Lea Anthony ba82f27534 Fix Bug with nil parameters.
Added browser and kvstore plugins.
2023-03-20 20:28:33 +11:00
Lea Anthony 13f620ae54 Add plugin init. Update plugin signature. 2023-03-19 09:13:05 +11:00
Lea Anthony c774af48b7 Extend call subsystem to support plugins 2023-03-18 09:12:44 +11:00
Lea Anthony 4300521064 Initial implementation 2023-03-18 08:11:36 +11:00
Lea Anthony 86aaa3a956 Merge branch 'v3/central-assetserver' into v3/plugins 2023-03-17 17:03:21 +11:00
stffabi 74f349862e [v3] AssetServer options update comments 2023-03-16 06:49:46 +01:00
stffabi 0e614b0194 [v3] Centralize the AssetServer and move it to the application 2023-03-16 06:49:45 +01:00
1339 changed files with 61273 additions and 67268 deletions
-1
View File
@@ -1 +0,0 @@
runtime/assets/default.html
-30
View File
@@ -1,30 +0,0 @@
{
"env": {
"browser": true,
"es6": true,
"node": true,
},
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": 2016,
"sourceType": "module",
},
"rules": {
"indent": [
"error",
"tab"
],
"linebreak-style": [
"error",
"unix"
],
"quotes": [
"error",
"single"
],
"semi": [
"error",
"always"
]
}
}
+4
View File
@@ -1,5 +1,9 @@
blank_issues_enabled: true
contact_links:
- name: Discord Chat
url: https://discord.gg/BrRSWTaxVK
about: Ask questions and discuss with other Wails users in real time.
- name: GitHub Community Discussions
url: https://github.com/wailsapp/wails/discussions
about: If your question is not a feature or a bug, please go to the discussion panel and retrieve if your question already exists before submitting.
+37
View File
@@ -0,0 +1,37 @@
# Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes # (issue)
## Type of change
Please delete options that are not relevant.
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update
# How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration using `wails doctor`.
- [ ] Windows
- [ ] macOS
- [ ] Linux
## Test Configuration
Please paste the output of `wails doctor`. If you are unable to run this command, please describe your environment in as much detail as possible.
# Checklist:
- [ ] I have updated `website/src/pages/changelog.mdx` with details of this PR
- [ ] My code follows the general coding style of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
@@ -0,0 +1,37 @@
name: Format Markdown Files
on:
workflow_dispatch:
push:
branches: [master]
jobs:
format_markdown_files:
runs-on: ubuntu-latest
if: github.repository == 'wailsapp/wails'
steps:
- uses: actions/checkout@v3
- name: Setup Nodejs
uses: actions/setup-node@v2
with:
node-version: 18.x
- name: Install Task
uses: arduino/setup-task@v1
with:
version: 3.x
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Format All Markdown Files
run: task format-all-md
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: "docs: format document"
title: "docs: format document"
body: "- [x] Format all Markdown(x) documents"
branch: chore/format-markdown-files
delete-branch: true
draft: false
-15
View File
@@ -1,15 +0,0 @@
name: Label sponsors
on:
pull_request:
types: [ opened ]
issues:
types: [ opened ]
jobs:
build:
name: is-sponsor-label
if: github.repository == 'wailsapp/wails'
runs-on: ubuntu-latest
steps:
- uses: JasonEtco/is-sponsor-label-action@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -1,7 +1,9 @@
name: Sync Translated Documents
name: Sync Translations
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
sync-translated-documents:
@@ -10,22 +12,30 @@ jobs:
steps:
- uses: actions/checkout@v3
- name: Set node
- name: Setup Nodejs
uses: actions/setup-node@v2
with:
node-version: 16.x
node-version: 18.x
- name: Install Task
uses: arduino/setup-task@v1
with:
version: 3.x
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Sync Translated Documents
run: cd scripts && chmod 755 ./sync-translated-documents.sh && ./sync-translated-documents.sh
env:
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
working-directory: ./website
run: task crowdin:pull
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: "docs: sync documents"
title: "docs: sync documents"
commit-message: "docs: sync translations"
title: "docs: sync translations"
body: "- [x] Sync translated documents"
branch: feature/documents
branch: chore/sync-translations
labels: translation
delete-branch: true
draft: true
@@ -1,8 +1,9 @@
name: Push Checks
name: Upload Source Documents
on:
push:
branches: [master]
workflow_dispatch:
jobs:
push_files_to_crowdin:
@@ -13,25 +14,28 @@ jobs:
- uses: actions/checkout@v2
- name: Verify Changed files
uses: tj-actions/verify-changed-files@v11.1
id: verify-changed-files
id: changed-files
uses: tj-actions/changed-files@v35
with:
files: |
website/**/*.mdx
website/**/*.md
website/**/*.json
- name: Set node
if: steps.verify-changed-files.outputs.files_changed != 'true'
- name: Setup Nodejs
uses: actions/setup-node@v2
with:
node-version: 16.x
node-version: 18.x
- name: Push files
- name: Setup Task
uses: arduino/setup-task@v1
with:
version: 3.x
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Upload source documents
if: steps.changed-files.outputs.any_changed == 'true'
env:
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
run: |
cd website
corepack enable
pnpm install
pnpm run crowdin push -b master
working-directory: ./website
run: task crowdin:push
+1
View File
@@ -35,3 +35,4 @@ v2/cmd/wails/internal/commands/initialise/templates/testtemplates/
/v3/.task
/v3/examples/build/bin/testapp
/websitev3/site/
/v3/examples/plugins/bin/testapp
-34
View File
@@ -1,34 +0,0 @@
# This is an example goreleaser.yaml file with some sane defaults.
# Make sure to check the documentation at http://goreleaser.com
builds:
- env:
- CGO_ENABLED=0
goos:
- windows
- linux
- darwin
goarch:
- 386
- amd64
ignore:
- goos: darwin
goarch: 386
main: ./cmd/wails/main.go
archive:
replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'
-6
View File
@@ -1,6 +0,0 @@
jshint:
config_file: .jshintrc
eslint:
enabled: true
config_file: .eslintrc
ignore_file: .eslintignore
-3
View File
@@ -1,3 +0,0 @@
{
"esversion": 6
}
+3
View File
@@ -0,0 +1,3 @@
website
v2
v3
+6
View File
@@ -0,0 +1,6 @@
overrides:
- files:
- "**/*.md"
options:
printWidth: 80
proseWrap: always
+3 -2
View File
@@ -26,8 +26,8 @@
<a href="https://github.com/avelino/awesome-go" rel="nofollow">
<img src="https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg" alt="Awesome" />
</a>
<a href="https://app.slack.com/client/T029RQSE6/CJ4P9F7MZ">
<img alt="Slack" src="https://img.shields.io/badge/slack-gophers%2Fwails%20-blue?logo=slack"/>
<a href="https://discord.gg/BrRSWTaxVK">
<img alt="Discord" src="https://dcbadge.vercel.app/api/server/BrRSWTaxVK?style=flat"/>
</a>
<br/>
<a href="https://github.com/wailsapp/wails/actions/workflows/build-and-test.yml" rel="nofollow">
@@ -58,6 +58,7 @@
- [スポンサー](#スポンサー)
- [始め方](#始め方)
- [FAQ](#faq)
- [スター数の推移](#スター数の推移)
- [コントリビューター](#コントリビューター)
- [特記事項](#特記事項)
- [スペシャルサンクス](#スペシャルサンクス)
+3 -2
View File
@@ -26,8 +26,8 @@
<a href="https://github.com/avelino/awesome-go" rel="nofollow">
<img src="https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg" alt="Awesome" />
</a>
<a href="https://app.slack.com/client/T029RQSE6/CJ4P9F7MZ">
<img alt="Slack" src="https://img.shields.io/badge/slack-gophers%2Fwails%20-blue?logo=slack"/>
<a href="https://discord.gg/BrRSWTaxVK">
<img alt="Discord" src="https://dcbadge.vercel.app/api/server/BrRSWTaxVK?style=flat"/>
</a>
<br/>
<a href="https://github.com/wailsapp/wails/actions/workflows/build-and-test.yml" rel="nofollow">
@@ -57,6 +57,7 @@
- [시작하기](#시작하기)
- [스폰서](#스폰서)
- [FAQ](#faq)
- [Stargazers 성장 추세](#stargazers-성장-추세)
- [기여자](#기여자)
- [라이센스](#라이센스)
- [영감](#영감)
+4 -3
View File
@@ -24,8 +24,8 @@
<a href="https://github.com/avelino/awesome-go" rel="nofollow">
<img src="https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg" alt="Awesome" />
</a>
<a href="https://app.slack.com/client/T029RQSE6/CJ4P9F7MZ">
<img alt="Slack" src="https://img.shields.io/badge/slack-gophers%2Fwails%20-blue?logo=slack"/>
<a href="https://discord.gg/BrRSWTaxVK">
<img alt="Discord" src="https://dcbadge.vercel.app/api/server/BrRSWTaxVK?style=flat"/>
</a>
<br/>
<a href="https://github.com/wailsapp/wails/actions/workflows/build-and-test.yml" rel="nofollow">
@@ -55,6 +55,7 @@
- [Getting Started](#getting-started)
- [Sponsors](#sponsors)
- [FAQ](#faq)
- [Stargazers over time](#stargazers-over-time)
- [Contributors](#contributors)
- [License](#license)
- [Inspiration](#inspiration)
@@ -91,9 +92,9 @@ The installation instructions are on the [official website](https://wails.io/doc
## Sponsors
This project is supported by these kind people / companies:
<img src="website/static/img/sponsors.svg" style="width:100%;max-width:800px;"/>
<p align="center">
<img src="https://wails.io/img/sponsor/jetbrains-grayscale.webp" style="width: 100px"/>
</p>
+3 -2
View File
@@ -26,8 +26,8 @@
<a href="https://github.com/avelino/awesome-go" rel="nofollow">
<img src="https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg" alt="Awesome" />
</a>
<a href="https://app.slack.com/client/T029RQSE6/CJ4P9F7MZ">
<img alt="Slack" src="https://img.shields.io/badge/slack-gophers%2Fwails%20-blue?logo=slack"/>
<a href="https://discord.gg/BrRSWTaxVK">
<img alt="Discord" src="https://dcbadge.vercel.app/api/server/BrRSWTaxVK?style=flat"/>
</a>
<br/>
<a href="https://github.com/wailsapp/wails/actions/workflows/build-and-test.yml" rel="nofollow">
@@ -57,6 +57,7 @@
- [快速入门](#快速入门)
- [赞助商](#赞助商)
- [常见问题](#常见问题)
- [星星增长趋势](#星星增长趋势)
- [贡献者](#贡献者)
- [许可证](#许可证)
- [灵感](#灵感)
+32 -9
View File
@@ -1,24 +1,47 @@
# https://taskfile.dev
version: '3'
version: "3"
vars:
GREETING: Hello, World!
includes:
website:
taskfile: website
dir: website
v2:
taskfile: v2
dir: v2
optional: true
v3:
taskfile: v3
dir: v3
optional: true
tasks:
check-contributors:
contributors:check:
cmds:
- npx -y all-contributors-cli check
update-contributors:
contributors:update:
cmds:
- go run v3/tasks/contribs/main.go
build-contributors:
contributors:build:
cmds:
- npx -y all-contributors-cli generate
release:
dir: v2/tools/release
format:md:
cmds:
- go run release.go
- npx prettier --write "**/*.md"
format:
cmds:
- task: format:md
format-all-md:
cmds:
- task: format:md
- task: website:format:md
- task: v2:format:md
# - task: v2:website:format
- task: v3:format:md
# - task: v3:website:format:md
-174
View File
@@ -1,174 +0,0 @@
package wails
import (
"os"
"syscall"
"github.com/syossan27/tebata"
"github.com/wailsapp/wails/cmd"
"github.com/wailsapp/wails/lib/binding"
"github.com/wailsapp/wails/lib/event"
"github.com/wailsapp/wails/lib/interfaces"
"github.com/wailsapp/wails/lib/ipc"
"github.com/wailsapp/wails/lib/logger"
"github.com/wailsapp/wails/lib/renderer"
wailsruntime "github.com/wailsapp/wails/runtime"
)
// -------------------------------- Compile time Flags ------------------------------
// BuildMode indicates what mode we are in
var BuildMode = cmd.BuildModeProd
// Runtime is the Go Runtime struct
type Runtime = wailsruntime.Runtime
// Store is a state store used for syncing with
// the front end
type Store = wailsruntime.Store
// CustomLogger is a specialised logger
type CustomLogger = logger.CustomLogger
// ----------------------------------------------------------------------------------
// App defines the main application struct
type App struct {
config *AppConfig // The Application configuration object
cli *cmd.Cli // In debug mode, we have a cli
renderer interfaces.Renderer // The renderer is what we will render the app to
logLevel string // The log level of the app
ipc interfaces.IPCManager // Handles the IPC calls
log *logger.CustomLogger // Logger
bindingManager interfaces.BindingManager // Handles binding of Go code to renderer
eventManager interfaces.EventManager // Handles all the events
runtime interfaces.Runtime // The runtime object for registered structs
}
// CreateApp creates the application window with the given configuration
// If none given, the defaults are used
func CreateApp(optionalConfig ...*AppConfig) *App {
var userConfig *AppConfig
if len(optionalConfig) > 0 {
userConfig = optionalConfig[0]
}
result := &App{
logLevel: "debug",
renderer: renderer.NewWebView(),
ipc: ipc.NewManager(),
bindingManager: binding.NewManager(),
eventManager: event.NewManager(),
log: logger.NewCustomLogger("App"),
}
appconfig, err := newConfig(userConfig)
if err != nil {
result.log.Fatalf("Cannot use custom HTML: %s", err.Error())
}
result.config = appconfig
// Set up the CLI if not in release mode
if BuildMode != cmd.BuildModeProd {
result.cli = result.setupCli()
} else {
// Disable Inspector in release mode
result.config.DisableInspector = true
}
// Platform specific init
platformInit()
return result
}
// Run the app
func (a *App) Run() error {
if BuildMode != cmd.BuildModeProd {
return a.cli.Run()
}
a.logLevel = "error"
err := a.start()
if err != nil {
a.log.Error(err.Error())
}
return err
}
func (a *App) start() error {
// Set the log level
logger.SetLogLevel(a.logLevel)
// Log starup
a.log.Info("Starting")
// Check if we are to run in bridge mode
if BuildMode == cmd.BuildModeBridge {
a.renderer = renderer.NewBridge()
}
// Initialise the renderer
err := a.renderer.Initialise(a.config, a.ipc, a.eventManager)
if err != nil {
return err
}
// Start signal handler
t := tebata.New(os.Interrupt, os.Kill, syscall.SIGTERM, syscall.SIGINT, syscall.SIGKILL)
t.Reserve(func() {
a.log.Debug("SIGNAL CAUGHT! Starting Shutdown")
a.renderer.Close()
})
// Start event manager and give it our renderer
a.eventManager.Start(a.renderer)
// Start the IPC Manager and give it the event manager and binding manager
a.ipc.Start(a.eventManager, a.bindingManager)
// Create the runtime
a.runtime = wailsruntime.NewRuntime(a.eventManager, a.renderer)
// Start binding manager and give it our renderer
err = a.bindingManager.Start(a.renderer, a.runtime)
if err != nil {
return err
}
// Defer the shutdown
defer a.shutdown()
// Run the renderer
err = a.renderer.Run()
if err != nil {
return err
}
return nil
}
// shutdown the app
func (a *App) shutdown() {
// Make sure this is only called once
a.log.Debug("Shutting down")
// Shutdown Binding Manager
a.bindingManager.Shutdown()
// Shutdown IPC Manager
a.ipc.Shutdown()
// Shutdown Event Manager
a.eventManager.Shutdown()
a.log.Debug("Cleanly Shutdown")
}
// Bind allows the user to bind the given object
// with the application
func (a *App) Bind(object interface{}) {
a.bindingManager.Bind(object)
}

Some files were not shown because too many files have changed in this diff Show More