Skip to content

Commit 06bbf8f

Browse files
authored
Merge pull request #229 from Choochmeque/windows-push
Windows toast activation support
2 parents 3e059e6 + 8696677 commit 06bbf8f

15 files changed

Lines changed: 850 additions & 11 deletions

Cargo.toml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,17 @@ windows = { version = "0.61", features = [
5555
"Foundation",
5656
"Networking_PushNotifications",
5757
"UI_Notifications",
58+
"Win32_Foundation",
59+
"Win32_System_Com",
60+
"Win32_UI_Notifications",
5861
] }
62+
# The `#[implement]` macro from `windows::core::implement` emits `::windows_core::*`
63+
# absolute paths, so `windows-core` must be a direct dependency, not just
64+
# transitive through `windows`.
65+
windows-core = "0.61"
66+
# Used to parse user-supplied CLSID strings (accepts braced, unbraced, and
67+
# hyphen-less forms) before converting to `windows::core::GUID` via raw bits.
68+
uuid = { version = "1", default-features = false }
5969
nt-time = "0.15"
6070

6171
[build-dependencies]

examples/notifications-demo/package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
"preview": "vite preview",
1010
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
1111
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
12-
"tauri": "tauri"
12+
"tauri": "tauri",
13+
"tauri:windows:build": "tauri-windows-bundle build"
1314
},
1415
"license": "MIT",
1516
"dependencies": {
@@ -25,6 +26,7 @@
2526
"svelte": "^5.56.1",
2627
"svelte-check": "^4.4.4",
2728
"typescript": "~6.0.3",
28-
"vite": "^8.0.13"
29+
"vite": "^8.0.13",
30+
"@choochmeque/tauri-windows-bundle": "^0.1.20"
2931
}
3032
}

examples/notifications-demo/pnpm-lock.yaml

Lines changed: 473 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Generated files
2+
# Keep bundle.config.json and templates in git
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Package
3+
xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10"
4+
xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10"
5+
xmlns:uap3="http://schemas.microsoft.com/appx/manifest/uap/windows10/3"
6+
xmlns:desktop="http://schemas.microsoft.com/appx/manifest/desktop/windows10"
7+
xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities">
8+
9+
<Identity
10+
Name="{{PACKAGE_NAME}}"
11+
Publisher="{{PUBLISHER}}"
12+
Version="{{VERSION}}"
13+
ProcessorArchitecture="{{ARCH}}" />
14+
15+
<Properties>
16+
<DisplayName>{{DISPLAY_NAME}}</DisplayName>
17+
<PublisherDisplayName>{{PUBLISHER_DISPLAY_NAME}}</PublisherDisplayName>
18+
<Logo>Assets\StoreLogo.png</Logo>
19+
</Properties>
20+
21+
<Dependencies>
22+
<TargetDeviceFamily Name="Windows.Desktop"
23+
MinVersion="{{MIN_VERSION}}"
24+
MaxVersionTested="10.0.22621.0" />
25+
</Dependencies>
26+
27+
<Resources>
28+
<Resource Language="en-us" />
29+
</Resources>
30+
31+
<Applications>
32+
<Application Id="App"
33+
Executable="{{EXECUTABLE}}"
34+
EntryPoint="Windows.FullTrustApplication">
35+
<uap:VisualElements
36+
DisplayName="{{DISPLAY_NAME}}"
37+
Description="{{DESCRIPTION}}"
38+
BackgroundColor="transparent"
39+
Square150x150Logo="Assets\Square150x150Logo.png"
40+
Square44x44Logo="Assets\Square44x44Logo.png">
41+
<uap:DefaultTile Wide310x150Logo="Assets\Wide310x150Logo.png" />
42+
</uap:VisualElements>
43+
44+
{{EXTENSIONS}}
45+
</Application>
46+
</Applications>
47+
48+
<Capabilities>
49+
{{CAPABILITIES}}
50+
</Capabilities>
51+
</Package>
8.39 KB
Loading
3.87 KB
Loading
1.27 KB
Loading
1.49 KB
Loading
554 Bytes
Loading

0 commit comments

Comments
 (0)