25 lines
502 B
C++
25 lines
502 B
C++
#ifndef IPropertyItem_h__
|
|||
|
|
#define IPropertyItem_h__
|
||
|
|
|
||
|
|
#include "Property.h"
|
||
|
|
#include <delegate/Delegate.h>
|
||
|
|
|
||
|
|
namespace LifeCore
|
||
|
|
{
|
||
|
|
class IPropertyItem
|
||
|
|
{
|
||
|
|
public:
|
||
|
|
EVENT0(PropertyItemEvent);
|
||
|
|
PropertyItemEvent Event_ValueChanged;
|
||
|
|
virtual PropertyEditMode GetEditMode() = 0;
|
||
|
|
virtual void OnBeginEdit() {};
|
||
|
|
virtual void OnEndEdit(const String& data) = 0;
|
||
|
|
virtual String ToString() = 0;
|
||
|
|
private:
|
||
|
|
void OnPropertyChanged()
|
||
|
|
{
|
||
|
|
Event_ValueChanged.Invoke();
|
||
|
|
}
|
||
|
|
};
|
||
|
|
}
|
||
|
|
#endif // IPropertyItem_h__
|