// Modified by:
// Created: 30.08.00
// RCS-ID: $Id$
-// Copyright: (c) 2000 SciTech Software, Inc. (www.scitechsoft.com)
+// Copyright: (c) 2000 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
#define _WX_UNIV_LISTBOX_H_
#ifdef __GNUG__
- #pragma implementation "listbox.h"
+ #pragma interface "univlistbox.h"
#endif
#include "wx/scrolwin.h" // for wxScrollHelper
+#include "wx/dynarray.h"
// ----------------------------------------------------------------------------
// the actions supported by this control
// wxListBox: a list of selectable items
// ----------------------------------------------------------------------------
-class wxListBox : public wxListBoxBase, public wxScrollHelper
+class WXDLLEXPORT wxListBox : public wxListBoxBase, public wxScrollHelper
{
public:
// ctors and such
void Activate(int item = -1);
// select or unselect the specified or current (if -1) item
- void Select(bool sel = TRUE, int item = -1);
+ void DoSelect(int item = -1, bool sel = TRUE);
// more readable wrapper
- void Unselect(int item) { Select(FALSE, item); }
+ void DoUnselect(int item) { DoSelect(item, FALSE); }
// select an item and send a notification about it
void SelectAndNotify(int item);
// let wxColourScheme choose the right colours for us
virtual bool IsContainerWindow() const { return TRUE; }
+ // idle processing
+ virtual void OnInternalIdle();
protected:
// geometry
virtual wxSize DoGetBestClientSize() const;
void Init();
// event handlers
- void OnIdle(wxIdleEvent& event);
void OnSize(wxSizeEvent& event);
// common part of Clear() and DoSetItems(): clears everything
bool toggleOnPressAlways = TRUE);
// base class methods
- virtual bool HandleKey(wxControl *control,
+ virtual bool HandleKey(wxInputConsumer *consumer,
const wxKeyEvent& event,
bool pressed);
- virtual bool HandleMouse(wxControl *control,
+ virtual bool HandleMouse(wxInputConsumer *consumer,
const wxMouseEvent& event);
- virtual bool HandleMouseMove(wxControl *control,
+ virtual bool HandleMouseMove(wxInputConsumer *consumer,
const wxMouseEvent& event);
protected: