class WXDLLEXPORT wxListItem;
class WXDLLEXPORT wxListEvent;
-#if !defined(__WXMSW__) || defined(__WIN16__) || defined(__WXUNIVERSAL__)
+#if !defined(__WXMSW__) || defined(__WXUNIVERSAL__)
class WXDLLEXPORT wxListCtrl;
#define wxImageListType wxImageList
#else
public:
wxGenericListCtrl();
wxGenericListCtrl( wxWindow *parent,
- wxWindowID id = -1,
+ wxWindowID winid = -1,
const wxPoint &pos = wxDefaultPosition,
const wxSize &size = wxDefaultSize,
long style = wxLC_ICON,
const wxValidator& validator = wxDefaultValidator,
const wxString &name = wxT("listctrl") )
{
- Create(parent, id, pos, size, style, validator, name);
+ Create(parent, winid, pos, size, style, validator, name);
}
~wxGenericListCtrl();
bool Create( wxWindow *parent,
- wxWindowID id = -1,
+ wxWindowID winid = -1,
const wxPoint &pos = wxDefaultPosition,
const wxSize &size = wxDefaultSize,
long style = wxLC_ICON,
bool SortItems( wxListCtrlCompare fn, long data );
bool Update( long item );
- // returns true if it is a virtual list control
- bool IsVirtual() const { return (GetWindowStyle() & wxLC_VIRTUAL) != 0; }
+ // are we in report mode?
+ bool InReportView() const { return HasFlag(wxLC_REPORT); }
+
+ // are we in virtual report mode?
+ bool IsVirtual() const { return HasFlag(wxLC_VIRTUAL); }
+
+ // do we have a header window?
+ bool HasHeader() const
+ { return InReportView() && !HasFlag(wxLC_NO_HEADER); }
// refresh items selectively (only useful for virtual list controls)
void RefreshItem(long item);
wxDEPRECATED( int GetItemSpacing( bool isSmall ) const );
+ virtual wxVisualAttributes GetDefaultAttributes() const
+ {
+ return GetClassDefaultAttributes(GetWindowVariant());
+ }
+
+ static wxVisualAttributes
+ GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
+
// implementation only from now on
// -------------------------------
DECLARE_DYNAMIC_CLASS(wxGenericListCtrl);
};
-#if !defined(__WXMSW__) || defined(__WIN16__) || defined(__WXUNIVERSAL__)
+#if !defined(__WXMSW__) || defined(__WXUNIVERSAL__)
/*
* wxListCtrl has to be a real class or we have problems with
* the run-time information.
public:
wxListCtrl() {}
- wxListCtrl(wxWindow *parent, wxWindowID id = -1,
+ wxListCtrl(wxWindow *parent, wxWindowID winid = -1,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxLC_ICON,
const wxValidator &validator = wxDefaultValidator,
const wxString &name = wxT("listctrl") )
- : wxGenericListCtrl(parent, id, pos, size, style, validator, name)
+ : wxGenericListCtrl(parent, winid, pos, size, style, validator, name)
{
}
};
-#endif // !__WXMSW__ || __WIN16__ || __WXUNIVERSAL__
+#endif // !__WXMSW__ || __WXUNIVERSAL__
#endif // __LISTCTRLH_G__