]> git.saurik.com Git - wxWidgets.git/blame - include/wx/generic/scrolwin.h
No real changes, just make wxWindow::CanScroll() virtual.
[wxWidgets.git] / include / wx / generic / scrolwin.h
CommitLineData
c801d85f 1/////////////////////////////////////////////////////////////////////////////
8614c467 2// Name: wx/generic/scrolwin.h
29e1398f
VZ
3// Purpose: generic wxScrollHelper
4// Author: Vadim Zeitlin
5// Created: 2008-12-24 (replacing old file with the same name)
29e1398f 6// Copyright: (c) 2008 Vadim Zeitlin <vadim@wxwidgets.org>
65571936 7// Licence: wxWindows licence
c801d85f
KB
8/////////////////////////////////////////////////////////////////////////////
9
8614c467
VZ
10#ifndef _WX_GENERIC_SCROLLWIN_H_
11#define _WX_GENERIC_SCROLLWIN_H_
c801d85f 12
8614c467 13// ----------------------------------------------------------------------------
29e1398f 14// generic wxScrollHelper implementation
8614c467
VZ
15// ----------------------------------------------------------------------------
16
29e1398f
VZ
17class WXDLLIMPEXP_CORE wxScrollHelper : public wxScrollHelperBase
18{
19public:
20 wxScrollHelper(wxWindow *winToScroll);
c801d85f 21
29e1398f
VZ
22 // implement base class pure virtuals
23 virtual void AdjustScrollbars();
24
bc448be3 25protected:
29e1398f
VZ
26 virtual void DoScroll(int x, int y);
27 virtual void DoShowScrollbars(wxScrollbarVisibility horz,
28 wxScrollbarVisibility vert);
29
bc448be3 30private:
29e1398f
VZ
31 // helper of AdjustScrollbars(): does the work for the single scrollbar
32 //
33 // notice that the parameters passed by non-const references are modified
34 // by this function
35 void DoAdjustScrollbar(int orient,
36 int clientSize,
37 int virtSize,
1ddb6d28 38 int pixelsPerUnit,
29e1398f
VZ
39 int& scrollUnits,
40 int& scrollPosition,
1ddb6d28 41 int& scrollLinesPerPage,
29e1398f
VZ
42 wxScrollbarVisibility visibility);
43
44
45 wxScrollbarVisibility m_xVisibility,
46 m_yVisibility;
47
c0c133e1 48 wxDECLARE_NO_COPY_CLASS(wxScrollHelper);
29e1398f 49};
8614c467 50
77df51f4 51#endif // _WX_GENERIC_SCROLLWIN_H_
566d84a7 52