pub struct Application {
    pub window: RefCell<Option<WeakRef<Window>>>,
    pub model: ProvidersModel,
    pub is_locked: Cell<bool>,
    pub lock_timeout_id: RefCell<Option<Source>>,
    pub can_be_locked: Cell<bool>,
    pub is_keyring_open: Cell<bool>,
}

Fields§

§window: RefCell<Option<WeakRef<Window>>>§model: ProvidersModel§is_locked: Cell<bool>§lock_timeout_id: RefCell<Option<Source>>§can_be_locked: Cell<bool>§is_keyring_open: Cell<bool>

Implementations§

source§

impl Application

source

fn register_type()

Registers the type only once.

source§

impl Application

source

pub fn downgrade(&self) -> <Self as Downgrade>::Weak

Trait Implementations§

source§

impl ApplicationImpl for Application

source§

fn startup(&self)

source§

fn activate(&self)

source§

fn open(&self, files: &[File], _hint: &str)

§

fn after_emit(&self, platform_data: &Variant)

§

fn before_emit(&self, platform_data: &Variant)

§

fn command_line(&self, command_line: &ApplicationCommandLine) -> ExitCode

§

fn local_command_line(&self, arguments: &mut ArgumentList) -> Option<ExitCode>

§

fn quit_mainloop(&self)

§

fn run_mainloop(&self)

§

fn shutdown(&self)

§

fn handle_local_options(&self, options: &VariantDict) -> ExitCode

source§

impl Default for Application

source§

fn default() -> Application

Returns the “default value” for a type. Read more
source§

impl DerivedObjectProperties for Application

source§

fn derived_properties() -> &'static [ParamSpec]

Properties installed for this type.
source§

fn derived_property(&self, id: usize, pspec: &ParamSpec) -> Value

Similar to ObjectImpl but auto-generated by the [Properties] macro to allow handling more complex use-cases.
source§

fn derived_set_property(&self, id: usize, value: &Value, pspec: &ParamSpec)

Similar to ObjectImpl but auto-generated by the [Properties] macro to allow handling more complex use-cases.
source§

impl GtkApplicationImpl for Application

§

fn window_added(&self, window: &Window)

§

fn window_removed(&self, window: &Window)

source§

impl ObjectImpl for Application

source§

fn properties() -> &'static [ParamSpec]

Properties installed for this type.
source§

fn set_property(&self, id: usize, value: &Value, pspec: &ParamSpec)

Property setter. Read more
source§

fn property(&self, id: usize, pspec: &ParamSpec) -> Value

Property getter. Read more
§

fn signals() -> &'static [Signal]

Signals installed for this type.
§

fn constructed(&self)

Constructed. Read more
§

fn dispose(&self)

Disposes of the object. Read more
§

fn notify(&self, pspec: &ParamSpec)

Function to be called when property change is notified for with self.notify("property").
§

fn dispatch_properties_changed(&self, pspecs: &[ParamSpec])

source§

impl ObjectSubclass for Application

§

type Interfaces = ()

List of interfaces implemented by this type.
§

type Class = ClassStruct<Application>

The C class struct. Read more
§

type Instance = InstanceStruct<Application>

The C instance struct. Read more
source§

fn new() -> Self

Constructor. Read more
source§

const NAME: &'static str = "Application"

GObject type name. Read more
§

type ParentType = Application

Parent Rust type to inherit from.
§

type Type = Application

Wrapper around this subclass defined with wrapper!
§

const ABSTRACT: bool = false

If this subclass is an abstract class or not. Read more
§

fn type_init(_type_: &mut InitializingType<Self>)

Additional type initialization. Read more
§

fn class_init(_klass: &mut Self::Class)

Class initialization. Read more
§

fn with_class(_klass: &Self::Class) -> Self

Constructor. Read more
§

fn instance_init(_obj: &InitializingObject<Self>)

Performs additional instance initialization. Read more
source§

impl ObjectSubclassType for Application

source§

fn type_data() -> NonNull<TypeData>

Storage for the type-specific data used during registration.
source§

fn type_() -> Type

Returns the glib::Type ID of the subclass. Read more
source§

impl AdwApplicationImpl for Application

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> ApplicationImplExt for T
where T: ApplicationImpl,

§

fn parent_activate(&self)

§

fn parent_after_emit(&self, platform_data: &Variant)

§

fn parent_before_emit(&self, platform_data: &Variant)

§

fn parent_command_line(&self, command_line: &ApplicationCommandLine) -> ExitCode

§

fn parent_local_command_line( &self, arguments: &mut ArgumentList ) -> Option<ExitCode>

§

fn parent_open(&self, files: &[File], hint: &str)

§

fn parent_quit_mainloop(&self)

§

fn parent_run_mainloop(&self)

§

fn parent_shutdown(&self)

§

fn parent_startup(&self)

§

fn parent_handle_local_options(&self, options: &VariantDict) -> ExitCode

source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> GtkApplicationImplExt for T
where T: GtkApplicationImpl,

§

fn parent_window_added(&self, window: &Window)

§

fn parent_window_removed(&self, window: &Window)

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> IntoSql for T

§

fn into_sql<T>(self) -> Self::Expression
where Self: AsExpression<T> + Sized, T: SqlType + TypedExpressionType,

Convert self to an expression for Diesel’s query builder. Read more
§

fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
where &'a Self: AsExpression<T>, T: SqlType + TypedExpressionType,

Convert &self to an expression for Diesel’s query builder. Read more
§

impl<T> NoneValue for T
where T: Default,

§

type NoneType = T

§

fn null_value() -> T

The none-equivalent value.
§

impl<T> ObjectImplExt for T
where T: ObjectImpl,

§

fn parent_constructed(&self)

Chain up to the parent class’ implementation of glib::Object::constructed().
§

fn parent_notify(&self, pspec: &ParamSpec)

Chain up to the parent class’ implementation of glib::Object::notify().
§

fn parent_dispatch_properties_changed(&self, pspecs: &[ParamSpec])

Chain up to the parent class’ implementation of glib::Object::dispatch_properties_changed().
§

fn signal_chain_from_overridden( &self, token: &SignalClassHandlerToken, values: &[Value] ) -> Option<Value>

Chain up to parent class signal handler.
§

impl<T> ObjectSubclassExt for T
where T: ObjectSubclass,

§

fn instance(&self) -> BorrowedObject<'_, <T as ObjectSubclass>::Type>

👎Deprecated: Use obj() instead
Returns the corresponding object instance.
§

fn from_instance(obj: &<T as ObjectSubclass>::Type) -> &T

👎Deprecated: Use from_obj() instead
Returns the implementation from an instance.
§

fn obj(&self) -> BorrowedObject<'_, <T as ObjectSubclass>::Type>

Returns the corresponding object instance. Read more
§

fn from_obj(obj: &<T as ObjectSubclass>::Type) -> &T

Returns the implementation from an instance. Read more
§

fn ref_counted(&self) -> ObjectImplRef<T>

Returns a new reference-counted wrapper around self.
§

fn instance_data<U>(&self, type_: Type) -> Option<&U>
where U: Any + Send + Sync + 'static,

Returns a pointer to the instance implementation specific data. Read more
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more