# AdaptiveTrigger

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls/visual_state/struct-adaptivetrigger/

**struct** · [`ferroui-controls`](/docs/0.5.0/api/ferroui-controls/) · v0.5.0

```rust
struct AdaptiveTrigger
```

A trigger that is active while the window is at least `MinWindowWidth` wide and
`MinWindowHeight` high (WinUI's `AdaptiveTrigger`).

The size is the client size of the window (the presentation source) of the element whose
states the trigger selects, not the size of that element. A value of -1 (the default) leaves
that dimension out; with both at -1 the trigger never applies.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L159)

## Members

- [`TYPE`](#assoc_const-type)
- [`to_ref`](#function-to_ref)
- [`min_window_width_property`](#function-min_window_width_property)
- [`min_window_height_property`](#function-min_window_height_property)
- [`construct`](#function-construct)
- [`new`](#function-new)
- [`min_window_width`](#function-min_window_width)
- [`set_min_window_width`](#function-set_min_window_width)
- [`min_window_height`](#function-min_window_height)
- [`set_min_window_height`](#function-set_min_window_height)

<a id="assoc_const-type"></a>

### TYPE

```rust
const TYPE: &'static $crate::TypeInfo
```

The runtime type of this class.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L163)

<a id="function-to_ref"></a>

### to_ref

```rust
fn to_ref(self: &Self) -> $crate::Ref<AdaptiveTrigger>
```

Returns a strong reference to this object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L163)

<a id="function-min_window_width_property"></a>

### min_window_width_property

```rust
fn min_window_width_property() -> &'static StyledProperty<f64>
```

Defines the `MinWindowWidth` property: the smallest window width at which the trigger
applies. Default -1 (no condition on the width).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L177)

<a id="function-min_window_height_property"></a>

### min_window_height_property

```rust
fn min_window_height_property() -> &'static StyledProperty<f64>
```

Defines the `MinWindowHeight` property: the smallest window height at which the trigger
applies. Default -1 (no condition on the height).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L177)

<a id="function-construct"></a>

### construct

```rust
fn construct() -> Self
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L192)

<a id="function-new"></a>

### new

```rust
fn new() -> Ref<Self>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L196)

<a id="function-min_window_width"></a>

### min_window_width

```rust
fn min_window_width(self: &Self) -> f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L200)

<a id="function-set_min_window_width"></a>

### set_min_window_width

```rust
fn set_min_window_width(self: &Self, value: f64)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L204)

<a id="function-min_window_height"></a>

### min_window_height

```rust
fn min_window_height(self: &Self) -> f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L208)

<a id="function-set_min_window_height"></a>

### set_min_window_height

```rust
fn set_min_window_height(self: &Self, value: f64)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/visual_state/state_trigger_base.rs#L212)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- [`Receiver`](/docs/0.5.0/api/ferroui-system/task/oneshot/struct-receiver/)
- `Any`
- [`FerroObjectImplExt`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimplext/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- `Deref`
- [`Upcast<T>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`Upcast<AdaptiveTrigger>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`StaticType`](/docs/0.5.0/api/ferroui-base/trait-statictype/)
- [`ObjectType`](/docs/0.5.0/api/ferroui-base/trait-objecttype/)
- [`Subclassable<T>`](/docs/0.5.0/api/ferroui-base/trait-subclassable/)
- [`DefaultConstructible`](/docs/0.5.0/api/ferroui-base/trait-defaultconstructible/)
- [`FerroObjectImpl`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimpl/)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
