From 6a076eca204eadc16e442b1cfdcaf7a5b38f197e Mon Sep 17 00:00:00 2001 From: Kohei Yoshida Date: Fri, 19 Oct 2012 16:05:10 +0200 Subject: [PATCH] We don't need this method now. The two classes have been merged. Therefore this method makes no sense now. Change-Id: Idb77d8faf5314f776bebc3bc9abc0e7e88ab5d18 --- svtools/inc/svtools/treelistbox.hxx | 2 -- svtools/source/contnr/svimpbox.cxx | 11 +++++------ svtools/source/contnr/treelistbox.cxx | 7 ------- 3 files changed, 5 insertions(+), 15 deletions(-) diff --git a/svtools/inc/svtools/treelistbox.hxx b/svtools/inc/svtools/treelistbox.hxx index 75c933b2bd54..06a4e54c05a1 100644 --- a/svtools/inc/svtools/treelistbox.hxx +++ b/svtools/inc/svtools/treelistbox.hxx @@ -101,7 +101,6 @@ enum SvButtonState { SV_BUTTON_UNCHECKED, SV_BUTTON_CHECKED, SV_BUTTON_TRISTATE #define SV_TAB_BORDER 8 -#define SV_LISTBOX_ID_TREEBOX 1 // fuer SvLBox::IsA() #define SV_ENTRYHEIGHTOFFS_PIXEL 2 #define TREEFLAG_CHKBTN 0x0001 @@ -378,7 +377,6 @@ public: using SvListView::SetModel; void SetModel(SvTreeList* pNewModel); - sal_uInt16 IsA(); sal_uLong GetEntryCount() const {return pModel->GetEntryCount();} SvTreeListEntry* First() const { return (SvTreeListEntry*)(pModel->First()); } SvTreeListEntry* Next( SvTreeListEntry* pEntry, sal_uInt16* pDepth=0 ) const { return pModel->Next(pEntry,pDepth); } diff --git a/svtools/source/contnr/svimpbox.cxx b/svtools/source/contnr/svimpbox.cxx index 83b344ec3788..61e54719580b 100644 --- a/svtools/source/contnr/svimpbox.cxx +++ b/svtools/source/contnr/svimpbox.cxx @@ -790,12 +790,11 @@ sal_Bool SvImpLBox::EntryReallyHit(SvTreeListEntry* pEntry,const Point& rPosPixe Rectangle aRect( pView->GetFocusRect( pEntry, nLine )); aRect.Right() = GetOutputSize().Width() - pView->GetMapMode().GetOrigin().X(); - if( pView->IsA() == SV_LISTBOX_ID_TREEBOX ) - { - SvLBoxContextBmp* pBmp = (SvLBoxContextBmp*)(pEntry->GetFirstItem(SV_ITEM_ID_LBOXCONTEXTBMP)); - aRect.Left() -= pBmp->GetSize(pView,pEntry).Width(); - aRect.Left() -= 4; // a little tolerance - } + + SvLBoxContextBmp* pBmp = (SvLBoxContextBmp*)(pEntry->GetFirstItem(SV_ITEM_ID_LBOXCONTEXTBMP)); + aRect.Left() -= pBmp->GetSize(pView,pEntry).Width(); + aRect.Left() -= 4; // a little tolerance + Point aPos( rPosPixel ); aPos -= pView->GetMapMode().GetOrigin(); if( aRect.IsInside( aPos ) ) diff --git a/svtools/source/contnr/treelistbox.cxx b/svtools/source/contnr/treelistbox.cxx index 6442181c445a..a24d6fbb6920 100644 --- a/svtools/source/contnr/treelistbox.cxx +++ b/svtools/source/contnr/treelistbox.cxx @@ -1554,13 +1554,6 @@ void SvTreeListBox::DisconnectFromModel() pImp->SetModel( GetModel() ); } - -sal_uInt16 SvTreeListBox::IsA() -{ - DBG_CHKTHIS(SvTreeListBox,0); - return SV_LISTBOX_ID_TREEBOX; -} - void SvTreeListBox::SetSublistOpenWithReturn( sal_Bool b ) { pImp->bSubLstOpRet = b;