Commit 3299db4
committed
feat(client): gate native backends behind Cargo features and add ConfigBuilder
Cargo features
* `default = []`; consumers now opt into exactly what they need.
* New matrix: `sound`, `clipboard`, `rdpdr`, `smartcard`, `gateway`,
`qoi`, `qoiz`, `dvc-pipe-proxy`, `dvc-com-plugin`, plus the
existing `rustls` / `native-tls` selection.
* `ironrdp-rdpsnd-native`, `ironrdp-cliprdr-native`, `ironrdp-mstsgu`,
`reqwest`, `ironrdp-dvc-pipe-proxy`, and `ironrdp-dvc-com-plugin`
become optional and are only pulled in by the matching feature.
* Native backend instantiation (cpal RDPSND, native clipboard,
NoopRdpdrBackend, Windows COM DVC plugin, gateway/WS transport)
moves into the library behind those `cfg`s, with
`with_<feature>_backend(custom)` escape hatches.
Public API
* Introduce `Config` + `ConfigBuilder` with typed fields and
per-feature runtime toggles (`with_sound(bool)`,
`with_clipboard(bool)`, ...). Setters always compile and are
documented no-ops when the matching Cargo feature is disabled,
so generic embedders don't need to sprinkle `cfg!`.
* Drop `PartialConfig` from the library's public surface; `.rdp` /
`PropertySet` / clap / inquire parsing now lives entirely in the
viewer and produces a `Config` directly.1 parent d5b3fa7 commit 3299db4
8 files changed
Lines changed: 1176 additions & 723 deletions
File tree
- crates
- ironrdp-client
- src
- ironrdp-viewer
- src
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
23 | | - | |
24 | | - | |
| 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 | + | |
25 | 51 | | |
26 | 52 | | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
27 | 57 | | |
28 | 58 | | |
29 | 59 | | |
| |||
33 | 63 | | |
34 | 64 | | |
35 | 65 | | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | 66 | | |
40 | 67 | | |
41 | 68 | | |
42 | 69 | | |
43 | 70 | | |
44 | | - | |
45 | 71 | | |
46 | | - | |
47 | | - | |
| 72 | + | |
48 | 73 | | |
49 | | - | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
50 | 86 | | |
51 | 87 | | |
52 | 88 | | |
| |||
62 | 98 | | |
63 | 99 | | |
64 | 100 | | |
| 101 | + | |
65 | 102 | | |
66 | 103 | | |
67 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
68 | 108 | | |
69 | 109 | | |
70 | 110 | | |
| |||
0 commit comments