### Class

# WebKit2 FileChooserRequest

#### Description [src]

    class WebKit2.FileChooserRequest : GObject.Object
    {
      WebKitFileChooserRequestPrivate* priv
    }

A request to open a file chooser.

Whenever the user interacts with an HTML input element with file type, WebKit will need to show a dialog to choose one or more files to be uploaded to the server along with the rest of the form data. For that to happen in a general way, instead of just opening a `GtkFileChooserDialog` (which might be not desirable in some cases, which could prefer to use their own file chooser dialog), WebKit will fire the `WebKitWebView::run-file-chooser` signal with a `WebKitFileChooserRequest` object, which will allow the client application to specify the files to be selected, to inspect the details of the request (e.g. if multiple selection should be allowed) and to cancel the request, in case nothing was selected.

In case the client application does not wish to handle this signal, WebKit will provide a default handler which will asynchronously run a regular `GtkFileChooserDialog` for the user to interact with.

#### Ancestors

- GObject

#### Instance methods

###### webkit_file_chooser_request_cancel

Ask WebKit to cancel the request.

###### webkit_file_chooser_request_get_mime_types

Get the list of MIME types the file chooser dialog should handle.

###### webkit_file_chooser_request_get_mime_types_filter

Get the filter currently associated with the request.

###### webkit_file_chooser_request_get_select_multiple

Whether the file chooser should allow selecting multiple files.

###### webkit_file_chooser_request_get_selected_files

Get the list of selected files associated to the request.

###### webkit_file_chooser_request_select_files

Ask WebKit to select local files for upload and complete the request.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### WebKit2.FileChooserRequest:filter

The filter currently associated with the request. See `webkit_file_chooser_request_get_mime_types_filter()` for more details.

###### WebKit2.FileChooserRequest:mime-types

A `NULL`-terminated array of strings containing the list of MIME types the file chooser dialog should handle. See `webkit_file_chooser_request_get_mime_types()` for more details.

###### WebKit2.FileChooserRequest:select-multiple

Whether the file chooser should allow selecting multiple files. See `webkit_file_chooser_request_get_select_multiple()` for more details.

###### WebKit2.FileChooserRequest:selected-files

A `NULL`-terminated array of strings containing the list of selected files associated to the current request. See `webkit_file_chooser_request_get_selected_files()` for more details.

#### Signals

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct WebKit2FileChooserRequestClass {
      GObjectClass parent_class;
      void (* _webkit_reserved0) (
    void
      );
      void (* _webkit_reserved1) (
    void
      );
      void (* _webkit_reserved2) (
    void
      );
      void (* _webkit_reserved3) (
    void
      );

    }

No description available.

###### Class members

`parent_class: GObjectClass`

  No description available.

`_webkit_reserved0: void (* _webkit_reserved0) ( void )`

  No description available.

`_webkit_reserved1: void (* _webkit_reserved1) ( void )`

  No description available.

`_webkit_reserved2: void (* _webkit_reserved2) ( void )`

  No description available.

`_webkit_reserved3: void (* _webkit_reserved3) ( void )`

  No description available.