mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-15 05:47:56 -07:00
d14efe561b
long become wxWidgets 2.9.2, which in turn is expected to be the last 2.9 release before the 3.0 stable release. Since the full wxWidgets distribution is rather large, I have imported only the parts that we use, on a subdirectory basis: art include/wx/*.* include/wx/aui include/wx/cocoa include/wx/generic include/wx/gtk include/wx/meta include/wx/msw include/wx/osx include/wx/persist include/wx/private include/wx/protocol include/wx/unix src/aui src/common src/generic src/gtk src/msw src/osx src/unix git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7380 8ced0084-cf51-0410-be5f-012b33b47a6e
76 lines
2.7 KiB
C++
76 lines
2.7 KiB
C++
/////////////////////////////////////////////////////////////////////////////
|
|
// Name: wx/msw/scrolbar.h
|
|
// Purpose: wxScrollBar class
|
|
// Author: Julian Smart
|
|
// Modified by:
|
|
// Created: 01/02/97
|
|
// RCS-ID: $Id: scrolbar.h 67254 2011-03-20 00:14:35Z DS $
|
|
// Copyright: (c) Julian Smart
|
|
// Licence: wxWindows licence
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef _WX_SCROLBAR_H_
|
|
#define _WX_SCROLBAR_H_
|
|
|
|
// Scrollbar item
|
|
class WXDLLIMPEXP_CORE wxScrollBar: public wxScrollBarBase
|
|
{
|
|
public:
|
|
wxScrollBar() { m_pageSize = 0; m_viewSize = 0; m_objectSize = 0; }
|
|
virtual ~wxScrollBar();
|
|
|
|
wxScrollBar(wxWindow *parent, wxWindowID id,
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
const wxSize& size = wxDefaultSize,
|
|
long style = wxSB_HORIZONTAL,
|
|
const wxValidator& validator = wxDefaultValidator,
|
|
const wxString& name = wxScrollBarNameStr)
|
|
{
|
|
Create(parent, id, pos, size, style, validator, name);
|
|
}
|
|
bool Create(wxWindow *parent, wxWindowID id,
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
const wxSize& size = wxDefaultSize,
|
|
long style = wxSB_HORIZONTAL,
|
|
const wxValidator& validator = wxDefaultValidator,
|
|
const wxString& name = wxScrollBarNameStr);
|
|
|
|
int GetThumbPosition() const ;
|
|
int GetThumbSize() const { return m_pageSize; }
|
|
int GetPageSize() const { return m_viewSize; }
|
|
int GetRange() const { return m_objectSize; }
|
|
|
|
virtual void SetThumbPosition(int viewStart);
|
|
virtual void SetScrollbar(int position, int thumbSize, int range, int pageSize,
|
|
bool refresh = true);
|
|
|
|
// needed for RTTI
|
|
void SetThumbSize( int s ) { SetScrollbar( GetThumbPosition() , s , GetRange() , GetPageSize() , true ) ; }
|
|
void SetPageSize( int s ) { SetScrollbar( GetThumbPosition() , GetThumbSize() , GetRange() , s , true ) ; }
|
|
void SetRange( int s ) { SetScrollbar( GetThumbPosition() , GetThumbSize() , s , GetPageSize() , true ) ; }
|
|
|
|
void Command(wxCommandEvent& event);
|
|
virtual bool MSWOnScroll(int orientation, WXWORD wParam,
|
|
WXWORD pos, WXHWND control);
|
|
|
|
// override wxControl version to not use solid background here
|
|
virtual WXHBRUSH MSWControlColor(WXHDC pDC, WXHWND hWnd);
|
|
|
|
virtual WXDWORD MSWGetStyle(long style, WXDWORD *exstyle) const;
|
|
|
|
// returns true if the platform should explicitly apply a theme border
|
|
virtual bool CanApplyThemeBorder() const { return false; }
|
|
|
|
protected:
|
|
virtual wxSize DoGetBestSize() const;
|
|
|
|
int m_pageSize;
|
|
int m_viewSize;
|
|
int m_objectSize;
|
|
|
|
DECLARE_DYNAMIC_CLASS_NO_COPY(wxScrollBar)
|
|
};
|
|
|
|
#endif
|
|
// _WX_SCROLBAR_H_
|