Compare commits

..

3 Commits

Author SHA1 Message Date
leaanthony 4c05c0bd30 chore: update contributors.svg 2023-04-02 22:55:17 +00:00
Lea Anthony b38ad7c7f1 Add initial svg 2023-04-03 08:54:45 +10:00
Lea Anthony acfca594f2 Debug contrib image 2023-04-03 08:53:11 +10:00
38 changed files with 640 additions and 414 deletions
+3 -2
View File
@@ -5,7 +5,7 @@ on:
- cron: '0 1 * * 0' # At 01:00 on Sunday.
push:
branches:
- master
- 'v2/update-contrib-svg'
jobs:
contributors:
@@ -13,10 +13,11 @@ jobs:
if: github.repository == 'wailsapp/wails'
steps:
- uses: actions/checkout@v3
- uses: wow-actions/contributors-list@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
svgPath: website/static/img/contributors.svg
svgPath: ./website/static/img/contributors.svg
noCommit: true
- name: Create Pull Request
-1
View File
@@ -35,4 +35,3 @@ v2/cmd/wails/internal/commands/initialise/templates/testtemplates/
/v3/.task
/v3/examples/build/bin/testapp
/websitev3/site/
/v3/examples/plugins/bin/testapp
Binary file not shown.

Before

Width:  |  Height:  |  Size: 130 KiB

After

Width:  |  Height:  |  Size: 0 B

-1
View File
@@ -14,7 +14,6 @@ require (
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421 // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
github.com/samber/lo v1.37.0 // indirect
github.com/wailsapp/mimetype v1.4.1 // indirect
-2
View File
@@ -24,8 +24,6 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2 h1:acNfDZXmm28D2Yg/c3ALnZStzNaZMSagpbr96vY6Zjc=
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2/go.mod h1:HKlIX3XHQyzLZPlr7++PzdhaXEj94dEiJgZDTsxEqUI=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.
+1 -5
View File
@@ -8,7 +8,6 @@ import (
"github.com/wailsapp/wails/v3/plugins/log"
"github.com/wailsapp/wails/v3/plugins/single_instance"
"github.com/wailsapp/wails/v3/plugins/sqlite"
"github.com/wailsapp/wails/v3/plugins/start_at_login"
"os"
"plugin_demo/plugins/hashes"
)
@@ -28,9 +27,7 @@ func main() {
"hashes": hashes.NewPlugin(),
"browser": browser.NewPlugin(),
"log": log.NewPlugin(),
"sqlite": sqlite.NewPlugin(&sqlite.Config{
DBFile: "test.db",
}),
"sqlite": sqlite.NewPlugin(&sqlite.Config{}),
"kvstore": kvstore.NewPlugin(&kvstore.Config{
Filename: "store.json",
AutoSave: true,
@@ -39,7 +36,6 @@ func main() {
// When true, the original app will be activated when a second instance is launched
ActivateAppOnSubsequentLaunch: true,
}),
"start_at_login": start_at_login.NewPlugin(),
},
Assets: application.AssetOptions{
FS: assets,
+2 -6
View File
@@ -33,11 +33,8 @@ func main() {
windowCounter := 1
newWindow := func() {
windowName := "WebviewWindow " + strconv.Itoa(windowCounter)
app.NewWebviewWindowWithOptions(&application.WebviewWindowOptions{
Name: windowName,
}).
SetTitle(windowName).
app.NewWebviewWindowWithOptions(&application.WebviewWindowOptions{}).
SetTitle("WebviewWindow "+strconv.Itoa(windowCounter)).
SetPosition(rand.Intn(1000), rand.Intn(800)).
Show()
windowCounter++
@@ -53,7 +50,6 @@ func main() {
})
newWindow()
newWindow()
app.SetMenu(menu)
err := app.Run()
-1
View File
@@ -12,7 +12,6 @@ require (
github.com/leaanthony/winicon v1.0.0
github.com/matryer/is v1.4.0
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2
github.com/pkg/errors v0.9.1
github.com/pterm/pterm v0.12.51
github.com/samber/lo v1.37.0
github.com/tc-hib/winres v0.1.6
-2
View File
@@ -96,8 +96,6 @@ github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLA
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2 h1:acNfDZXmm28D2Yg/c3ALnZStzNaZMSagpbr96vY6Zjc=
github.com/pkg/browser v0.0.0-20210706143420-7d21f8c997e2/go.mod h1:HKlIX3XHQyzLZPlr7++PzdhaXEj94dEiJgZDTsxEqUI=
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+4 -7
View File
@@ -22,7 +22,7 @@ import {enableContextMenus} from "./contextmenu";
import {reloadWML} from "./wml";
window.wails = {
...newRuntime(null),
...newRuntime(-1),
};
// Internal wails endpoints
@@ -34,16 +34,13 @@ window._wails = {
callErrorCallback,
};
export function newRuntime(windowName) {
export function newRuntime(id) {
return {
Clipboard: {
...Clipboard
},
Application: {
...Application,
GetWindowByName(windowName) {
return newRuntime(windowName);
}
...Application
},
Log,
Screens,
@@ -68,7 +65,7 @@ export function newRuntime(windowName) {
Off,
OffAll,
},
Window: newWindow(windowName),
Window: newWindow(id),
};
}
+13 -12
View File
@@ -12,20 +12,14 @@ The electron alternative for Go
const runtimeURL = window.location.origin + "/wails/runtime";
function runtimeCall(method, windowName, args) {
function runtimeCall(method, args) {
let url = new URL(runtimeURL);
url.searchParams.append("method", method);
if (args) {
if(args) {
url.searchParams.append("args", JSON.stringify(args));
}
let fetchOptions = {
headers: {},
};
if (windowName) {
fetchOptions.headers["x-wails-window-name"] = windowName;
}
return new Promise((resolve, reject) => {
fetch(url, fetchOptions)
fetch(url)
.then(response => {
if (response.ok) {
// check content type
@@ -42,8 +36,15 @@ function runtimeCall(method, windowName, args) {
});
}
export function newRuntimeCaller(object, windowName) {
return function (method, args=null) {
return runtimeCall(object + "." + method, windowName, args);
export function newRuntimeCaller(object, id) {
if (!id || id === -1) {
return function (method, args) {
return runtimeCall(object + "." + method, args);
};
}
return function (method, args) {
args = args || {};
args.windowID = id;
return runtimeCall(object + "." + method, args);
};
}
+2 -2
View File
@@ -18,8 +18,8 @@ The electron alternative for Go
import {newRuntimeCaller} from "./runtime";
export function newWindow(windowName) {
let call = newRuntimeCaller("window", windowName);
export function newWindow(id) {
let call = newRuntimeCaller("window", id);
return {
// Reload: () => call('WR'),
// ReloadApp: () => call('WR'),
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long

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