ALBA
albaGUIComboBox.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: ALBA (Agile Library for Biomedical Applications)
4 Module: albaGUIComboBox
5 Authors: Daniele Giunchi
6
7 Copyright (c) BIC
8 All rights reserved. See Copyright.txt or
9
10
11 This software is distributed WITHOUT ANY WARRANTY; without even
12 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
13 PURPOSE. See the above copyright notice for more information.
14
15=========================================================================*/
16#ifndef __albaGUIComboBox_H__
17#define __albaGUIComboBox_H__
18//----------------------------------------------------------------------------
19// Include:
20//----------------------------------------------------------------------------
21#include <wx/laywin.h>
22#include <wx/listctrl.h>
23#include "albaEvent.h"
24#include "albaObserver.h"
25#include "albaGUIPanel.h"
26
27//----------------------------------------------------------------------------
28// albaGUIComboBox :
33//----------------------------------------------------------------------------
34
35class ALBA_EXPORT albaGUIComboBox: public wxComboBox
36{
37public:
38 albaGUIComboBox(wxWindow* parent,
39 wxWindowID id,
40 wxArrayString array,
41 const wxPoint& pos = wxDefaultPosition,
42 const wxSize& size = wxDefaultSize,
43 long style = wxTAB_TRAVERSAL | wxCLIP_CHILDREN);
44
46
47 void SetListener(albaObserver *listener){m_Listener = listener;}
48#ifdef WIN32
49 /*virtual*/ bool MSWCommand(WXUINT param, WXWORD id);
50#endif
51 /*virtual*/ void SetSelection(int n);
52
53protected:
54
57 DECLARE_EVENT_TABLE()
58};
59#endif
a ListBox that send albaEventNotification in the form albaEvent(this, widget_id, item_id,...
void SetSelection(int n)
albaObserver * m_Listener
virtual ~albaGUIComboBox()
albaGUIComboBox(wxWindow *parent, wxWindowID id, wxArrayString array, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL|wxCLIP_CHILDREN)
void SetListener(albaObserver *listener)
Interface implementing the Observer of the Subject/Observer design pattern.
Definition: albaObserver.h:36