VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DtSliderSpinboxWidget.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright (c) 2013 MAK Technologies, Inc.
3  * All rights reserved.
4  ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCoreQt/vrvCoreQt.h>
13 
14 #include <QtGui/QWidget>
15 
16 class QEvent;
17 class QHBoxLayout;
18 class QHideEvent;
19 class QShowEvent;
20 class QSlider;
21 class QSpinBox;
22 
23 
24 namespace makVrv
25 {
31  {
32  Q_OBJECT
33 
34  public:
40  DtSliderSpinboxWidget(int maxValue, int minValue = 0,
41  QWidget* parent = NULL, Qt::WindowFlags flags = Qt::Widget);
42 
44  virtual ~DtSliderSpinboxWidget();
45 
49 
53  virtual void setValue(int value);
54 
57  virtual int value() const;
58 
62  virtual void setMaxAndMin(int maxValue, int minValue);
63 
65  virtual int maximum() const;
66 
68  virtual int minimum() const;
69 
70  virtual void setSingleStep(int step);
71 
73 
77 
80  QHBoxLayout* mainLayout();
81 
84  QSlider* sliderWidget();
85 
88  QSpinBox* spinboxWidget();
89 
91 
92 
93  signals:
96  void valueChanged(int value);
97 
98  protected slots:
99 
103 
104  virtual void onSliderValueChanged(int value);
105  virtual void onSpinnerValueChanged(int value);
106 
108 
109  protected:
110 
114 
117  virtual void changeEvent(QEvent* evt);
118 
122  virtual void showEvent(QShowEvent* evt);
123  virtual void hideEvent(QHideEvent* evt);
125 
127 
128  private:
131  void setupGui();
132 
135  void connectToSignals();
136 
137  protected:
138  QHBoxLayout* myLayout;
139  QSlider* mySlider;
141 
144  };
145 
146 }

Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)