Method

GioTaskget_context

since: 2.36

Declaration

GMainContext*
g_task_get_context (
  GTask* task
)

Description

Gets the GMainContext that task will return its result in (that is, the context that was the [thread-default main context][g-main-context-push-thread-default] at the point when task was created).

This will always return a non-NULL value, even if the task’s context is the default GMainContext.

Available since: 2.36

Return value

Type: GMainContext

tasks GMainContext.

The data is owned by the instance.