prompt_sync


Description:

public int prompt_sync (string? type, string? title, string? primary_text, string? secondary_text, bool use_markup, List<string>? button_captions, Cancellable? cancellable = null) throws Error

Prompts a user for a decision.

The type can be one of "info", "warning", "question" or "error", to include an icon in the message prompt; anything else results in no icon in the message.

If button_captions is null or empty list, then only one button is shown in the prompt, a "Dismiss" button.

If an error occurred, the function sets throws and returns -1.

Parameters:

this

an UserPrompter

type

type of the prompt; can be null

title

window title of the prompt; can be null

primary_text

primary text of the prompt; can be null

secondary_text

secondary text of the prompt; can be null

use_markup

whether both texts are with markup

button_captions

captions of buttons to use in the message; can be null

cancellable

optional Cancellable object, or null

Returns:

0-based index of a button being used by a user as a response, corresponding to button_captions list.