Skip to content

Commit 9c6ca93

Browse files
committed
chore(rust): upgrade to windows-rs@0.60.0
1 parent 660b1e2 commit 9c6ca93

File tree

9 files changed

+65
-95
lines changed

9 files changed

+65
-95
lines changed

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,13 @@ This is a porting project for Microsoft Chinese (Simplified, China) IME sample f
44

55
## Build
66

7-
* You need to be on 64bit Windows. (Solely because I don't want to complicate the Visual Studio configuration and the build script)
8-
* Install the latest [Visual Studio](https://visualstudio.microsoft.com/downloads/), [Rust](https://www.rust-lang.org/), and [PowerShell](https://www.microsoft.com/store/productId/9MZ1SNWT0N5D).
9-
* Install cbindgen by `cargo install cbindgen`.
10-
* Copy-paste `cpp/SampleIME/Dictionary/SampleIMESimplifiedQuanPinUtf8.txt` into `cpp/x64/Debug`.
11-
* Run and choose the x64/Debug configuration, as any other configurations are not supported.
7+
0. Only x86-64 and arm64 targets are supported and being tested.
8+
1. Install the latest [Build Tools for Visual Studio](https://visualstudio.microsoft.com/downloads/), [Rust](https://www.rust-lang.org/), and [PowerShell](https://www.microsoft.com/store/productId/9MZ1SNWT0N5D).
9+
* Alternatively the full Visual Studio also works.
10+
1. Install cbindgen by `cargo install cbindgen`.
11+
1. Copy-paste `cpp/SampleIME/Dictionary/SampleIMESimplifiedQuanPinUtf8.txt` into `cpp/arm64/Debug` (or `cpp/x64/Debug`).
12+
1. Run Developer Command Prompt which is installed together with Build Tools.
13+
1. Run `msbuild cpp/SampleIME.sln -target:SampleIME /property:Platform=arm64` or (`Platform=x64` for x86-64).
1214

1315
## Deploy
1416

rust/Cargo.lock

Lines changed: 49 additions & 81 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rust/composition_processor/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ globals = { path = "../globals" }
1919
itf_components = { path = "../itf_components" }
2020

2121
[dependencies.windows]
22-
version = "0.59.0"
22+
version = "0.60.0"
2323
features = [
2424
"Win32_Foundation",
2525
"Win32_System_LibraryLoader",

rust/globals/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ name = "globals"
1111
crate-type = ["rlib", "staticlib"]
1212

1313
[dependencies]
14-
windows = "0.59.0"
14+
windows = "0.60.0"

rust/ime/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ globals = { path = "../globals" }
1414
winreg = "0.55.0"
1515

1616
[dependencies.windows]
17-
version = "0.59.0"
17+
version = "0.60.0"
1818
features = [
1919
"Win32_Graphics_Gdi",
2020
"Win32_System_Com",

rust/input_processor/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ globals = { path = "../globals" }
1515
itf_components = { path = "../itf_components" }
1616

1717
[dependencies.windows]
18-
version = "0.59.0"
18+
version = "0.60.0"
1919
features = [
2020
"Win32_UI_TextServices",
2121
]

rust/itf_components/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ crate-type = ["rlib", "staticlib"]
1313
ime = { path = "../ime" }
1414
globals = { path = "../globals" }
1515
ruststringrange = { path = "../ruststringrange" }
16-
windows-core = "0.59.0"
16+
windows-core = "0.60.1"
1717

1818
[dependencies.windows]
19-
version = "0.59.0"
19+
version = "0.60.0"
2020
features = [
2121
"Win32_Foundation",
2222
"Win32_UI_TextServices",

rust/itf_components/src/language_bar.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ use std::ffi::c_void;
77

88
use globals::SAMPLEIME_CLSID;
99
use ruststringrange::RustStringRange;
10-
use windows::core::{implement, AsImpl, IUnknown, Interface, Ref, BSTR, GUID, HRESULT};
11-
use windows::Win32::Foundation::{BOOL, E_FAIL, E_INVALIDARG, POINT, RECT};
10+
use windows::core::{implement, AsImpl, IUnknown, Interface, Ref, BOOL, BSTR, GUID, HRESULT};
11+
use windows::Win32::Foundation::{E_FAIL, E_INVALIDARG, POINT, RECT};
1212
use windows::Win32::System::Com::{CoCreateInstance, CLSCTX_INPROC_SERVER};
1313
use windows::Win32::System::Ole::{
1414
CONNECT_E_ADVISELIMIT, CONNECT_E_CANNOTCONNECT, CONNECT_E_NOCONNECTION,

rust/numberkey_windows/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ crate-type = ["rlib", "staticlib"]
1212

1313
[dependencies]
1414
[dependencies.windows]
15-
version = "0.59.0"
15+
version = "0.60.0"
1616
features = [
1717
"Win32_UI_Input_KeyboardAndMouse",
1818
]

0 commit comments

Comments
 (0)