Skip to content

Commit

Permalink
Fix a few API doc issues
Browse files Browse the repository at this point in the history
  • Loading branch information
swsnr committed Jan 10, 2025
1 parent cb3e4f5 commit c53544a
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/app/searchprovider.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ async fn dispatch_method_call(

/// Register the Turn On search provider for `app`.
///
/// Register a search provider for devices on the DBus connection of `app`.
/// Register a search provider for devices on the D-Bus connection of `app`.
/// The search provider exposes devices from the `app` model to GNOME Shell,
/// and allows to turn on devices directly from the shell overview.
pub fn register_app_search_provider(app: &TurnOnApplication) -> Option<RegistrationId> {
Expand Down
2 changes: 1 addition & 1 deletion src/dbus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

//! DBus interface definitions and helpers.
//! D-Bus interface definitions and helpers.
pub mod searchprovider2;
2 changes: 1 addition & 1 deletion src/dbus/searchprovider2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ static XML: &str = include_str!("../../dbus-1/org.gnome.ShellSearchProvider2.xml
/// The name of the interface.
pub static INTERFACE_NAME: &str = "org.gnome.Shell.SearchProvider2";

/// Get the DBus interface info for the search provider interface.
/// Get the D-Bus interface info for the search provider interface.
pub fn interface() -> DBusInterfaceInfo {
// We unwrap here since we know that the XML is valid and contains the
// desired interface, so none of this can realistically fail.
Expand Down
6 changes: 3 additions & 3 deletions src/net.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.

//! Networking for TurnOn.
//! Networking for Turn On.
//!
//! This module provides various utilities around networking required by TurnOn.
//! Specifically, it has a user-space ping implementation, a WakeOnLan
//! This module provides various utilities around networking required by Turn On.
//! Specifically, it has a user-space ping implementation, a Wake-On-Lan
//! implementation, some helper types, and various tools for network scanning.
pub mod arpcache;
Expand Down
2 changes: 1 addition & 1 deletion src/net/arpcache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use macaddr::MacAddr6;
/// for known hardware types as of Linux 6.12.
///
/// We do not represent all hardware types, but only those we're interested in
/// with regards to TurnOn.
/// with regards to Turn On.
#[derive(Debug, PartialEq, Eq)]
#[repr(u16)]
pub enum ArpKnownHardwareType {
Expand Down
4 changes: 2 additions & 2 deletions src/net/macaddr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//! Simple MAC address type on top of [`glib::Bytes`].
//!
//! While this is not the most efficient approach it allows storing the MAC
//! address as a GLib property.
//! address as a glib property.
use std::fmt::Display;
use std::ops::Deref;
Expand All @@ -17,7 +17,7 @@ use macaddr::MacAddr6;

/// Boxed [`MacAddr6`].
///
/// Define a MAC address type for GLib, by boxing a [`MacAdd6`].
/// Define a MAC address type for glib, by boxing a [`MacAdd6`].
#[derive(Default, Debug, Copy, Clone, Eq, PartialEq, PartialOrd, Ord, glib::Boxed)]
#[boxed_type(name = "MacAdd6")]
pub struct MacAddr6Boxed(MacAddr6);
Expand Down
2 changes: 1 addition & 1 deletion src/net/wol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ fn write_magic_packet<W: Write>(sink: &mut W, mac_address: MacAddr6) -> std::io:

/// Send a magic Wake On LAN packet to the given `mac_address`.
///
/// Sends the WoL package as UDP package to port 9 on the IPv4 broadcast address.
/// Sends the magic package as UDP package to port 9 on the IPv4 broadcast address.
pub async fn wol(mac_address: MacAddr6) -> Result<(), glib::Error> {
let socket = gio::Socket::new(
gio::SocketFamily::Ipv4,
Expand Down

0 comments on commit c53544a

Please sign in to comment.