28 |
|
|
29 |
#include "pgslider.h" |
#include "pgslider.h" |
30 |
#include "pgapplication.h" |
#include "pgapplication.h" |
31 |
|
#include "pgtheme.h" |
32 |
|
|
33 |
PG_Slider::PG_Slider(PG_Widget* parent, int id, const PG_Rect& r, int direction, const char* style) : PG_ScrollBar(parent, id, r, direction) { |
PG_Slider::PG_Slider(PG_Widget* parent, int id, const PG_Rect& r, ScrollDirection direction, const char* style) : PG_ScrollBar(parent, id, r, direction) { |
34 |
|
|
35 |
my_showButtons = false; |
my_showButtons = false; |
36 |
|
|
37 |
if(sb_direction == PG_SB_VERTICAL) { |
if(sb_direction == VERTICAL) { |
38 |
my_sliderSize = r.my_width; |
my_sliderSize = r.my_width; |
39 |
position[3].h = r.my_width; |
position[3].h = r.my_width; |
40 |
} else { |
} else { |
80 |
|
|
81 |
//PG_ScrollBar::LoadThemeStyle(widgettype); |
//PG_ScrollBar::LoadThemeStyle(widgettype); |
82 |
|
|
83 |
if(sb_direction == PG_SB_VERTICAL) { |
if(sb_direction == VERTICAL) { |
84 |
t->GetProperty(widgettype, "SliderDragV", "height", position[3].h); |
t->GetProperty(widgettype, "SliderDragV", "height", position[3].h); |
85 |
my_sliderSize = position[3].h; |
my_sliderSize = position[3].h; |
86 |
|
|
96 |
|
|
97 |
dragbutton->LoadThemeStyle(widgettype, "SliderDrag"); |
dragbutton->LoadThemeStyle(widgettype, "SliderDrag"); |
98 |
|
|
99 |
if(sb_direction == PG_SB_VERTICAL) { |
if(sb_direction == VERTICAL) { |
100 |
dragbutton->LoadThemeStyle(widgettype, "SliderDragV"); |
dragbutton->LoadThemeStyle(widgettype, "SliderDragV"); |
101 |
PG_ThemeWidget::LoadThemeStyle(widgettype, "SliderV"); |
PG_ThemeWidget::LoadThemeStyle(widgettype, "SliderV"); |
102 |
} else { |
} else { |
143 |
position[2].h = h; |
position[2].h = h; |
144 |
} |
} |
145 |
|
|
146 |
if(sb_direction == PG_SB_VERTICAL) { |
if(sb_direction == VERTICAL) { |
147 |
position[3].h = my_sliderSize; |
position[3].h = my_sliderSize; |
148 |
} else { |
} else { |
149 |
position[3].w = my_sliderSize; |
position[3].w = my_sliderSize; |