MAK Data Logger API Documentation for HLA
Home
Modules
Namespaces
Classes
Files
Examples
Libraries
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
lgrGui
lgrDataViewComponent.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 1992-2012 VT MAK
3
** All rights reserved.
4
******************************************************************************/
5
8
9
#pragma once
10
11
#include <
lgrGui/lgrGui.h
>
12
#include <
lgrGui/lgrGuiComponent.h
>
13
#include <
lgrCore/lgrDataViewSet.h
>
14
15
#include <
lgrCore/lgrEditorInterface.h
>
16
17
#include <vlutil/vlTime.h>
18
19
class
DtMutex;
20
21
namespace
MAKLogger
22
{
23
class
DtLgrGuiModel;
24
class
DtProgressiveLineGraph;
25
26
class
DT_DLL_LGRGUI
DtLgrDataViewComponent
:
public
DtLgrGuiComponent
27
{
28
Q_OBJECT
29
public
:
30
32
DtLgrDataViewComponent
(
DtLgrGuiModel
& model,
const
QString& name);
33
35
virtual
~
DtLgrDataViewComponent
();
36
38
virtual
void
update();
39
44
virtual
double
updateTime();
45
47
virtual
QWidget
* initialize(
QWidget
* parent);
48
50
virtual
void
activate();
51
53
virtual
void
deactivate();
54
58
virtual
DtLgrZoomableWidget
* zoomComponent();
59
61
virtual
void
updateExportData(
DtLgrDataViewSetSP
set
);
62
64
virtual
void
addRunningData(
const
DtLgrDataViewSet
&
set
);
65
67
virtual
DtLgrDataViewSetSP
getExportData();
68
71
virtual
bool
getRunningData(
DtLgrDataViewSet
& outputSet);
72
74
virtual
void
reloadFile();
75
76
virtual
QWidget
* graph();
77
78
virtual
void
enableZoom();
79
80
81
public
:
82
83
// When updating last time, slice a bit off so that we don't export a partial of a time increment.
84
static
DtRelativeTime
theSliceLast
;
85
86
// When updating first time, pad with a very small interval to skip over any time already exported.
87
static
DtRelativeTime
thePadFirst
;
88
89
public
slots:
90
92
virtual
void
reloadFile(QString fileName);
93
95
virtual
void
reloadFile(
const
DtLgrEditorInterface::FileDataOperations
& fileOp );
96
98
virtual
void
syncRunningData(
DtLgrGuiModel
&);
99
101
virtual
void
syncExpandingData(
DtLgrGuiModel
&);
102
103
protected
:
104
106
virtual
void
syncData();
107
109
void
toggleRunningData(
const
bool
& running);
110
112
void
lastTimeChanged(
const
DtAbsoluteTime
& lastTime);
113
115
void
jumpTimeChanged(
const
DtAbsoluteTime
& jumpTime);
116
118
void
fileExpandingChanged(
const
bool
& isExpanding);
119
121
void
followExportIntervalChanged(
const
double
& interval);
122
125
void
updateCurrentSet(
const
DtString
& exportType);
126
128
virtual
void
adjustValue(
unsigned
long
& value,
const
DtLgrDataViewSet::DataPoint
& dataPoint);
129
131
virtual
double
updateGraph(
const
DtLgrDataViewSet
& aSet,
double
firstVisibleTime,
132
double
lastVisibleTime);
133
135
void
cancelUpdateCurrentSet(
const
DtString
& exportType);
136
137
protected
:
138
139
DtLgrGuiModel
*
myModel
;
140
141
DtProgressiveLineGraph
*
myGraph
;
142
QWidget
*
myMainWidget
;
143
DtMutex*
myDataMutex
;
144
DtMutex*
myRunningMutex
;
145
DtString
myExporteraName
;
146
147
bool
myDataOutOfSyncFlag
;
148
bool
myWaitingForDataFlag
;
149
bool
myActivatedFlag
;
150
bool
myRecording
;
151
bool
myFileLoading
;
152
bool
myJumpPending
;
153
154
DtAbsoluteTime
myUpdateFirstTime
;
155
DtAbsoluteTime
myUpdateLastTime
;
156
DtAbsoluteTime
myLastTimeChange
;
157
DtAbsoluteTime
myPreviousFirstTime
;
158
DtAbsoluteTime
myPreviousLastTime
;
159
DtAbsoluteTime
myJumpTime
;
160
161
DtTime
myNextExportTime
;
162
163
// Only safely accessed via the updateDataAcrossThread and currentDataSet functions.
164
DtLgrDataViewSetSP
myExportedDataSet
;
165
DtLgrDataViewSet
*
myRunningDataSet
;
166
DtLgrDataViewSet
*
myCompleteDataSet
;
167
size_t
myRunningDataIndex
;
168
bool
myIsExpanding
;
169
170
// When file is expanding, the file is exported this amount of time
171
DtTime
myExportInterval
;
172
173
DtClock
myClock
;
174
175
176
protected
:
177
178
static
const
int
Graph_Updates = 0;
179
static
const
int
Graph_Interactions = 1;
180
static
const
int
Graph_Checkpoints = 2;
181
182
};
183
184
}
185
Document ID: Generated on Wed Jun 5 18:45:18 EDT 2019 from SVN revision 198968
Copyright © 2019 VT MAK. All Rights Reserved (
www.mak.com
)