ALBA
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
albaGUIButton Class Reference

#include <albaGUIButton.h>

Inheritance diagram for albaGUIButton:
Inheritance graph
[legend]
Collaboration diagram for albaGUIButton:
Collaboration graph
[legend]

Public Member Functions

 albaGUIButton (wxWindow *parent, wxWindowID id, const wxString &label, const wxPoint &pos, const wxSize &size=wxDefaultSize, long style=0)
 
 albaGUIButton (wxWindow *parent, wxWindowID id=0)
 
void SetListener (albaObserver *listener)
 

Protected Member Functions

virtual void Command (wxCommandEvent &event)
 
void OnSetFocus (wxFocusEvent &event)
 

Protected Attributes

int m_Id
 
albaObserverm_Listener
 

Detailed Description

albaGUIButton inherit from wxButton.

It override SetDefault and SetFocus to prevent the button to display the frame typical of the selected buttons.

albaGUIButton is able to send both wxWindows messages and albaEvents. albaEvents are sent if m_Listener in not NULL otherwise wxWindows messages are sent.

Definition at line 34 of file albaGUIButton.h.

Constructor & Destructor Documentation

◆ albaGUIButton() [1/2]

albaGUIButton::albaGUIButton ( wxWindow *  parent,
wxWindowID  id,
const wxString &  label,
const wxPoint &  pos,
const wxSize &  size = wxDefaultSize,
long  style = 0 
)

◆ albaGUIButton() [2/2]

albaGUIButton::albaGUIButton ( wxWindow *  parent,
wxWindowID  id = 0 
)

Member Function Documentation

◆ SetListener()

void albaGUIButton::SetListener ( albaObserver listener)
inline

Set the Listener that will receive event-notification.

Definition at line 44 of file albaGUIButton.h.

◆ Command()

virtual void albaGUIButton::Command ( wxCommandEvent &  event)
protectedvirtual

Overriden function member to intercept event generation and forward it to the Listener.

◆ OnSetFocus()

void albaGUIButton::OnSetFocus ( wxFocusEvent &  event)
inlineprotected

Called when the button take the focus.

Definition at line 52 of file albaGUIButton.h.

Member Data Documentation

◆ m_Id

int albaGUIButton::m_Id
protected

Definition at line 54 of file albaGUIButton.h.

◆ m_Listener

albaObserver* albaGUIButton::m_Listener
protected

Definition at line 55 of file albaGUIButton.h.


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