Search documentation of wx

# View Source wxDropFilesEvent (wx v2.4.3)

This class is used for drop files events, that is, when files have been dropped onto the window.

The window must have previously been enabled for dropping by calling `wxWindow:dragAcceptFiles/2`.

Important note: this is a separate implementation to the more general drag and drop implementation documented in the overview_dnd. It uses the older, Windows message-based approach of dropping files.

See:

- Overview events

- `wxWindow:dragAcceptFiles/2`

This class is derived, and can use functions, from:

- `wxEvent`

wxWidgets docs: wxDropFilesEvent

## Events

Use `wxEvtHandler:connect/3` with `wxDropFilesEventType` to subscribe to events of this type.

# Summary

## Types

wxDropFiles()
wxDropFilesEvent()
wxDropFilesEventType()

## Functions

getFiles(This)

Returns an array of filenames.

getNumberOfFiles(This)

Returns the number of files dropped.

getPosition(This)

Returns the position at which the files were dropped.

# Types

Link to this type

# wxDropFiles()

View Source

    -type wxDropFiles() ::
              #wxDropFiles{type :: wxDropFilesEvent:wxDropFilesEventType(),
                           pos :: {X :: integer(), Y :: integer()},
                           files :: [unicode:chardata()]}.

Link to this type

# wxDropFilesEvent()

View Source

    -type wxDropFilesEvent() :: wx:wx_object().

Link to this type

# wxDropFilesEventType()

View Source

    -type wxDropFilesEventType() :: drop_files.

# Functions

Link to this function

# getFiles(This)

View Source

    -spec getFiles(This) -> [unicode:charlist()] when This :: wxDropFilesEvent().

Returns an array of filenames.

Link to this function

# getNumberOfFiles(This)

View Source

    -spec getNumberOfFiles(This) -> integer() when This :: wxDropFilesEvent().

Returns the number of files dropped.

Link to this function

# getPosition(This)

View Source

    -spec getPosition(This) -> {X :: integer(), Y :: integer()} when This :: wxDropFilesEvent().

Returns the position at which the files were dropped.

Returns an array of filenames.