commit | 1a3fba396d0fc53b1575502bfb6fbdaa89ab1fa5 | [log] [tgz] |
---|---|---|
author | Prashant Malani <pmalani@chromium.org> | Wed Nov 23 01:10:32 2022 +0000 |
committer | Copybara-Service <copybara-worker@google.com> | Mon Nov 28 18:19:13 2022 -0800 |
tree | 3efe31c096e5c33f00ba0e9a6daad9daf5e820f3 | |
parent | 48281573dd5b83ed380affe6be11716f2be36e89 [diff] |
typecd: Add Data Access setting D-Bus method Add a D-Bus method to update the Peripheral Data Access setting. This will be used by the Chrome browser to let typecd know when the setting has changed. The setting currently has no bearing on actual policy. That will change once the Chrome browser is updated to call the D-Bus method. BUG=b:260017469 TEST=- Unit tests all still pass. - Verified that the method gets called, when invoked from the commandline using dbus-send. Change-Id: I35076e424ff678879ca415726f60e94522d974e8 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/4052762 Commit-Queue: Prashant Malani <pmalani@chromium.org> Reviewed-by: Jameson Thies <jthies@google.com> Tested-by: Prashant Malani <pmalani@chromium.org> NOKEYCHECK=True GitOrigin-RevId: 814113743a9b63c5a21af3df0a37479725415875
This directory (platform2/system_api
) contains constants and definitions like D-Bus service names that are shared between Chromium and Chromium OS.
This directory is only for things like headers and .proto files. No implementation should be added.
When writting a .proto file make sure to use:
option optimize_for = LITE_RUNTIME;
This will force usage of a lite protobuf instead of a full/heavy weight protobuf. The browser only links against the light version, so you will get cryptic link errors about missing parts of Message if you define a protobuf here and then try to use it in Chrome. Currently CrOS links against the full protobuffer library, but that might change in the future.
When declaring a protobuf, avoid use of required unless it is exactly what you mean. "Required is Forever" and very rarely should actually be used. Consult Protocol Buffer Basics: C++ for a detailed of this issue.