Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

CGauge Class Reference

#include <Gauges.h>

Inheritance diagram for CGauge:

CStreamObject CObject CBitmapGauge CDigitsReadoutGauge CDualKnobGauge CFlyhawkAnnunciator CFlyhawkAnnunciatorTest CHobbsMeterGauge CIndicatorGauge CKAFireExtinguisherButton CMasterCautionWarningButtonGauge CNavGaugeGroup CPushButtonGauge CPushPullKnobGauge CRadioGaugeGroup CSimpleFloatSwitch CSimpleSwitch CTrimWheelGauge CTurnKnobGauge CVerticalSliderGauge CWalkerAPPanel CWalkerFirePanel List of all members.

Public Member Functions

 CGauge (void)
virtual int Read (SStream *stream, Tag tag)
virtual void ReadFinished (void)
virtual void GetSize (int *x1, int *y1, int *x2, int *y2)
virtual void Update (void)
virtual void Draw (void)
virtual void Blit (int xOffset, int yOffset, int y_isiz)
virtual SSurfaceGetSurface (void)
void ClearSurface (void)
virtual EClickResult MouseClick (int x, int y, int buttons)
virtual EClickResult TrackClick (int x, int y, int buttons)
virtual EClickResult StopClick (int x, int y, int buttons)
virtual ECursorResult MouseMoved (int x, int y)

Static Public Attributes

static int sfx_source = 0

Protected Attributes

Tag type
Tag unid
char unid_s [8]
int x
int y
int w
int h
int cx
int cy
SMessage mesg
float gmin
float gmax
CDataMap gtbl
Tag lite
char mask [64]
bool fore
char curs [64]
Tag cursTag
char help [64]
char dtyp [64]
char dfmt [64]
bool nomc
bool igno
SSurfacesurf
int last_state
float value

Detailed Description

Todo:
Currently this class is not abstract, but the Draw() method should be changed to pure virtual once all of the subclasses have their own Draw() methods defined.

Definition at line 351 of file Gauges.h.


Constructor & Destructor Documentation

CGauge::CGauge void   ) 
 

Definition at line 489 of file Gauges.cpp.

References curs, cx, cy, dfmt, dtyp, fore, GAUGE_BASE, gmax, gmin, h, help, igno, lite, mask, mesg, nomc, surf, type, unid, w, x, and y.


Member Function Documentation

void CGauge::Blit int  xOffset,
int  yOffset,
int  y_isiz
[virtual]
 

Reimplemented in CBasicADFGauge, and CNavigationGauge.

Definition at line 789 of file Gauges.cpp.

References BlitSurface(), and surf.

Referenced by CPanel::Draw().

void CGauge::ClearSurface void   ) 
 

Definition at line 779 of file Gauges.cpp.

References EraseSurface(), and surf.

Referenced by CBKAP140Gauge::Draw(), CBKADFKR87Gauge::Draw(), CBKXPDRKT76Gauge::Draw(), CBKNavComKX155Gauge::Draw(), CNavigationGauge::Draw(), CBasicADFGauge::Draw(), CNeedleGauge::Draw(), CBitmapGauge::Draw(), and Draw().

void CGauge::Draw void   )  [virtual]
 

Reimplemented in CBitmapGauge, CNeedleGauge, CVerticalSpeedGauge, CBasicADFGauge, CDigitsReadoutGauge, CNavigationGauge, CBKNavComKX155Gauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, CBKAP140Gauge, CSimpleInOutStateSwitch, CSimpleSwitch, CBasicBatterySwitch, and CBasicMagnetoSwitch.

Definition at line 784 of file Gauges.cpp.

References ClearSurface().

Referenced by CPanel::Draw().

void CGauge::GetSize int *  x1,
int *  y1,
int *  x2,
int *  y2
[virtual]
 

Definition at line 661 of file Gauges.cpp.

Referenced by CPanel::Draw(), and CPanel::GaugeHit().

SSurface * CGauge::GetSurface void   )  [virtual]
 

Definition at line 670 of file Gauges.cpp.

References surf.

EClickResult CGauge::MouseClick int  x,
int  y,
int  buttons
[virtual]
 

Reimplemented in CBasicADFGauge, CNavigationGauge, CBKNavComKX155Gauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, CSimpleInOutStateSwitch, CSimpleSwitch, CBasicBatterySwitch, and CBasicMagnetoSwitch.

Definition at line 726 of file Gauges.cpp.

References MOUSE_TRACKING_OFF.

Referenced by CPanel::GaugeMouseClick().

ECursorResult CGauge::MouseMoved int  x,
int  y
[virtual]
 

Reimplemented in CAltimeterGauge, CRollingAltimeterGauge, CHorizonGauge, CAirspeedGauge, CVerticalSpeedGauge, CN1TachometerGauge, CFlyhawkDigitalClockGauge, CBasicADFGauge, CCabinPressureRateKnobGauge, CBrakePressureGauge, CAOANeedleGauge, CHSIGauge, CBKNavComKX155Gauge, CBKGPSKLN89Gauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, CBKAP140Gauge, CBKKFC200Gauge, CBKKFC150Gauge, CBKAudioKMA26Gauge, CGenericNavRadioGauge, CGenericCommRadioGauge, CGenericTransponderGauge, CGenericADFRadioGauge, CRMINeedleGauge, CFlyhawkNavGpsPanelGauge, CFlyhawkFuelSelectorGauge, CFlyhawkElevatorTrimGauge, CDMEGauge, CDME2Gauge, CSimpleSwitch, CSwitchPairGauge, CDualKnobGauge, CTrimWheelGauge, and CRockerSwitch.

Definition at line 760 of file Gauges.cpp.

References CURSOR_NOT_CHANGED, CURSOR_WAS_CHANGED, SGlobals::cursormgr, cursTag, globals, and CCursorManager::SetCursor().

Referenced by CPanel::MouseMotion(), CTrimWheelGauge::MouseMoved(), CDualKnobGauge::MouseMoved(), CSimpleSwitch::MouseMoved(), CDME2Gauge::MouseMoved(), CDMEGauge::MouseMoved(), CFlyhawkElevatorTrimGauge::MouseMoved(), CFlyhawkFuelSelectorGauge::MouseMoved(), CFlyhawkNavGpsPanelGauge::MouseMoved(), CRMINeedleGauge::MouseMoved(), CGenericADFRadioGauge::MouseMoved(), CGenericTransponderGauge::MouseMoved(), CGenericCommRadioGauge::MouseMoved(), CGenericNavRadioGauge::MouseMoved(), CBKAudioKMA26Gauge::MouseMoved(), CBKKFC150Gauge::MouseMoved(), CBKKFC200Gauge::MouseMoved(), CBKAP140Gauge::MouseMoved(), CBKGPSKLN89Gauge::MouseMoved(), CBKADFKR87Gauge::MouseMoved(), CBKXPDRKT76Gauge::MouseMoved(), CBKNavComKX155Gauge::MouseMoved(), CHSIGauge::MouseMoved(), CAOANeedleGauge::MouseMoved(), CBrakePressureGauge::MouseMoved(), CCabinPressureRateKnobGauge::MouseMoved(), CBasicADFGauge::MouseMoved(), CFlyhawkDigitalClockGauge::MouseMoved(), CN1TachometerGauge::MouseMoved(), CVerticalSpeedGauge::MouseMoved(), CAirspeedGauge::MouseMoved(), CHorizonGauge::MouseMoved(), CRollingAltimeterGauge::MouseMoved(), and CAltimeterGauge::MouseMoved().

int CGauge::Read SStream stream,
Tag  tag
[virtual]
 

Todo:
Parse user string into SMessage field update

Reimplemented from CStreamObject.

Reimplemented in CBitmapGauge, CNeedleGauge, CTwoNeedleGauge, CThreeNeedleGauge, CDigitalNeedleGauge, CAltimeterGauge, CRollingAltimeterGauge, CHorizonGauge, CFDHorizonGauge, CHorizontalBallGauge, CAirspeedGauge, CVerticalSpeedGauge, CDirectionalGyroGauge, CVacuumGauge, CSuctionGauge, CFuelGauge, CFuelFlowGauge, COilPressureGauge, COilTemperatureGauge, CTachometerGauge, CDualTachometerGauge, CN1TachometerGauge, CExhaustGasTemperatureGauge, CBasicCompassGauge, CAnalogClockGauge, CAmmeterGauge, CFlyhawkDigitalClockGauge, CBasicDigitalClockGauge, CBasicADFGauge, CDigitalReadoutGauge, CDigitsReadoutGauge, CCabinPressureRateKnobGauge, CCabinPressureGauge, CBrakePressureGauge, CAOANeedleGauge, CTurnCoordinatorGauge, CHSIGauge, CFlyhawkELTGauge, CSlipIndicatorGauge, CHobbsMeterGauge, CNavigationGauge, CBKNavComKX155Gauge, CBKGPSKLN89Gauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, CBKAP140Gauge, CBKKFC200Gauge, CBKKFC150Gauge, CBKAudioKMA26Gauge, CGenericNavRadioGauge, CGenericCommRadioGauge, CGenericTransponderGauge, CGenericADFRadioGauge, CRMINeedleGauge, CNavGaugeGroup, CRadioGaugeGroup, CAnnunciator, CFlyhawkAnnunciator, CFlyhawkAnnunciatorTest, CFlyhawkNavGpsPanelGauge, CFlyhawkFuelSelectorGauge, CFlyhawkElevatorTrimGauge, CMalybooCHTIndicatorGauge, CMalybooCHTButtonGauge, CMalybooNavGpsPanelGauge, CMalybooDigitalClockGauge, CMalybooEngineMonitorGauge, CNavajoFuelSelectorGauge, CNavajoAmmeterGauge, CNavajoRadarAltimeterGauge, CCollinsEFISSelectionGauge, CCollinsVspeedPanel, CCollinsHFRadioGauge, CCollinsPFDGauge, CCollinsNDGauge, CCollinsRTUGauge, CCollinsAirDataGauge, CCollinsMNDGauge, CUniversalFMSGauge, CPilatusEFISPanel, CWalkerTempAirspeedGauge, CGyroSlavingGauge, CVerticalRateGauge, CPropSyncGauge, CDMEGauge, CDME2Gauge, CWeatherRadarGauge, CAnalogAltPreselectGauge, CMomentaryHotSpotGauge, CSimpleInOutStateSwitch, CLitInOutSwitch, CSimpleSwitch, CBasicBatterySwitch, CTwoStateELTGauge, CSwitchPairGauge, CSimpleFloatSwitch, CDualSwitch, CPushPullKnobGauge, CPrimerKnobGauge, CFlapsSwitchGauge, CLitLandingGearKnobGauge, CMixtureKnobGauge, CReversibleThrottleKnobGauge, CDualKnobGauge, CFlyhawkLightKnobGauge, CTurnKnobGauge, CCoveredSwitch, CCoveredLightButtonGauge, CVerticalSliderGauge, CTrimWheelGauge, CTrimWheelIndicatorGauge, CIndicatorGauge, CFlapsIndicatorGauge, CPushButtonGauge, CLightButtonGauge, CTurnSwitchGauge, CMasterCautionWarningButtonGauge, CKAFireExtinguisherButton, CWalkerAPPanel, CWalkerFirePanel, CLightSwitchSetGauge, and CRockerSwitch.

Definition at line 509 of file Gauges.cpp.

References curs, cx, cy, dfmt, dtyp, fore, globals, gmax, gmin, SMessage::group, gtbl, h, help, igno, lite, SGlobals::logWarning, mask, mesg, nomc, ReadFloat(), ReadFrom(), ReadInt(), ReadMessage(), ReadString(), ReadTag(), ReadUInt(), TAG_IGNORED, TAG_READ, TagToString(), unid, unid_s, SMessage::user, w, CLogFile::Write(), x, and y.

Referenced by CWalkerFirePanel::Read(), CWalkerAPPanel::Read(), CKAFireExtinguisherButton::Read(), CMasterCautionWarningButtonGauge::Read(), CPushButtonGauge::Read(), CIndicatorGauge::Read(), CTrimWheelGauge::Read(), CVerticalSliderGauge::Read(), CTurnKnobGauge::Read(), CDualKnobGauge::Read(), CPushPullKnobGauge::Read(), CSimpleFloatSwitch::Read(), CSimpleSwitch::Read(), CFlyhawkAnnunciatorTest::Read(), CFlyhawkAnnunciator::Read(), CRadioGaugeGroup::Read(), CNavGaugeGroup::Read(), CHobbsMeterGauge::Read(), CDigitsReadoutGauge::Read(), CDigitalReadoutGauge::Read(), and CBitmapGauge::Read().

void CGauge::ReadFinished void   )  [virtual]
 

Reimplemented from CStreamObject.

Reimplemented in CBitmapGauge, CVerticalSpeedGauge, CBasicADFGauge, CNavigationGauge, CBKNavComKX155Gauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, CGyroSlavingGauge, CSimpleInOutStateSwitch, CSimpleSwitch, CSimpleFloatSwitch, CMasterCautionWarningButtonGauge, CKAFireExtinguisherButton, and CRockerSwitch.

Definition at line 644 of file Gauges.cpp.

References CCursorManager::BindCursor(), CreateSurface(), curs, SGlobals::cursormgr, cursTag, globals, h, surf, w, x, SSurface::xScreen, y, and SSurface::yScreen.

Referenced by CRockerSwitch::ReadFinished(), CKAFireExtinguisherButton::ReadFinished(), CMasterCautionWarningButtonGauge::ReadFinished(), CSimpleFloatSwitch::ReadFinished(), CSimpleInOutStateSwitch::ReadFinished(), CSimpleSwitch::ReadFinished(), and CBitmapGauge::ReadFinished().

EClickResult CGauge::StopClick int  x,
int  y,
int  buttons
[virtual]
 

Reimplemented in CNavigationGauge, CBKXPDRKT76Gauge, CBKADFKR87Gauge, and CBasicMagnetoSwitch.

Definition at line 748 of file Gauges.cpp.

References MOUSE_TRACKING_OFF.

Referenced by CPanel::GaugeStopClick().

EClickResult CGauge::TrackClick int  x,
int  y,
int  buttons
[virtual]
 

Definition at line 739 of file Gauges.cpp.

References MOUSE_TRACKING_ON.

Referenced by CPanel::GaugeTrackClick(), and CPanel::MouseMotion().

void CGauge::Update void   )  [virtual]
 

Definition at line 679 of file Gauges.cpp.

References SMessage::dataType, gmax, gmin, gtbl, SMessage::intData, SMessage::intPtrData, CDataMap::Lookup(), mesg, SMessage::realData, SMessage::realPtrData, SendMessage(), TYPE_CHAR, TYPE_CHARPTR, TYPE_INT, TYPE_INTPTR, TYPE_NONE, TYPE_REAL, TYPE_REALPTR, TYPE_VOID, and value.

Referenced by CNeedleGauge::Draw().


Member Data Documentation

char CGauge::curs[64] [protected]
 

Definition at line 384 of file Gauges.h.

Referenced by CGauge(), CKAFireExtinguisherButton::Read(), CPushButtonGauge::Read(), Read(), and ReadFinished().

Tag CGauge::cursTag [protected]
 

Definition at line 385 of file Gauges.h.

Referenced by MouseMoved(), and ReadFinished().

int CGauge::cx [protected]
 

Definition at line 377 of file Gauges.h.

Referenced by CGauge(), CNavigationGauge::Draw(), CBasicADFGauge::Draw(), CNeedleGauge::Draw(), and Read().

int CGauge::cy [protected]
 

Definition at line 377 of file Gauges.h.

Referenced by CGauge(), CNavigationGauge::Draw(), CBasicADFGauge::Draw(), CNeedleGauge::Draw(), and Read().

char CGauge::dfmt[64] [protected]
 

Definition at line 388 of file Gauges.h.

Referenced by CGauge(), and Read().

char CGauge::dtyp[64] [protected]
 

Definition at line 387 of file Gauges.h.

Referenced by CGauge(), and Read().

bool CGauge::fore [protected]
 

Definition at line 383 of file Gauges.h.

Referenced by CGauge(), and Read().

float CGauge::gmax [protected]
 

Definition at line 379 of file Gauges.h.

Referenced by CGauge(), Read(), and Update().

float CGauge::gmin [protected]
 

Definition at line 379 of file Gauges.h.

Referenced by CGauge(), Read(), and Update().

CDataMap CGauge::gtbl [protected]
 

Definition at line 380 of file Gauges.h.

Referenced by Read(), and Update().

int CGauge::h [protected]
 

Definition at line 376 of file Gauges.h.

Referenced by CGauge(), CBasicBatterySwitch::MouseClick(), CSimpleSwitch::MouseClick(), CSimpleSwitch::MouseMoved(), Read(), and ReadFinished().

char CGauge::help[64] [protected]
 

Definition at line 386 of file Gauges.h.

Referenced by CGauge(), CPushPullKnobGauge::Read(), and Read().

bool CGauge::igno [protected]
 

Definition at line 390 of file Gauges.h.

Referenced by CGauge(), and Read().

int CGauge::last_state [protected]
 

Definition at line 394 of file Gauges.h.

Referenced by CSimpleSwitch::Draw(), and CSimpleSwitch::ReadFinished().

Tag CGauge::lite [protected]
 

Definition at line 381 of file Gauges.h.

Referenced by CGauge(), and Read().

char CGauge::mask[64] [protected]
 

Definition at line 382 of file Gauges.h.

Referenced by CGauge(), and Read().

SMessage CGauge::mesg [protected]
 

Reimplemented in CPushPullKnobGauge.

Definition at line 378 of file Gauges.h.

Referenced by CGauge(), CSimpleSwitch::DecState(), CBasicMagnetoSwitch::Draw(), CSimpleInOutStateSwitch::Draw(), CSimpleSwitch::Draw(), CBKAP140Gauge::Draw(), CBKADFKR87Gauge::Draw(), CBKXPDRKT76Gauge::Draw(), CBKNavComKX155Gauge::Draw(), CNavigationGauge::Draw(), CBasicADFGauge::Draw(), CNeedleGauge::Draw(), CSimpleSwitch::IncState(), CBasicMagnetoSwitch::MouseClick(), CSimpleInOutStateSwitch::MouseClick(), CBKADFKR87Gauge::MouseClick(), CBKXPDRKT76Gauge::MouseClick(), CBKNavComKX155Gauge::MouseClick(), Read(), CBKADFKR87Gauge::ReadFinished(), CBKXPDRKT76Gauge::ReadFinished(), CBKNavComKX155Gauge::ReadFinished(), CNavigationGauge::ReadFinished(), CBasicMagnetoSwitch::StopClick(), CBKADFKR87Gauge::StopClick(), CBKXPDRKT76Gauge::StopClick(), and Update().

bool CGauge::nomc [protected]
 

Definition at line 389 of file Gauges.h.

Referenced by CGauge(), and Read().

int CGauge::sfx_source = 0 [static]
 

Definition at line 398 of file Gauges.h.

Referenced by CSituation::CSituation(), CSimpleSwitch::DecState(), CSimpleSwitch::IncState(), CBasicMagnetoSwitch::MouseClick(), CBasicBatterySwitch::MouseClick(), CSimpleInOutStateSwitch::MouseClick(), and CBasicMagnetoSwitch::StopClick().

SSurface* CGauge::surf [protected]
 

Definition at line 392 of file Gauges.h.

Referenced by CNavigationGauge::Blit(), CBasicADFGauge::Blit(), Blit(), CGauge(), ClearSurface(), CBasicMagnetoSwitch::Draw(), CBasicBatterySwitch::Draw(), CSimpleInOutStateSwitch::Draw(), CSimpleSwitch::Draw(), CBKAP140Gauge::Draw(), CBKADFKR87Gauge::Draw(), CBKXPDRKT76Gauge::Draw(), CBKNavComKX155Gauge::Draw(), CNavigationGauge::Draw(), CBasicADFGauge::Draw(), CVerticalSpeedGauge::Draw(), CNeedleGauge::Draw(), CBitmapGauge::DrawOverlay(), CBitmapGauge::DrawUnderlay(), GetSurface(), and ReadFinished().

Tag CGauge::type [protected]
 

Definition at line 373 of file Gauges.h.

Referenced by CGauge(), and CSimpleInOutStateSwitch::CSimpleInOutStateSwitch().

Tag CGauge::unid [protected]
 

Definition at line 374 of file Gauges.h.

Referenced by CGauge(), and Read().

char CGauge::unid_s[8] [protected]
 

Definition at line 375 of file Gauges.h.

Referenced by Read().

float CGauge::value [protected]
 

Definition at line 395 of file Gauges.h.

Referenced by CNeedleGauge::Draw(), and Update().

int CGauge::w [protected]
 

Definition at line 376 of file Gauges.h.

Referenced by CGauge(), CBasicBatterySwitch::MouseClick(), CSimpleSwitch::MouseClick(), CSimpleSwitch::MouseMoved(), Read(), and ReadFinished().

int CGauge::x [protected]
 

Definition at line 376 of file Gauges.h.

Referenced by CGauge(), CBKADFKR87Gauge::Draw(), CBKXPDRKT76Gauge::Draw(), Read(), CNavigationGauge::ReadFinished(), CBasicADFGauge::ReadFinished(), and ReadFinished().

int CGauge::y [protected]
 

Definition at line 376 of file Gauges.h.

Referenced by CGauge(), CBKADFKR87Gauge::Draw(), CBKXPDRKT76Gauge::Draw(), Read(), CNavigationGauge::ReadFinished(), CBasicADFGauge::ReadFinished(), and ReadFinished().


The documentation for this class was generated from the following files:
SourceForge.net Logo Documentation generated by doxygen