//---------------------------------------------------------------------------

#ifndef VMSWCAM0FH
#define VMSWCAM0FH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <DB.hpp>
#include <DBClient.hpp>
#include <Provider.hpp>
//---------------------------------------------------------------------------
#include <ExtCtrls.hpp>
#include <Graphics.hpp>
#include <jpeg.hpp>
#include <Menus.hpp>
#include <GIFImg.hpp>
#include <OleCtrls.hpp>
#include "cxContainer.hpp"
#include "cxControls.hpp"
#include "cxEdit.hpp"
#include "cxGraphics.hpp"
#include "cxGroupBox.hpp"
#include "cxLookAndFeelPainters.hpp"
#include "cxLookAndFeels.hpp"
#include "dxSkinBlack.hpp"
#include "dxSkinMcSkin.hpp"
#include "dxSkinsCore.hpp"
#include "dxSkinBlue.hpp"
#include "dxSkinCaramel.hpp"
#include "dxSkinCoffee.hpp"
#include "dxSkinDarkRoom.hpp"
#include "dxSkinDarkSide.hpp"
#include "dxSkinFoggy.hpp"
#include "dxSkinGlassOceans.hpp"
#include "dxSkiniMaginary.hpp"
#include "dxSkinLilian.hpp"
#include "dxSkinLiquidSky.hpp"
#include "dxSkinLondonLiquidSky.hpp"
#include "dxSkinMoneyTwins.hpp"
#include "dxSkinOffice2007Black.hpp"
#include "dxSkinOffice2007Blue.hpp"
#include "dxSkinOffice2007Green.hpp"
#include "dxSkinOffice2007Pink.hpp"
#include "dxSkinOffice2007Silver.hpp"
#include "dxSkinOffice2010Black.hpp"
#include "dxSkinOffice2010Blue.hpp"
#include "dxSkinOffice2010Silver.hpp"
#include "dxSkinSeven.hpp"
#include "dxSkinSharp.hpp"
#include "dxSkinSilver.hpp"
#include "dxSkinStardust.hpp"

//---------------------------------------------------------------------------
#include "CDSVmsCtlrF.h"
#include "cxLabel.hpp"
#include "FFBaseComponent.hpp"
#include "FFBasePlay.hpp"
#include "FFPlay.hpp"
//---------------------------------------------------------------------------
class TVMSWCAM0 : public TForm
{
__published:	// IDE-managed Components
    TPopupMenu *PopupMenu1;
    TMenuItem *MnuPlay;
    TMenuItem *MnuStop;
    TMenuItem *MnuCtlrPing;
    TMenuItem *N1;
    TTimer *TmrPlay;
    TPanel *PnlMain;
    TPanel *PnlTitle;
    TPanel *PnFormBack;
    TPanel *PnlName;
    TPanel *PnlCamera;
    TMenuItem *MnuVmsInfId;
    TMenuItem *N2;
    TMenuItem *MnuWebcamPing;
    TTimer *TmrStop;
    TcxLabel *LblName;
    TFFPlayer *FFPlayer1;
    void __fastcall FormDestroy(TObject *Sender);
    void __fastcall FormShow(TObject *Sender);
    void __fastcall MnuNetworkPingClick(TObject *Sender);
    void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
    void __fastcall PnlNameClick(TObject *Sender);
    void __fastcall OnFormClick(TObject *Sender);
    void __fastcall PopupMenu1Popup(TObject *Sender);
    void __fastcall MnuPlayClick(TObject *Sender);
    void __fastcall MnuStopClick(TObject *Sender);
    void __fastcall TmrPlayTimer(TObject *Sender);
    void __fastcall TmrStopTimer(TObject *Sender);
    void __fastcall LblNameDblClick(TObject *Sender);
    void __fastcall FFPlayer1State(TObject *Sender, TPlayState APlayState);


private:	// User declarations
    bool        FSelected;
    int         FDisplayMode;
    float       FZoomRate;
    int         FDispIndex;
    bool        FPlay;

public:
    String  FTitle;
    bool    FAutoPlay;
    long    FConHandle;
    bool    FInstalled;

    TScrollBox *FScrollBox;
    TVmsCtlr   *FVmsObj;
    bool        FZoomView;
    HWND        FWndParent;

    String      FStrmAddr;
    String      FId;
    String      FLoc;

public:		// User declarations
    __fastcall TVMSWCAM0(TComponent* Owner, TVmsCtlr *AVmsObj);

    void __fastcall LoadLocalSkin();

    void __fastcall DisplayName(String AName);
    void __fastcall SetFormSize(int AFormW);

    void __fastcall RefreshVmsStatus();
    void __fastcall RefreshVmsMessage();

    void __fastcall CamPlay();
    void __fastcall CamStop();
    void __fastcall InitCamera(void *ACctv, bool AAutoPlay=true);

    void __fastcall SelectForm(bool ASelect);
    void __fastcall SetPlay(bool APlay);

    __property bool Selected = { read = FSelected, write = SelectForm };
    __property bool Play     = { read = FPlay,     write = SetPlay };
};
//---------------------------------------------------------------------------
//extern PACKAGE TVMSWCAM0 *VMSWCAM0;
//---------------------------------------------------------------------------
#endif

