objc2_ui_kit/generated/
UITrackingLayoutGuide.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(UILayoutGuide, NSObject))]
13 #[thread_kind = MainThreadOnly]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 #[cfg(feature = "UILayoutGuide")]
16 pub struct UITrackingLayoutGuide;
17);
18
19#[cfg(feature = "UILayoutGuide")]
20extern_conformance!(
21 unsafe impl NSCoding for UITrackingLayoutGuide {}
22);
23
24#[cfg(feature = "UILayoutGuide")]
25extern_conformance!(
26 unsafe impl NSObjectProtocol for UITrackingLayoutGuide {}
27);
28
29#[cfg(feature = "UILayoutGuide")]
30impl UITrackingLayoutGuide {
31 extern_methods!(
32 #[cfg(all(feature = "NSLayoutConstraint", feature = "UIGeometry"))]
33 #[unsafe(method(setConstraints:activeWhenNearEdge:))]
37 #[unsafe(method_family = none)]
38 pub unsafe fn setConstraints_activeWhenNearEdge(
39 &self,
40 tracking_constraints: &NSArray<NSLayoutConstraint>,
41 edge: NSDirectionalRectEdge,
42 );
43
44 #[cfg(all(feature = "NSLayoutConstraint", feature = "UIGeometry"))]
45 #[unsafe(method(constraintsActiveWhenNearEdge:))]
46 #[unsafe(method_family = none)]
47 pub unsafe fn constraintsActiveWhenNearEdge(
48 &self,
49 edge: NSDirectionalRectEdge,
50 ) -> Retained<NSArray<NSLayoutConstraint>>;
51
52 #[cfg(all(feature = "NSLayoutConstraint", feature = "UIGeometry"))]
53 #[unsafe(method(setConstraints:activeWhenAwayFromEdge:))]
57 #[unsafe(method_family = none)]
58 pub unsafe fn setConstraints_activeWhenAwayFromEdge(
59 &self,
60 tracking_constraints: &NSArray<NSLayoutConstraint>,
61 edge: NSDirectionalRectEdge,
62 );
63
64 #[cfg(all(feature = "NSLayoutConstraint", feature = "UIGeometry"))]
65 #[unsafe(method(constraintsActiveWhenAwayFromEdge:))]
66 #[unsafe(method_family = none)]
67 pub unsafe fn constraintsActiveWhenAwayFromEdge(
68 &self,
69 edge: NSDirectionalRectEdge,
70 ) -> Retained<NSArray<NSLayoutConstraint>>;
71
72 #[unsafe(method(removeAllTrackedConstraints))]
74 #[unsafe(method_family = none)]
75 pub unsafe fn removeAllTrackedConstraints(&self);
76 );
77}
78
79#[cfg(feature = "UILayoutGuide")]
81impl UITrackingLayoutGuide {
82 extern_methods!(
83 #[unsafe(method(init))]
84 #[unsafe(method_family = init)]
85 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
86
87 #[unsafe(method(new))]
88 #[unsafe(method_family = new)]
89 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
90 );
91}