Implemented BPortLink::AttachShape and BPortLink::ReadShape and used them for passing the shapes in AS_GET_GLYPH_SHAPES.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12215 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -78,6 +78,8 @@ virtual void _ReservedShape4();
|
||||
friend class TPicture;
|
||||
friend class BView;
|
||||
friend class BFont;
|
||||
friend class BPortLink;
|
||||
|
||||
void GetData(int32 *opCount, int32 *ptCount, uint32 **opList, BPoint **ptList);
|
||||
void SetData(int32 opCount, int32 ptCount, uint32 *opList, BPoint *ptList);
|
||||
void InitData();
|
||||
|
||||
@@ -68,6 +68,7 @@ public:
|
||||
status_t Attach(const void *data, ssize_t size);
|
||||
status_t AttachString(const char *string);
|
||||
status_t AttachRegion(const BRegion ®ion);
|
||||
status_t AttachShape(BShape &shape);
|
||||
template <class Type> status_t Attach(const Type& data)
|
||||
{
|
||||
return Attach(&data, sizeof(Type));
|
||||
@@ -77,6 +78,7 @@ public:
|
||||
status_t Read(void *data, ssize_t size);
|
||||
status_t ReadString(char **string);
|
||||
status_t ReadRegion(BRegion *region);
|
||||
status_t ReadShape(BShape *shape);
|
||||
template <class T> status_t Read(T *data)
|
||||
{
|
||||
return fReader->Read(data,sizeof(T));
|
||||
|
||||
Reference in New Issue
Block a user