engage/generated/unity_engine/
scrollviewstate.rs1#[cfg(feature = "unity_engine-scrollviewstate-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::system::object::{IObject, Object};
9
10 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/unity_engine/scrollviewstate/ScrollViewState.md"))]
11 #[::unity::class(namespace = "UnityEngine", name = "ScrollViewState")]
12 #[parent(crate::system::object::Object)]
13 pub struct ScrollViewState {
14 #[offset(16)]
15 #[rename(name = "position")]
16 pub position: crate::unity_engine::rect::Rect,
17 #[offset(32)]
18 #[rename(name = "visibleRect")]
19 pub visible_rect: crate::unity_engine::rect::Rect,
20 #[offset(48)]
21 #[rename(name = "viewRect")]
22 pub view_rect: crate::unity_engine::rect::Rect,
23 #[offset(64)]
24 #[rename(name = "scrollPosition")]
25 pub scroll_position: crate::unity_engine::vector2::Vector2,
26 #[offset(72)]
27 #[rename(name = "apply")]
28 pub apply: bool,
29 #[offset(73)]
30 #[rename(name = "isDuringTouchScroll")]
31 pub is_during_touch_scroll: bool,
32 #[offset(76)]
33 #[rename(name = "touchScrollStartMousePosition")]
34 pub touch_scroll_start_mouse_position: crate::unity_engine::vector2::Vector2,
35 #[offset(84)]
36 #[rename(name = "touchScrollStartPosition")]
37 pub touch_scroll_start_position: crate::unity_engine::vector2::Vector2,
38 #[offset(92)]
39 #[rename(name = "velocity")]
40 pub velocity: crate::unity_engine::vector2::Vector2,
41 #[offset(100)]
42 #[rename(name = "previousTimeSinceStartup")]
43 pub previous_time_since_startup: f32,
44 }
45}
46
47#[cfg(feature = "unity_engine-scrollviewstate-types")]
48pub use __types::*;
49
50#[cfg(feature = "unity_engine-scrollviewstate")]
51pub trait IScrollViewStateMethods: IScrollViewState {
52 #[doc = "`.ctor()` overload"]
53 fn ctor(self) -> () {
54 unsafe {
55 let __receiver = <ScrollViewState as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
56 ::unity::il2cpp_call!((::unity::module_base()+0x3c51710usize)as*mut u8,();
57(ScrollViewState)__receiver)
58 }
59 }
60}
61
62#[cfg(feature = "unity_engine-scrollviewstate")]
63impl<__T: IScrollViewState> IScrollViewStateMethods for __T {}
64
65#[cfg(feature = "unity_engine-scrollviewstate")]
66impl ScrollViewState {
67 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
68 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
69 }
70}
71
72#[cfg(feature = "unity_engine-scrollviewstate")]
73impl ScrollViewState {
74 #[doc = "`.ctor()` — no args"]
75 pub fn new() -> Self {
76 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
77 panic!(
78 "{}
79::{}
80 failed to instantiate",
81 ::core::stringify!(ScrollViewState),
82 ::core::stringify!(new),
83 )
84 });
85 <Self as IScrollViewStateMethods>::ctor(this);
86 this
87 }
88}
89
90#[cfg(feature = "unity_engine-scrollviewstate")]
91#[doc(hidden)]
92pub mod prelude {
93 pub use super::{IScrollViewState, IScrollViewStateMethods, ScrollViewState};
94 pub use crate::system::object::IObject;
95 #[cfg(feature = "system-object")]
96 pub use crate::system::object::IObjectMethods;
97}