Repository navigation
Commit 8dee501
committed
refactor(tsf): share the profile-GUID match as a header-only helper
`ImeModule::loadImeInfo` compared the flat `guid` and then walked
`additionalProfiles` inline, so this one of the four dispatchers had no way to
be exercised outside the `build-and-sign` job: the vendored mingw carries no
Windows SDK headers. Extracting the match into `PIMETextService/ImeProfileGuids.h`,
which includes only `<string>` and the header-only nlohmann json, keeps the
behaviour and lets the two pure-C++ helper tests upstream already runs gain a
third sibling case.
- `imeProfileGuidEqual`: ASCII case-insensitive, the same comparison `stricmp`
gave, so a lowercased client id still meets an upper-case manifest.
- `imeProfileGuidMatches`: the flat `guid` first, then each `additionalProfiles`
entry; a non-object entry, a missing or non-string `guid`, and an empty
`guid` are skipped without throwing.
- `loadImeInfo` calls it: the 17 inline lines become one call (22 lines
changed, 15 fewer), and the first-match `break` of the backend scan is
unchanged, so `onConfigure` resolves `ime.json` from either profile GUID.
Architecture and design by asdf80730. Implementation generated with AI assistance from omp (tensorfold/Qwen3.8-Flash-Next).1 parent 564e3e2 commit 8dee501
2 files changed
Lines changed: 84 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
| |||
119 | 120 | | |
120 | 121 | | |
121 | 122 | | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
139 | 127 | | |
140 | 128 | | |
141 | 129 | | |
| |||
0 commit comments