summaryrefslogtreecommitdiff
path: root/svtools/inc/tabbar.hxx
diff options
context:
space:
mode:
authorKohei Yoshida <kyoshida@novell.com>2010-10-04 17:23:15 -0400
committerKohei Yoshida <kyoshida@novell.com>2010-10-04 17:23:15 -0400
commitda2f4f8f88429c8656a7f7945e5854b9049bda1b (patch)
tree5888c0e14f8b4094eb1c1f1c039e66e95c0a47dd /svtools/inc/tabbar.hxx
parenta2d677f7b4964bd0291c258be3e16a18619cc12b (diff)
Ported calc-insert-new-sheet-tab-*.diff from ooo-build.
Parts of the work that enables display of a '+' button at the right end of the tab bar.
Diffstat (limited to 'svtools/inc/tabbar.hxx')
-rw-r--r--svtools/inc/tabbar.hxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/svtools/inc/tabbar.hxx b/svtools/inc/tabbar.hxx
index e036f4c2f045..442e605fc67f 100644
--- a/svtools/inc/tabbar.hxx
+++ b/svtools/inc/tabbar.hxx
@@ -302,6 +302,7 @@ ueber einem bzw. ueber welchem Item durchgefuehrt wurde.
#define WB_TOPBORDER ((WinBits)0x04000000)
#define WB_3DTAB ((WinBits)0x08000000)
#define WB_MINSCROLL ((WinBits)0x20000000)
+#define WB_INSERTTAB ((WinBits)0x40000000)
#define WB_STDTABBAR WB_BORDER
// ------------------
@@ -328,6 +329,7 @@ typedef USHORT TabBarPageBits;
// - TabBar -
// ----------
struct TabBar_Impl;
+struct ImplTabBarItem;
class SVT_DLLPUBLIC TabBar : public Window
{
@@ -371,6 +373,7 @@ private:
BOOL mbSelColor;
BOOL mbSelTextColor;
BOOL mbMirrored;
+ bool mbHasInsertTab; // if true, the tab bar has an extra tab at the end.
Link maSelectHdl;
Link maDoubleClickHdl;
Link maSplitHdl;
@@ -394,11 +397,15 @@ private:
SVT_DLLPRIVATE void ImplSelect();
SVT_DLLPRIVATE void ImplActivatePage();
SVT_DLLPRIVATE long ImplDeactivatePage();
+ SVT_DLLPRIVATE void ImplPrePaint();
+ SVT_DLLPRIVATE ImplTabBarItem* ImplGetLastTabBarItem( USHORT nItemCount ) const;
+ SVT_DLLPRIVATE Rectangle ImplGetInsertTabRect(ImplTabBarItem* pItem) const;
DECL_DLLPRIVATE_LINK( ImplClickHdl, ImplTabButton* );
public:
static const sal_uInt16 APPEND;
static const sal_uInt16 PAGE_NOT_FOUND;
+ static const sal_uInt16 INSERT_TAB_POS;
TabBar( Window* pParent, WinBits nWinStyle = WB_STDTABBAR );
virtual ~TabBar();
@@ -443,7 +450,7 @@ public:
USHORT GetPageCount() const;
USHORT GetPageId( USHORT nPos ) const;
USHORT GetPagePos( USHORT nPageId ) const;
- USHORT GetPageId( const Point& rPos ) const;
+ USHORT GetPageId( const Point& rPos, bool bCheckInsTab = false ) const;
Rectangle GetPageRect( USHORT nPageId ) const;
// returns the rectangle in which page tabs are drawn
Rectangle GetPageArea() const;