ManaPlus
Public Member Functions
AwayListener Class Reference

#include <awaylistener.h>

Inheritance diagram for AwayListener:
ActionListener

Public Member Functions

 AwayListener ()
 
void action (const ActionEvent &event)
 
- Public Member Functions inherited from ActionListener
virtual ~ActionListener ()
 

Additional Inherited Members

- Protected Member Functions inherited from ActionListener
 ActionListener ()
 

Detailed Description

Definition at line 29 of file awaylistener.h.

Constructor & Destructor Documentation

◆ AwayListener()

AwayListener::AwayListener ( )
inline

Definition at line 32 of file awaylistener.h.

33  { }

Member Function Documentation

◆ action()

void AwayListener::action ( const ActionEvent actionEvent)
virtual

Called when an action is recieved from a widget. It is used to be able to recieve a notification that an action has occured.

Parameters
actionEventThe event of the action.

Implements ActionListener.

Definition at line 37 of file awaylistener.cpp.

38 {
39  if (event.getId() == "ok" &&
40  localPlayer != nullptr &&
42  {
45  if (outfitWindow != nullptr)
48  }
49 }
static void changeAwayMode(const bool forward)
void updateStatus() const
void unwearAwayOutfit()
bool awayMode
Definition: settings.h:158
LocalPlayer * localPlayer
OutfitWindow * outfitWindow
Settings settings
Definition: settings.cpp:32

References Settings::awayMode, GameModifiers::changeAwayMode(), UpdateStatusListener::distributeEvent(), ActionEvent::getId(), localPlayer, outfitWindow, settings, OutfitWindow::unwearAwayOutfit(), and LocalPlayer::updateStatus().


The documentation for this class was generated from the following files: