libyui  3.10.0
YSlider.cc
1 /*
2  Copyright (C) 2000-2012 Novell, Inc
3  This library is free software; you can redistribute it and/or modify
4  it under the terms of the GNU Lesser General Public License as
5  published by the Free Software Foundation; either version 2.1 of the
6  License, or (at your option) version 3.0 of the License. This library
7  is distributed in the hope that it will be useful, but WITHOUT ANY
8  WARRANTY; without even the implied warranty of MERCHANTABILITY or
9  FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
10  License for more details. You should have received a copy of the GNU
11  Lesser General Public License along with this library; if not, write
12  to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
13  Floor, Boston, MA 02110-1301 USA
14 */
15 
16 
17 /*-/
18 
19  File: YSlider.cc
20 
21  Author: Stefan Hundhammer <sh@suse.de>
22 
23 /-*/
24 
25 
26 #define YUILogComponent "ui"
27 #include "YUILog.h"
28 
29 #include "YSlider.h"
30 
31 using std::string;
32 
33 
35 {
37  {}
38 
39  bool dummy;
40 };
41 
42 
43 
44 
46  const string & label,
47  int minValue,
48  int maxValue )
49  : YIntField( parent, label, minValue, maxValue )
50  , priv( new YSliderPrivate() )
51 {
52  YUI_CHECK_NEW( priv );
53 
54  setDefaultStretchable( YD_HORIZ, true );
55  setStretchable( YD_VERT, false );
56 }
57 
58 
60 {
61  // NOP
62 }
63 
64 
65 //
66 // Property documentation - all inherited from YIntField:
67 //
68 
69 /*
70  * @property integer Value the slider value
71  * @property integer MinValue the minimum value
72  * @property integer MaxValue the maximum value
73  * @property string Label caption above the slider
74  */
YWidget
Abstract base class of all UI widgets.
Definition: YWidget.h:54
YSlider::~YSlider
virtual ~YSlider()
Destructor.
Definition: YSlider.cc:59
YWidget::setStretchable
void setStretchable(YUIDimension dim, bool newStretch)
Set the stretchable state to "newStretch" regardless of any hstretch or vstretch options.
Definition: YWidget.cc:560
YIntField
IntField: Input field for integer values.
Definition: YIntField.h:38
YWidget::setDefaultStretchable
void setDefaultStretchable(YUIDimension dim, bool newStretch)
Set the stretchable state to "newStretch".
Definition: YWidget.cc:566
YSliderPrivate
Definition: YSlider.cc:34
YSlider::YSlider
YSlider(YWidget *parent, const std::string &label, int minValue, int maxValue)
Constructor.
Definition: YSlider.cc:45