|
Mana
|
An emote popup. More...
#include <emotepopup.h>
Public Member Functions | |
| EmotePopup () | |
| Constructor. | |
| ~EmotePopup () override | |
| void | draw (gcn::Graphics *graphics) override |
| Draws the emotes. | |
| void | mouseExited (gcn::MouseEvent &event) override |
| void | mousePressed (gcn::MouseEvent &event) override |
| void | mouseMoved (gcn::MouseEvent &event) override |
| int | getSelectedEmoteId () const |
| Returns the selected emote. | |
| void | addSelectionListener (gcn::SelectionListener *listener) |
| Adds a listener to the list that's notified each time a change to the selection occurs. | |
| void | removeSelectionListener (gcn::SelectionListener *listener) |
| Removes a listener from the list that's notified each time a change to the selection occurs. | |
Public Member Functions inherited from Popup | |
| Popup (const std::string &name=std::string(), SkinType skinType=SkinType::Popup) | |
| Constructor. | |
| ~Popup () override | |
| Destructor. | |
| void | add (gcn::Widget *widget) override |
| void | add (gcn::Widget *widget, int x, int y) override |
| void | draw (gcn::Graphics *graphics) override |
| Draws the popup. | |
| void | drawFrame (gcn::Graphics *graphics) override |
| Draws the popup frame. | |
| void | setContentSize (int width, int height) |
| Sets the size of this popup. | |
| void | setLocationRelativeTo (gcn::Widget *widget) |
| Sets the location relative to the given widget. | |
| void | mouseMoved (gcn::MouseEvent &event) override |
| void | setMinWidth (int width) |
| Sets the minimum width of the popup. | |
| int | getMinWidth () const |
| void | setMinHeight (int height) |
| Sets the minimum height of the popup. | |
| int | getMinHeight () const |
| void | setMaxWidth (int width) |
| Sets the maximum width of the popup. | |
| int | getMaxWidth () const |
| void | setMaxHeight (int height) |
| Sets the minimum height of the popup. | |
| int | getMaxHeight () const |
| int | getPadding () const |
| Gets the padding of the popup. | |
| void | setPadding (int padding) |
| void | setPopupName (const std::string &name) |
| Sets the name of the popup. | |
| const std::string & | getPopupName () const |
| void | scheduleDelete () |
| Schedule this popup for deletion. | |
| gcn::Rectangle | getChildrenArea () override |
| void | position (int x, int y) |
| Sets the location to display the popup. | |
| const Skin & | getSkin () const |
| Returns the Skin used by this popup. | |
Public Member Functions inherited from Container | |
| Container () | |
| ~Container () override | |
| void | drawFrame (gcn::Graphics *graphics) override |
Private Member Functions | |
| void | setSelectedEmoteId (int emoteId) |
| Sets the index of the currently selected emote. | |
| int | getIndexAt (int x, int y) const |
| Returns the index at the specified coordinates. | |
| void | recalculateSize () |
| Determine and set the size of the container. | |
| void | distributeValueChangedEvent () |
| Sends out selection events to the list of selection listeners. | |
Private Attributes | |
| int | mSelectedEmoteId = -1 |
| int | mHoveredEmoteIndex = -1 |
| int | mRowCount = 1 |
| int | mColumnCount = 1 |
| std::list< gcn::SelectionListener * > | mListeners |
Additional Inherited Members | |
Static Public Member Functions inherited from Popup | |
| static void | setWindowContainer (WindowContainer *windowContainer) |
| Sets the window container to be used by new popups. | |
Protected Member Functions inherited from Container | |
| Layout & | getLayout () |
| Gets the layout handler for this container. | |
| LayoutCell & | place (int x, int y, gcn::Widget *wg, int w=1, int h=1) |
| Adds a widget to the container and sets it at given cell. | |
| ContainerPlacer | getPlacer (int x, int y) |
| Returns a proxy for adding widgets in an inner table of the layout. | |
An emote popup.
Used to activate emotes and assign them to shortcuts.
Definition at line 42 of file emotepopup.h.
| EmotePopup::EmotePopup | ( | ) |
|
overridedefault |
|
inline |
Adds a listener to the list that's notified each time a change to the selection occurs.
Definition at line 70 of file emotepopup.h.
|
private |
Sends out selection events to the list of selection listeners.
Definition at line 188 of file emotepopup.cpp.
|
override |
Draws the emotes.
Definition at line 47 of file emotepopup.cpp.
|
private |
Returns the index at the specified coordinates.
Returns -1 when there is no valid index.
Definition at line 137 of file emotepopup.cpp.
| int EmotePopup::getSelectedEmoteId | ( | ) | const |
Returns the selected emote.
Definition at line 123 of file emotepopup.cpp.
|
override |
Definition at line 94 of file emotepopup.cpp.
|
override |
Definition at line 116 of file emotepopup.cpp.
|
override |
Definition at line 101 of file emotepopup.cpp.
|
private |
Determine and set the size of the container.
Definition at line 169 of file emotepopup.cpp.
|
inline |
Removes a listener from the list that's notified each time a change to the selection occurs.
Definition at line 79 of file emotepopup.h.
|
private |
Sets the index of the currently selected emote.
Definition at line 128 of file emotepopup.cpp.
|
private |
Definition at line 110 of file emotepopup.h.
|
private |
Definition at line 107 of file emotepopup.h.
|
private |
Definition at line 112 of file emotepopup.h.
|
private |
Definition at line 109 of file emotepopup.h.
|
private |
Definition at line 106 of file emotepopup.h.