pub struct ButtonControl {
pub control_number: u8,
pub display: String,
pub tooltip: Option<String>,
}
Expand description
Button that sends a signal when pressed. The button is only enabled when capturing.
The extcap utility can set the button text at startup using the display
field, change the button text using
set_label
, and receive button press signals
from an ExtcapControlReader
.
The button is disabled and the button text is restored to the default text when not capturing.
Fields§
§control_number: u8
The control number, a unique identifier for this control.
display: String
The user-visible label for the button.
tooltip: Option<String>
Tooltip shown when hovering over the UI element.
Implementations§
Source§impl ButtonControl
impl ButtonControl
Trait Implementations§
Source§impl ControlWithLabel for ButtonControl
impl ControlWithLabel for ButtonControl
Source§impl Debug for ButtonControl
impl Debug for ButtonControl
Source§impl EnableableControl for ButtonControl
impl EnableableControl for ButtonControl
Source§fn set_enabled(&self, enabled: bool) -> ControlPacket<'static>
fn set_enabled(&self, enabled: bool) -> ControlPacket<'static>
Sets whether the control is enabled or disabled. Read more
Source§impl PrintSentence for ButtonControl
impl PrintSentence for ButtonControl
Source§fn format_sentence(&self, f: &mut Formatter<'_>) -> Result
fn format_sentence(&self, f: &mut Formatter<'_>) -> Result
The extcap interface expects certain output “sentences” to stdout to
communicate with Wireshark, like Read more
Source§fn print_sentence(&self)
fn print_sentence(&self)
Prints the extcap sentence to stdout.
Source§impl ToolbarControl for ButtonControl
impl ToolbarControl for ButtonControl
Source§fn control_number(&self) -> u8
fn control_number(&self) -> u8
The control number, a unique identifier for this control.
Auto Trait Implementations§
impl Freeze for ButtonControl
impl RefUnwindSafe for ButtonControl
impl Send for ButtonControl
impl Sync for ButtonControl
impl Unpin for ButtonControl
impl UnwindSafe for ButtonControl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more