objc2_watch_kit/generated/
WKInterfaceSlider.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-ui-kit")]
7use objc2_ui_kit::*;
8
9use crate::*;
10
11extern_class!(
12 #[unsafe(super(WKInterfaceObject, NSObject))]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 #[cfg(feature = "WKInterfaceObject")]
16 pub struct WKInterfaceSlider;
17);
18
19#[cfg(feature = "WKInterfaceObject")]
20extern_conformance!(
21 unsafe impl NSObjectProtocol for WKInterfaceSlider {}
22);
23
24#[cfg(feature = "WKInterfaceObject")]
25impl WKInterfaceSlider {
26 extern_methods!(
27 #[unsafe(method(setEnabled:))]
28 #[unsafe(method_family = none)]
29 pub unsafe fn setEnabled(&self, enabled: bool);
30
31 #[unsafe(method(setValue:))]
32 #[unsafe(method_family = none)]
33 pub unsafe fn setValue(&self, value: c_float);
34
35 #[cfg(feature = "objc2-ui-kit")]
36 #[unsafe(method(setColor:))]
37 #[unsafe(method_family = none)]
38 pub unsafe fn setColor(&self, color: Option<&UIColor>);
39
40 #[unsafe(method(setNumberOfSteps:))]
41 #[unsafe(method_family = none)]
42 pub unsafe fn setNumberOfSteps(&self, number_of_steps: NSInteger);
43 );
44}
45
46#[cfg(feature = "WKInterfaceObject")]
48impl WKInterfaceSlider {
49 extern_methods!(
50 #[unsafe(method(init))]
51 #[unsafe(method_family = init)]
52 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
53 );
54}
55
56#[cfg(feature = "WKInterfaceObject")]
58impl WKInterfaceSlider {
59 extern_methods!(
60 #[unsafe(method(new))]
61 #[unsafe(method_family = new)]
62 pub unsafe fn new() -> Retained<Self>;
63 );
64}