Top | ![]() |
![]() |
![]() |
![]() |
These functions let applications be informed about available software updates (for themselves) and install those updates.
The underlying portal is org.freedesktop.portal.Flatpak.
void xdp_portal_update_monitor_start (XdpPortal *portal
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer data
);
Makes XdpPortal start monitoring for available software updates.
When a new update is available, the “update-available”. signal is emitted.
Use xdp_portal_update_monitor_stop()
to stop monitoring.
portal |
||
cancellable |
optional GCancellable. |
[nullable] |
callback |
a callback to call when the request is done. |
[scope async] |
data |
data to pass to |
[closure] |
gboolean xdp_portal_update_monitor_start_finish (XdpPortal *portal
,GAsyncResult *result
,GError **error
);
Finishes an update-monitor request, and returns the result in the form of boolean.
void
xdp_portal_update_monitor_stop (XdpPortal *portal
);
Stops update monitoring that was started with
xdp_portal_update_monitor_start()
.
void xdp_portal_update_install (XdpPortal *portal
,XdpParent *parent
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer data
);
Installs an available software update. This should be called in response to a “update-available” signal.
During the update installation, the “update-progress” signal will be emitted to provide progress information.
portal |
||
parent |
||
cancellable |
optional GCancellable. |
[nullable] |
callback |
a callback to call when the request is done. |
[scope async] |
data |
data to pass to |
[closure] |
gboolean xdp_portal_update_install_finish (XdpPortal *portal
,GAsyncResult *result
,GError **error
);
Finishes an update-installation request, and returns the result in the form of boolean.
Note that the update may not be completely installed by the time this function is called. You need to listen to the “update-progress” signal to learn when the installation is complete.
The values of this enum are returned in the “update-progress” signal to indicate the current progress of an update installation.