VR-Forces 4.3.1 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
timeEntryWidget.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2012 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
10 
11 #pragma once
12 
14 
15 class QTimeEdit;
16 class QLabel;
17 class QSpinBox;
18 class QHBoxLayout;
19 class QLineEdit;
20 class QIntValidator;
21 
22 namespace makVrf
23 {
26  {
27  Q_OBJECT
28 
29  public:
30  DtTimeEntryWidget(makVrv::DtDe& de, QWidget* parent, const Qt::WindowFlags& flags = 0);
31 
32  //DTOR
33  virtual ~DtTimeEntryWidget();
34 
36  virtual void setLabel(const std::string&);
37 
39  virtual void setRange(double bottom, double top);
40 
42  virtual void setDayShown(bool);
43 
46  virtual void setDefaultValue(const std::string&);
47 
49  virtual void setVariableData(const std::string&);
50 
52  virtual void setSecondsOnlyMode(bool);
53 
55  virtual DtReaderWriter* createBoundVariable(const std::string& variableName);
56 
58  virtual void setupFromBoundVariable(const DtReaderWriter* variableName);
59 
61  virtual void setTimeInSeconds(int);
62  virtual int timeInSeconds() const;
63 
64  static makVrv::DtUnicode codeVariableType()
65  {
66  return makVrv::DtUnicode::tr("Integer Unit: seconds");
67  }
68 
70  boost::signal<void ()> signal_changed;
71 
72  protected slots:
73  virtual void onTimeChanged();
74 
75  protected:
77  virtual void parseTime(const std::string& s, int& days, int& hours, int& minutes, int& seconds) const;
78 
79  public:
81  QTimeEdit* myTime;
83  QIntValidator* myIntValidator;
85  QHBoxLayout* myContentLayout;
87  bool myDayShown;
88  };
89 
91 }

Document ID: Generated on Wed Jul 29 00:55:00 EDT 2015 from SVN revision 155257
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)