mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Flatten and simplify Servo's preferences code. In addition, have both preferences and options passed in as arguments to `Servo::new()` and make sure not to use the globally set preferences in `servoshell` (as much as possible now). Instead of a complex procedural macro to generate preferences, just expose a very simple derive macro that adds string based getters and setters. - All command-line parsing is moved to servoshell. - There is no longer the concept of a missing preference. - Preferences no longer have to be part of the resources bundle because they now have reasonable default values. - servoshell specific preferences are no longer part of the preferences exposed by the Servo API. Signed-off-by: Martin Robinson <mrobinson@igalia.com> |
||
---|---|---|
.. | ||
adapter.rs | ||
bluetooth.rs | ||
Cargo.toml | ||
empty.rs | ||
lib.rs | ||
macros.rs | ||
README.md | ||
test.rs |
Bluetooth Rust lib using macOS CoreBluetooth
The main aim of BlurMac is to enable WebBluetooth in Servo on macOS. Thus, API and implementation decisions are affected by the encapsulating Devices, and the sibling BlurZ and BlurDroid crates.
Run Servo with WebBluetooth Enabled
Usually, you don't want to work with BlurMac on its own but use it within Servo. So, most probably you'll want to run Servo with WebBluetooth enabled:
RUST_LOG=blurmac \
./mach run \
--dev \
--pref=dom.bluetooth.enabled \
--pref=dom.permissions.testing.allowed_in_nonsecure_contexts \
URL
Notes:
- The above command is actually not really BlurMac-specific (except for the
RUST_LOG
part). It runs Servo with WBT enabled on any platform where WBT is supported. - You don't need the
RUST_LOG=blurmac
part if you don't want to see BlurMac debug messages on the console. - You don't need the
--dev
part if you want to run a release build. - You don't need the
--pref=dom.permissions.testing.allowed_in_nonsecure_contexts
part if yourURL
is https (but you do need it if you test a local file).
Known Issues
- Device RSSI can not be retrieved yet.
- Support for included services is incomplete.
- Descriptors are not supported yet.
- Notifications on characteristics are not supported yet (the limitation comes from Devices).
Compatibility
Tested on:
- macOS Sierra 10.12.
Copyright and Licensing
Licensed under the BSD 3-Clause License.