// CodeGear C++Builder
// Copyright (c) 1995, 2014 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'FMX.TMSGrid.pas' rev: 27.00 (Windows)

#ifndef Fmx_TmsgridHPP
#define Fmx_TmsgridHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>	// Pascal unit
#include <SysInit.hpp>	// Pascal unit
#include <FMX.Dialogs.hpp>	// Pascal unit
#include <System.Classes.hpp>	// Pascal unit
#include <System.Types.hpp>	// Pascal unit
#include <FMX.TMSCustomGrid.hpp>	// Pascal unit
#include <FMX.TMSGridOptions.hpp>	// Pascal unit
#include <FMX.TMSGridData.hpp>	// Pascal unit
#include <FMX.TMSBaseControl.hpp>	// Pascal unit
#include <FMX.Types.hpp>	// Pascal unit
#include <System.SysUtils.hpp>	// Pascal unit
#include <FMX.Edit.hpp>	// Pascal unit
#include <System.UITypes.hpp>	// Pascal unit
#include <Data.Bind.Components.hpp>	// Pascal unit
#include <Data.Bind.Grid.hpp>	// Pascal unit
#include <Data.Bind.DBScope.hpp>	// Pascal unit
#include <Data.DB.hpp>	// Pascal unit
#include <Data.Bind.Consts.hpp>	// Pascal unit
#include <FMX.TMSGridCell.hpp>	// Pascal unit
#include <System.Generics.Collections.hpp>	// Pascal unit
#include <FMX.Graphics.hpp>	// Pascal unit
#include <System.Generics.Defaults.hpp>	// Pascal unit
#include <FMX.Controls.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Fmx
{
namespace Tmsgrid
{
//-- type declarations -------------------------------------------------------
class DELPHICLASS TColumnDescObject;
#pragma pack(push,4)
class PASCALIMPLEMENTATION TColumnDescObject : public System::TObject
{
	typedef System::TObject inherited;
	
private:
	Data::Bind::Grid::TCreateColumnDescription FColumnDesc;
	
public:
	__property Data::Bind::Grid::TCreateColumnDescription ColumnDesc = {read=FColumnDesc, write=FColumnDesc};
public:
	/* TObject.Create */ inline __fastcall TColumnDescObject(void) : System::TObject() { }
	/* TObject.Destroy */ inline __fastcall virtual ~TColumnDescObject(void) { }
	
};

#pragma pack(pop)

class DELPHICLASS TBlobFieldProtected;
class PASCALIMPLEMENTATION TBlobFieldProtected : public Data::Db::TBlobField
{
	typedef Data::Db::TBlobField inherited;
	
public:
	/* TBlobField.Create */ inline __fastcall virtual TBlobFieldProtected(System::Classes::TComponent* AOwner) : Data::Db::TBlobField(AOwner) { }
	
public:
	/* TField.Destroy */ inline __fastcall virtual ~TBlobFieldProtected(void) { }
	
};


class DELPHICLASS TColumnDescList;
class PASCALIMPLEMENTATION TColumnDescList : public System::Generics::Collections::TObjectList__1<TColumnDescObject*>
{
	typedef System::Generics::Collections::TObjectList__1<TColumnDescObject*> inherited;
	
public:
	/* {System_Generics_Collections}TObjectList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(bool AOwnsObjects)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>(AOwnsObjects) { }
	/* {System_Generics_Collections}TObjectList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(const System::DelphiInterface<System::Generics::Defaults::IComparer__1<TColumnDescObject*> > AComparer, bool AOwnsObjects)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>(AComparer, AOwnsObjects) { }
	/* {System_Generics_Collections}TObjectList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(System::Generics::Collections::TEnumerable__1<TColumnDescObject*>* const Collection, bool AOwnsObjects)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>(Collection, AOwnsObjects) { }
	
public:
	/* {System_Generics_Collections}TList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(void)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>() { }
	/* {System_Generics_Collections}TList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(const System::DelphiInterface<System::Generics::Defaults::IComparer__1<TColumnDescObject*> > AComparer)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>(AComparer) { }
	/* {System_Generics_Collections}TList<FMX_TMSGrid_TColumnDescObject>.Create */ inline __fastcall TColumnDescList(System::Generics::Collections::TEnumerable__1<TColumnDescObject*>* const Collection)/* overload */ : System::Generics::Collections::TObjectList__1<TColumnDescObject*>(Collection) { }
	/* {System_Generics_Collections}TList<FMX_TMSGrid_TColumnDescObject>.Destroy */ inline __fastcall virtual ~TColumnDescList(void) { }
	
};


typedef void __fastcall (__closure *TTMSFMXGridFormatCellDataExpression)(System::TObject* Sender, const Data::Bind::Grid::TCreateColumnDescription &AColumnDescription, int AColumn, System::UnicodeString &AFormat);

class DELPHICLASS TTMSFMXGrid;
class PASCALIMPLEMENTATION TTMSFMXGrid : public Fmx::Tmscustomgrid::TTMSFMXCustomGrid
{
	typedef Fmx::Tmscustomgrid::TTMSFMXCustomGrid inherited;
	
private:
	Fmx::Tmsgriddata::TCell FInternalCell;
	TColumnDescList* FColumnDescList;
	bool FSaveDataSetData;
	TTMSFMXGridFormatCellDataExpression FOnFormatCellDataExpression;
	int __fastcall GetColumnIndex(void);
	int __fastcall GetSelected(void);
	void __fastcall SetColumnIndex(const int Value);
	void __fastcall SetSelected(const int Value);
	int __fastcall GetItemIndex(void);
	void __fastcall SetItemIndex(const int Value);
	
protected:
	virtual void __fastcall AssignBitmapEx(System::Classes::TPersistent* Source, System::Classes::TPersistent* Dest);
	virtual bool __fastcall CanObserve(const int ID);
	virtual void __fastcall ObserverAdded(const int ID, const System::Classes::_di_IObserver Observer);
	void __fastcall ObserverToggle(const System::Classes::_di_IObserver AObserver, const bool Value);
	System::TVarRec __fastcall ObserverCurrent(void);
	
public:
	__property TColumnDescList* ColumnDescList = {read=FColumnDescList, write=FColumnDescList};
	__fastcall virtual TTMSFMXGrid(System::Classes::TComponent* AOwner);
	__fastcall virtual ~TTMSFMXGrid(void);
	virtual void __fastcall DoGetCellReadOnly(int ACol, int ARow, bool &AReadOnly);
	virtual void __fastcall DoCanInsertRow(int ARow, bool &Allow);
	virtual void __fastcall DoCanDeleteRow(int ARow, bool &Allow);
	virtual void __fastcall DoGetCellEditorType(int ACol, int ARow, Fmx::Tmsgriddata::TTMSFMXGridEditorType &CellEditorType);
	virtual void __fastcall DoGetCellLayout(int ACol, int ARow, Fmx::Tmsgridcell::TTMSFMXGridCellLayout* ALayout, Fmx::Tmsgriddata::TCellState ACellState);
	virtual void __fastcall DoGetCellProperties(int ACol, int ARow, Fmx::Types::TFmxObject* Cell);
	virtual void __fastcall DoCellCheckBoxClick(int ACol, int ARow, Fmx::Types::TFmxObject* Cell);
	virtual void __fastcall DoCellEditGetData(int ACol, int ARow, Fmx::Types::TFmxObject* CellEditor, System::UnicodeString &CellString);
	virtual void __fastcall CellEditKeyDown(System::TObject* Sender, System::Word &Key, System::WideChar &KeyChar, System::Classes::TShiftState Shift);
	virtual void __fastcall DoCellEditDone(int ACol, int ARow, Fmx::Types::TFmxObject* CellEditor);
	virtual void __fastcall SelectCell(const Fmx::Tmsgriddata::TCell &Cell, System::Classes::TShiftState Shift = System::Classes::TShiftState() , bool MouseDragging = false);
	void __fastcall NotifyObserver(void);
	void __fastcall NotifyObserverStartEdit(void);
	void __fastcall NotifyObserverStopEdit(void);
	void __fastcall NotifyObserverCheckClick(int ACol, int ARow);
	__property int Selected = {read=GetSelected, write=SetSelected, nodefault};
	__property int ItemIndex = {read=GetItemIndex, write=SetItemIndex, nodefault};
	__property int ColumnIndex = {read=GetColumnIndex, write=SetColumnIndex, nodefault};
	__property bool SaveDataSetData = {read=FSaveDataSetData, write=FSaveDataSetData, nodefault};
	
__published:
	__property Columns;
	__property TTMSFMXGridFormatCellDataExpression OnFormatCellDataExpression = {read=FOnFormatCellDataExpression, write=FOnFormatCellDataExpression};
};


//-- var, const, procedure ---------------------------------------------------
}	/* namespace Tmsgrid */
}	/* namespace Fmx */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_FMX_TMSGRID)
using namespace Fmx::Tmsgrid;
#endif
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_FMX)
using namespace Fmx;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// Fmx_TmsgridHPP
