get_main_context


Description:

public unowned MainContext get_main_context ()

Gets the default main context for a scheduler.

This may be a different value depending on the calling thread.

For example, calling this on the [class@Dex.ThreadPoolScheduler] from outside a worker thread may result in getting a shared [ struct@GLib.MainContext] for the process.

However, calling from a worker thread may give you a [struct@GLib.MainContext] specifically for that thread.

Parameters:

this

a [class@Dex.Scheduler]

Returns:

a [struct@GLib.MainContext]