Gtk.AppChooserButton
const Gtk = imports.gi.Gtk; let app_chooser_button = new Gtk.AppChooserButton({ heading: value, show_default_item: value, show_dialog_item: value, });
The Gtk.AppChooserButton is a widget that lets the user select an application. It implements the Gtk.AppChooser interface.
Initially, a Gtk.AppChooserButton selects the first application in its list, which will either be the most-recently used application or, if Gtk.show-default-item is true, the default application.
The list of applications shown in a Gtk.AppChooserButton includes the recommended applications for the given content type. When Gtk.show-default-item is set, the default application is also included. To let the user chooser other applications, you can set the Gtk.show-dialog-item property, which allows to open a full Gtk.AppChooserDialog.
It is possible to add custom items to the list, using Gtk.append_custom_item. These items cause the Gtk.custom-item-activated signal to be emitted when they are selected.
To track changes in the selected application, use the Gtk.changed signal.
Hierarchy
-
GObject.Object
-
GObject.InitiallyUnowned
-
Gtk.Widget
-
Gtk.Container
-
Gtk.Bin
-
Gtk.ComboBox
- Gtk.AppChooserButton
-
-
-
-
-
Methods
- Gtk.AppChooserButton.prototype.append_custom_item
- Gtk.AppChooserButton.prototype.append_separator
- Gtk.AppChooserButton.prototype.get_heading
- Gtk.AppChooserButton.prototype.get_show_default_item
- Gtk.AppChooserButton.prototype.get_show_dialog_item
- Gtk.AppChooserButton.prototype.set_active_custom_item
- Gtk.AppChooserButton.prototype.set_heading
- Gtk.AppChooserButton.prototype.set_show_default_item
- Gtk.AppChooserButton.prototype.set_show_dialog_item