Kaydet (Commit) 80ee754c authored tarafından Kohei Yoshida's avatar Kohei Yoshida

Move SvViewDataEntry and SvViewDataItem into these files too.

Change-Id: Ib25e7b4ff692804e4e4b617ffba228c4b2cae1db
üst cf9b196b
...@@ -131,31 +131,6 @@ public: ...@@ -131,31 +131,6 @@ public:
sal_Bool IsPushable() const { return (sal_Bool)((nFlags & SV_LBOXTAB_PUSHABLE)!=0); } sal_Bool IsPushable() const { return (sal_Bool)((nFlags & SV_LBOXTAB_PUSHABLE)!=0); }
}; };
// *********************************************************************
// *********************** View-dependent data *************************
// *********************************************************************
class SvViewDataItem
{
public:
Size aSize;
SvViewDataItem();
~SvViewDataItem();
};
// View-dependent data for an Entry is created in the virtual function
// SvTreeListBox::CreateViewData. The View creation of Items cannot be
// changed (because it's an array)
class SvViewDataEntry : public SvViewData
{
public:
SvViewDataItem* pItemData; // An array of SvViewDataItems
sal_uInt16 nItmCnt; // Item count for delete operator
SvViewDataEntry();
virtual ~SvViewDataEntry();
};
// ********************************************************************* // *********************************************************************
// ****************************** Items ******************************** // ****************************** Items ********************************
// ********************************************************************* // *********************************************************************
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include "svtdllapi.h" #include "svtdllapi.h"
#include "tools/solar.h" #include "tools/solar.h"
#include "tools/gen.hxx"
// Entryflags that are attached to the View // Entryflags that are attached to the View
#define SVLISTENTRYFLAG_SELECTED 0x0001 #define SVLISTENTRYFLAG_SELECTED 0x0001
...@@ -30,6 +31,8 @@ ...@@ -30,6 +31,8 @@
#define SVLISTENTRYFLAG_CURSORED 0x0008 #define SVLISTENTRYFLAG_CURSORED 0x0008
#define SVLISTENTRYFLAG_NOT_SELECTABLE 0x0010 #define SVLISTENTRYFLAG_NOT_SELECTABLE 0x0010
class SvViewDataItem;
class SVT_DLLPUBLIC SvViewData class SVT_DLLPUBLIC SvViewData
{ {
friend class SvTreeList; friend class SvTreeList;
...@@ -54,6 +57,28 @@ public: ...@@ -54,6 +57,28 @@ public:
void SetSelectable( bool bSelectable ); void SetSelectable( bool bSelectable );
}; };
// View-dependent data for an Entry is created in the virtual function
// SvTreeListBox::CreateViewData. The View creation of Items cannot be
// changed (because it's an array)
class SvViewDataEntry : public SvViewData
{
public:
SvViewDataItem* pItemData; // An array of SvViewDataItems
sal_uInt16 nItmCnt; // Item count for delete operator
SvViewDataEntry();
virtual ~SvViewDataEntry();
};
class SvViewDataItem
{
public:
Size aSize;
SvViewDataItem();
~SvViewDataItem();
};
#endif #endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -366,37 +366,6 @@ const Size& SvLBoxItem::GetSize(const SvTreeListBox* pView, const SvTreeListEntr ...@@ -366,37 +366,6 @@ const Size& SvLBoxItem::GetSize(const SvTreeListBox* pView, const SvTreeListEntr
return pViewData->aSize; return pViewData->aSize;
} }
DBG_NAME(SvViewDataItem);
SvViewDataItem::SvViewDataItem()
{
DBG_CTOR(SvViewDataItem,0);
}
SvViewDataItem::~SvViewDataItem()
{
DBG_DTOR(SvViewDataItem,0);
}
// ***************************************************************
// class SvLBoxViewData
// ***************************************************************
DBG_NAME(SvViewDataEntry);
SvViewDataEntry::SvViewDataEntry()
: SvViewData()
{
DBG_CTOR(SvViewDataEntry,0);
pItemData = 0;
}
SvViewDataEntry::~SvViewDataEntry()
{
DBG_DTOR(SvViewDataEntry,0);
delete [] pItemData;
}
struct SvTreeListBoxImpl struct SvTreeListBoxImpl
{ {
bool m_bIsEmptyTextAllowed:1; bool m_bIsEmptyTextAllowed:1;
......
...@@ -101,4 +101,31 @@ void SvViewData::SetSelectable( bool bSelectable ) ...@@ -101,4 +101,31 @@ void SvViewData::SetSelectable( bool bSelectable )
nFlags |= SVLISTENTRYFLAG_NOT_SELECTABLE; nFlags |= SVLISTENTRYFLAG_NOT_SELECTABLE;
} }
DBG_NAME(SvViewDataEntry);
SvViewDataEntry::SvViewDataEntry()
: SvViewData()
{
DBG_CTOR(SvViewDataEntry,0);
pItemData = 0;
}
SvViewDataEntry::~SvViewDataEntry()
{
DBG_DTOR(SvViewDataEntry,0);
delete [] pItemData;
}
DBG_NAME(SvViewDataItem);
SvViewDataItem::SvViewDataItem()
{
DBG_CTOR(SvViewDataItem,0);
}
SvViewDataItem::~SvViewDataItem()
{
DBG_DTOR(SvViewDataItem,0);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment