Class
XdpPortal
unstable since: 1.0
Description [src]
final class Xdp.Portal : GObject.Object
implements Gio.Initable {
/* No available fields */
}
Context for portal calls.
The XdpPortal object provides the main context object for the portal operations of libportal.
Typically, an application will create a single XdpPortal
object with xdp_portal_new()
and use it throughout its lifetime.
Available since: 1.0
Constructors
xdp_portal_new
Creates a new XdpPortal
object. If D-Bus is unavailable this API will abort.
We recommend using xdp_portal_initable_new()
to safely handle this failure.
unstable since: 1.0
Functions
xdp_portal_running_under_flatpak
Detects if running inside of a Flatpak or WebKit sandbox.
unstable since: 1.0
xdp_portal_running_under_sandbox
This function tries to determine if the current process is running under a sandbox that requires the use of portals.
unstable since: 1.0
xdp_portal_running_under_snap
Detects if you are running inside of a Snap sandbox.
unstable since: 1.0
Instance methods
xdp_portal_compose_email
Presents a window that lets the user compose an email, with some pre-filled information.
unstable since: 1.0
xdp_portal_create_remote_desktop_session_finish
Finishes the create-remote-desktop request, and returns a XdpSession
.
unstable since: 1.0
xdp_portal_create_screencast_session_finish
Finishes the create-screencast request, and returns a XdpSession
.
unstable since: 1.0
xdp_portal_dynamic_launcher_get_desktop_entry
This function gets the contents of a .desktop file that was previously installed by the dynamic launcher portal.
unstable since: 1.0
xdp_portal_dynamic_launcher_get_icon
This function gets the icon associated with a .desktop file that was previously installed by the dynamic launcher portal.
unstable since: 1.0
xdp_portal_dynamic_launcher_install
This function completes installation of a launcher so that the icon and name given in previous method calls will show up in the desktop environment’s menu.
unstable since: 1.0
xdp_portal_dynamic_launcher_prepare_install
Presents a dialog to the user so they can confirm they want to install a launcher to their desktop.
unstable since: 1.0
xdp_portal_dynamic_launcher_prepare_install_finish
Finishes the prepare-install-launcher request, and returns
GVariant
dictionary with the following information:
unstable since: 1.0
xdp_portal_dynamic_launcher_request_install_token
Requests a token which can be passed to xdp_portal_dynamic_launcher_install()
to complete installation of the launcher without user interaction.
unstable since: 1.0
xdp_portal_dynamic_launcher_uninstall
This function uninstalls a launcher that was previously installed using the dynamic launcher portal, resulting in the .desktop file and icon being deleted.
unstable since: 1.0
xdp_portal_get_user_information_finish
Finishes the get-user-information request.
unstable since: 1.0
xdp_portal_location_monitor_start
Makes XdpPortal
start monitoring location changes.
unstable since: 1.0
xdp_portal_location_monitor_stop
Stops location monitoring that was started with
xdp_portal_location_monitor_start()
.
unstable since: 1.0
xdp_portal_open_directory
Opens the directory containing the file specified by the uri
.
unstable since: 1.0
xdp_portal_open_pipewire_remote_for_camera
Opens a file descriptor to the pipewire remote where the camera nodes are available.
unstable since: 1.0
xdp_portal_prepare_print
Presents a print dialog to the user and returns print settings and page setup.
unstable since: 1.0
xdp_portal_save_files
Asks for a folder as a location to save one or more files.
unstable since: 1.0
xdp_portal_session_monitor_query_end_response
This method should be called within one second of
receiving a XdpPortal::session-state-changed
signal
with the ‘Query End’ state, to acknowledge that they
have handled the state change.
unstable since: 1.0
xdp_portal_session_monitor_start
Makes XdpPortal
start monitoring the login session state.
unstable since: 1.0
xdp_portal_session_monitor_stop
Stops session state monitoring that was started with
xdp_portal_session_monitor_start()
.
unstable since: 1.0
xdp_portal_session_uninhibit
Removes an inhibitor that was created by a call
to xdp_portal_session_inhibit()
.
unstable since: 1.0
xdp_portal_set_background_status
Sets the status information of the application, for when it’s running in background.
unstable since: 1.0
xdp_portal_set_background_status_finish
Finishes setting the background status of the application.
unstable since: 1.0
xdp_portal_spawn
Creates a new copy of the applications sandbox, and runs a process in, with the given arguments.
unstable since: 1.0
xdp_portal_spawn_signal
Sends a Unix signal to a process that has been spawned
by xdp_portal_spawn()
.
unstable since: 1.0
xdp_portal_update_monitor_start
Makes XdpPortal
start monitoring for available software updates.
unstable since: 1.0
xdp_portal_update_monitor_stop
Stops update monitoring that was started with
xdp_portal_update_monitor_start()
.
unstable since: 1.0
Methods inherited from GInitable (1)
Signals
Xdp.Portal::location-updated
Emitted when location monitoring is enabled and the location changes.
unstable since: 1.0
Xdp.Portal::notification-action-invoked
Emitted when a non-exported action is activated on a notification.
unstable since: 1.0
Xdp.Portal::session-state-changed
Emitted when session state monitoring is enabled and the state of the login session changes or the screensaver is activated or deactivated.
unstable since: 1.0
Xdp.Portal::spawn-exited
Emitted when a process that was spawned with xdp_portal_spawn()
exits.
unstable since: 1.0
Xdp.Portal::update-available
Emitted when updates monitoring is enabled and a new update is available.
unstable since: 1.0
Xdp.Portal::update-progress
Emitted to indicate progress of an update installation.
unstable since: 1.0
Signals inherited from GObject (1)
GObject::notify
The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.
unstable since: 2.0