session_inhibit


Description:

public async int session_inhibit (Parent? parent, string? reason, InhibitFlags flags, Cancellable? cancellable) throws Error

Inhibits various session status changes.

To obtain an ID that can be used to undo the inhibition, use [method@Portal.session_inhibit_finish] in the callback.

To remove an active inhibitor, call [method@Portal.session_uninhibit] with the same ID.

Parameters:

this

a [class@Portal]

parent

parent window information

reason

user-visible reason for the inhibition

flags

information about what to inhibit

cancellable

optional [class@Gio.Cancellable]

callback

a callback to call when the request is done

data

data to pass to callback