Struct gpui2::AnyWindowHandle
source · pub struct AnyWindowHandle { /* private fields */ }
Implementations§
source§impl AnyWindowHandle
impl AnyWindowHandle
pub fn window_id(&self) -> WindowId
pub fn downcast<T: 'static>(&self) -> Option<WindowHandle<T>>
pub fn update<C, R>( self, cx: &mut C, update: impl FnOnce(AnyView, &mut WindowContext<'_>) -> R ) -> Result<R>where C: Context,
pub fn read<T, C, R>( self, cx: &C, read: impl FnOnce(View<T>, &AppContext) -> R ) -> Result<R>where C: Context, T: 'static,
Trait Implementations§
source§impl Clone for AnyWindowHandle
impl Clone for AnyWindowHandle
source§fn clone(&self) -> AnyWindowHandle
fn clone(&self) -> AnyWindowHandle
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Hash for AnyWindowHandle
impl Hash for AnyWindowHandle
source§impl<V: 'static> Into<AnyWindowHandle> for WindowHandle<V>
impl<V: 'static> Into<AnyWindowHandle> for WindowHandle<V>
source§fn into(self) -> AnyWindowHandle
fn into(self) -> AnyWindowHandle
Converts this type into the (usually inferred) input type.
source§impl PartialEq<AnyWindowHandle> for AnyWindowHandle
impl PartialEq<AnyWindowHandle> for AnyWindowHandle
source§fn eq(&self, other: &AnyWindowHandle) -> bool
fn eq(&self, other: &AnyWindowHandle) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for AnyWindowHandle
impl Eq for AnyWindowHandle
impl StructuralEq for AnyWindowHandle
impl StructuralPartialEq for AnyWindowHandle
Auto Trait Implementations§
impl RefUnwindSafe for AnyWindowHandle
impl Send for AnyWindowHandle
impl Sync for AnyWindowHandle
impl Unpin for AnyWindowHandle
impl UnwindSafe for AnyWindowHandle
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.