wxDropFilesEvent(3erl)

πŸ’… wxDropFilesEvent: Erlang module definition πŸ’…

Okay so welcome to the wxDropFilesEvent(3erl) page, bestie β€” this is the Erlang module definition for the wxDropFilesEvent class. It's giving drop-files-event main character energy, and we're gonna get through every single detail together. πŸ¦‹βœ¨

🌸 NAME 🌸

wxDropFilesEvent β€” functions for the wxDropFilesEvent class.

✨ DESCRIPTION ✨

Okay so 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. Like, no cap, you need that setup first. πŸ’…

🚨 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.
πŸͺŸ Remark: Windows only until version 2.8.9, available on all platforms since 2.8.10.

πŸ‘€ 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.

πŸ¦‹ DATA TYPES πŸ¦‹

wxDropFilesEvent() = wx:wx_object()

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

wxDropFilesEventType() = drop_files

πŸ‘‘ EXPORTS πŸ‘‘

🌟 getPosition(This) -> {X :: integer(), Y :: integer()} 🌟

Types:

This = wxDropFilesEvent()

Returns the position at which the files were dropped.

Returns an array of filenames.

🌟 getNumberOfFiles(This) -> integer() 🌟

Types:

This = wxDropFilesEvent()

Returns the number of files dropped.

🌟 getFiles(This) -> [unicode:charlist()] 🌟

Types:

This = wxDropFilesEvent()

Returns an array of filenames.


mwah πŸ’‹ β€” from the wxWidgets team, with wx 2.2.2.1 and manual wxDropFilesEvent(3erl). Stay hydrated, bestie. πŸ’–βœ¨

πŸ“¦ where this page comes from