1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- #ifndef MECHPURCHASESCREEN_H
- #define MECHPURCHASESCREEN_H
- /*************************************************************************************************\
- MechPurchaseScreen.h : Interface for the MechPurchaseScreen component.
- //---------------------------------------------------------------------------//
- // Copyright (C) Microsoft Corporation. All rights reserved. //
- //===========================================================================//
- \*************************************************************************************************/
- #ifndef LOGISTICSSCREEN_H
- #include "LogisticsScreen.h"
- #endif
- #include "MechListBox.h"
- #include "LogisticsMech.h"
- #include "EList.h"
- #include "LogisticsMechDisplay.h"
- class LogisticsMech;
- //*************************************************************************************************
- /**************************************************************************************************
- CLASS DESCRIPTION
- MechPurchaseScreen:
- **************************************************************************************************/
- class MechPurchaseScreen: public LogisticsScreen
- {
- public:
- static MechPurchaseScreen* instance() { return s_instance; }
- MechPurchaseScreen();
- virtual ~MechPurchaseScreen();
- int init( FitIniFile& file );
- virtual void begin();
- virtual void end();
- virtual void update();
- virtual void render(int xOffset, int yOffset);
- void setMech( LogisticsMech* pMech, bool bFromLB = 0 );
- void beginDrag( LogisticsMech* pMech );
- virtual int handleMessage( unsigned long, unsigned long );
- private:
-
- MechPurchaseScreen( const MechPurchaseScreen& src );
- MechPurchaseScreen& operator=( const MechPurchaseScreen& echPurchaseScreen );
- MechListBox inventoryListBox;
- MechListBox variantListBox;
- LogisticsMechDisplay mechDisplay;
- LogisticsMech* pDragMech;
- aObject dragIcon;
- bool acceptPressed;
- static MechPurchaseScreen* s_instance;
- bool dragStartLeft;
-
- typedef EList<LogisticsMech, LogisticsMech > MECH_LIST;
- MECH_LIST prevInventory;
- float countDownTime;
- float curCount;
- float previousAmount;
- float oldCBillsAmount;
- float flashTime;
- // HELPER FUNCTIONS
- void addSelectedMech();
- void removeSelectedMech();
- void addMech( LogisticsMech* pMech );
- void removeMech( LogisticsMech* pMech );
- void endDrag();
- bool selectFirstBuyableMech();
- };
- //*************************************************************************************************
- #endif // end of file ( MechPurchaseScreen.h )
|