Trait gdk_pixbuf::subclass::prelude::ApplicationImpl
source · pub trait ApplicationImpl: ObjectImpl + ApplicationImplExt {
// Provided methods
fn activate(&self) { ... }
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 open(&self, files: &[File], hint: &str) { ... }
fn quit_mainloop(&self) { ... }
fn run_mainloop(&self) { ... }
fn shutdown(&self) { ... }
fn startup(&self) { ... }
fn handle_local_options(&self, options: &VariantDict) -> ExitCode { ... }
}
Provided Methods§
sourcefn activate(&self)
fn activate(&self)
Activates the application.
In essence, this results in the activate
signal being
emitted in the primary instance.
The application must be registered before calling this function.
fn after_emit(&self, platform_data: &Variant)
fn before_emit(&self, platform_data: &Variant)
fn command_line(&self, command_line: &ApplicationCommandLine) -> ExitCode
sourcefn local_command_line(&self, arguments: &mut ArgumentList) -> Option<ExitCode>
fn local_command_line(&self, arguments: &mut ArgumentList) -> Option<ExitCode>
This virtual function is always invoked in the local instance. It
gets passed a pointer to a None
-terminated copy of argv
and is
expected to remove arguments that it handled (shifting up remaining
arguments).
The last argument to local_command_line()
is a pointer to the status
variable which can used to set the exit status that is returned from
ApplicationExtManual::run()
.
See ApplicationExtManual::run()
for more details on Application
startup.
arguments
array of command line arguments
Returns
true
if the commandline has been completely handled
exit_status
exit status to fill after processing the command line.
sourcefn open(&self, files: &[File], hint: &str)
fn open(&self, files: &[File], hint: &str)
Opens the given files.
In essence, this results in the open
signal being emitted
in the primary instance.
n_files
must be greater than zero.
hint
is simply passed through to the ::open signal. It is
intended to be used by applications that have multiple modes for
opening files (eg: “view” vs “edit”, etc). Unless you have a need
for this functionality, you should use “”.
The application must be registered before calling this function
and it must have the ApplicationFlags::HANDLES_OPEN
flag set.
files
an array of GFiles
to open
hint
a hint (or “”), but never None