Exponent::GUI::Controls::CSlider Class Reference

Inheritance diagram for Exponent::GUI::Controls::CSlider:

Exponent::GUI::Controls::CControl Exponent::GUI::Controls::IControl Exponent::GUI::Controls::CScrollBar List of all members.

Detailed Description

Represents a slider.

Date:
19/03/2005
Author:
Paul Chana
Version:
1.0.0 Initial version
Note:
All contents of this source code are copyright 2005 Exp Digital Uk.
This source file is covered by the licence conditions of the Infinity API. You should have recieved a copy
with the source code. If you didnt, please refer to http://www.expdigital.co.uk All content is the Intellectual property of Exp Digital Uk.
Certain sections of this code may come from other sources. They are credited where applicable.
If you have comments, suggestions or bug reports please visit http://support.expdigital.co.uk
Id
CSlider.hpp,v 1.6 2007/02/08 21:07:54 paul Exp

Definition at line 39 of file CSlider.hpp.

Public Member Functions

Protected Member Functions

Protected Attributes


Constructor & Destructor Documentation

Exponent::GUI::Controls::CSlider::CSlider ( IControlRoot root,
const long  uniqueId,
const CRect &  area,
IActionListener *  listener = NULL 
)

Construction

Parameters:
root The root control that this control is being added to
uniqueId The unique Identifier of this control or CCONTROL_NO_ID_REQUIRED if no id is required
area The area of this control relative to the root controls top left
listener The action listener

virtual Exponent::GUI::Controls::CSlider::~CSlider (  )  [virtual]

Destruction


Member Function Documentation

virtual void Exponent::GUI::Controls::CSlider::checkAndLock ( const CPoint &  point  )  [protected, virtual]

Check if the area is rolled over and lock if it is

Parameters:
point The point to check

virtual void Exponent::GUI::Controls::CSlider::drawControl ( CGraphics &  graphics  )  [virtual]

Draw the controls

Parameters:
graphics The graphics context

Reimplemented from Exponent::GUI::Controls::CControl.

Reimplemented in Exponent::GUI::Controls::CScrollBar.

virtual bool Exponent::GUI::Controls::CSlider::drawEnabledControl ( CGraphics &  graphics  )  [protected, virtual]

Check if the control is enabled. If it isnt, draw the disabled background and return

Parameters:
graphics The graphics context
Return values:
bool TRue if should draw, false if disabled / shouldnt draw

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::handleLeftButtonDown ( CMouseEvent &  event  )  [virtual]

Handle left button being clicked

Parameters:
event The event to handle

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::handleLeftButtonUp ( CMouseEvent &  event  )  [virtual]

Handle left button being released

Parameters:
event The event to handle

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::handleMouseLeavingArea ( CMouseEvent &  event  )  [virtual]

Handle the mouse leaving the window area

Parameters:
event The event to handle

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::handleMouseMovement ( CMouseEvent &  event  )  [virtual]

Handle the mouse movement

Parameters:
event The event to handle

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::handleMouseScroll ( CMouseEvent &  event  )  [virtual]

Handle the scroll wheel

Parameters:
event The event to handle

Reimplemented from Exponent::GUI::Controls::CControl.

virtual void Exponent::GUI::Controls::CSlider::setColours ( CAlphaColour  frameColour,
CAlphaColour  backgroundColour,
CAlphaColour  handleColour,
CAlphaColour  handleOverColour,
CAlphaColour  handleDownColour 
) [virtual]

Set the colours

Parameters:
frameColour The colour of the frame
backgroundColour The background colour of the control
handleColour The colour of the area that can be grabbed by the user
handleOverColour The colour of the area that can be grabbed by the user when mouse is over
handleDownColour The colour of the area that can be grabbed by the user when mouse is grabbing it

virtual void Exponent::GUI::Controls::CSlider::setSliderImages ( IImage *  sliderHandle,
IImage *  sliderOver,
IImage *  sliderDown,
IImage *  sliderDisabled 
) [virtual]

Set the slider images

Parameters:
sliderHandle The image of the area that can be grabbed by the user
sliderOver The image of the area that can be grabbed by the user when mouse is over
sliderDown The image of the area that can be grabbed by the user when mouse is grabbing it
sliderDisabled The image of the area that can be grabbed by the user when the control is disabled

virtual void Exponent::GUI::Controls::CSlider::setValue ( const double  value  )  [virtual]

Set the value of the slider

Parameters:
value The value of the slider (0 - 1 range)

Reimplemented from Exponent::GUI::Controls::CControl.


Member Data Documentation

CPoint Exponent::GUI::Controls::CSlider::m_grabOffset [protected]

What is the offset to where they grabbed?

Definition at line 159 of file CSlider.hpp.

CAlphaColour Exponent::GUI::Controls::CSlider::m_handleColour [protected]

Colour of the slider

Definition at line 167 of file CSlider.hpp.

CAlphaColour Exponent::GUI::Controls::CSlider::m_handleDownColour [protected]

Colour of the slider when mouse is down

Definition at line 169 of file CSlider.hpp.

CAlphaColour Exponent::GUI::Controls::CSlider::m_handleOverColour [protected]

Colour of the slider when mouse is over

Definition at line 168 of file CSlider.hpp.

bool Exponent::GUI::Controls::CSlider::m_isDragging [protected]

Are we dragging the slider

Definition at line 163 of file CSlider.hpp.

bool Exponent::GUI::Controls::CSlider::m_isVertical [protected]

Is the slider vertical?

Definition at line 162 of file CSlider.hpp.

IImage* Exponent::GUI::Controls::CSlider::m_sliderDisabledImage [protected]

The disabled image

Definition at line 156 of file CSlider.hpp.

IImage* Exponent::GUI::Controls::CSlider::m_sliderDownImage [protected]

The down image

Definition at line 155 of file CSlider.hpp.

IImage* Exponent::GUI::Controls::CSlider::m_sliderHandleImage [protected]

The slider image

Definition at line 153 of file CSlider.hpp.

IImage* Exponent::GUI::Controls::CSlider::m_sliderOverImage [protected]

The over image

Definition at line 154 of file CSlider.hpp.

CRect Exponent::GUI::Controls::CSlider::m_sliderPosition [protected]

The position of the slider

Definition at line 158 of file CSlider.hpp.

double Exponent::GUI::Controls::CSlider::m_sliderRange [protected]

The range of the slider

Definition at line 165 of file CSlider.hpp.

CRolloverButton::ERolloverState Exponent::GUI::Controls::CSlider::m_state [protected]

Current state of slider (0 = off : 1 = over : 2 = on)

Definition at line 161 of file CSlider.hpp.


Infinity API - Exponent::GUI::Controls::CSlider Class Reference generated on 7 Mar 2007