ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

Widget with a dragged slider for twisting the volume. More...

#include <settingsmenu.h>

Inheritance diagram for Stark::VolumeWidget:
Collaboration diagram for Stark::VolumeWidget:

List of all members.

Public Member Functions

 VolumeWidget (const char *renderEntryName, Cursor *cursor, TestSoundManager &soundManager, int soundIndex, Settings::IntSettingIndex settingIndex, WidgetOnMouseMoveCallback *onMouseMoveCallback)
virtual ~VolumeWidget ()
void render () override
 Draw the widget.
bool isMouseInside (const Common::Point &mousePos) const override
 Is the specified point inside the widget?
void onClick () override
 Called when the widget is clicked.
void onMouseMove (const Common::Point &mousePos) override
 Called when the mouse hovers the widget.
void onMouseUp () override
 Called when the mouse's left button just gets up.

Private Member Functions

bool isMouseInsideBg (const Common::Point &mousePos) const
int volumeToX (int volume)
int xToVolume (int x)

Private Attributes

VisualImageXMG_sliderImage
VisualImageXMG_bgImage
Cursor_cursor
TestSoundManager_soundManager
const int _soundIndex
Common::Point _sliderPosition
Common::Point _bgPosition
int _bgWidth
int _bgHeight
int _sliderWidth
int _minX
int _maxX
bool _isDragged
const Settings::IntSettingIndex _settingIndex

Static Private Attributes

static const uint32 _textColorBgHovered = 0xFFFFFFFF
static const int _maxVolume = 256

Detailed Description

Widget with a dragged slider for twisting the volume.

Definition at line 143 of file settingsmenu.h.


Constructor & Destructor Documentation

Stark::VolumeWidget::VolumeWidget ( const char *  renderEntryName,
Cursor cursor,
TestSoundManager soundManager,
int  soundIndex,
Settings::IntSettingIndex  settingIndex,
WidgetOnMouseMoveCallback onMouseMoveCallback 
)

Definition at line 274 of file settingsmenu.cpp.

virtual Stark::VolumeWidget::~VolumeWidget (  )  [inline, virtual]

Definition at line 149 of file settingsmenu.h.


Member Function Documentation

bool Stark::VolumeWidget::isMouseInside ( const Common::Point mousePos  )  const [override, virtual]

Is the specified point inside the widget?

Reimplemented from Stark::StaticLocationWidget.

Definition at line 309 of file settingsmenu.cpp.

bool Stark::VolumeWidget::isMouseInsideBg ( const Common::Point mousePos  )  const [private]

Definition at line 343 of file settingsmenu.cpp.

void Stark::VolumeWidget::onClick (  )  [override, virtual]

Called when the widget is clicked.

Reimplemented from Stark::StaticLocationWidget.

Definition at line 313 of file settingsmenu.cpp.

void Stark::VolumeWidget::onMouseMove ( const Common::Point mousePos  )  [override, virtual]

Called when the mouse hovers the widget.

Reimplemented from Stark::StaticLocationWidget.

Definition at line 320 of file settingsmenu.cpp.

void Stark::VolumeWidget::onMouseUp (  )  [override, virtual]

Called when the mouse's left button just gets up.

Reimplemented from Stark::StaticLocationWidget.

Definition at line 339 of file settingsmenu.cpp.

void Stark::VolumeWidget::render (  )  [override, virtual]

Draw the widget.

Reimplemented from Stark::StaticLocationWidget.

Definition at line 300 of file settingsmenu.cpp.

int Stark::VolumeWidget::volumeToX ( int  volume  )  [inline, private]

Definition at line 178 of file settingsmenu.h.

int Stark::VolumeWidget::xToVolume ( int  x  )  [inline, private]

Definition at line 182 of file settingsmenu.h.


Member Data Documentation

Definition at line 171 of file settingsmenu.h.

Definition at line 163 of file settingsmenu.h.

Definition at line 170 of file settingsmenu.h.

Definition at line 171 of file settingsmenu.h.

Definition at line 165 of file settingsmenu.h.

Definition at line 173 of file settingsmenu.h.

const int Stark::VolumeWidget::_maxVolume = 256 [static, private]

Definition at line 160 of file settingsmenu.h.

Definition at line 171 of file settingsmenu.h.

Definition at line 171 of file settingsmenu.h.

Definition at line 162 of file settingsmenu.h.

Definition at line 171 of file settingsmenu.h.

const int Stark::VolumeWidget::_soundIndex [private]

Definition at line 168 of file settingsmenu.h.

const uint32 Stark::VolumeWidget::_textColorBgHovered = 0xFFFFFFFF [static, private]

Definition at line 159 of file settingsmenu.h.


The documentation for this class was generated from the following files:


Generated on Sat Jan 12 2019 05:05:12 for ResidualVM by doxygen 1.7.1
curved edge   curved edge