summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorJoseph Powers <jpowers27@cox.net>2011-07-23 07:16:14 -0700
committerJoseph Powers <jpowers27@cox.net>2011-07-23 07:20:33 -0700
commit18d18c8a5646868a8229dea9ffe3f46888c2bad5 (patch)
tree68da0273e44e8998dcfa293c8763e0693dab9690 /svtools
parent8622956e24a178637cf3d6d8e84188ebfd3500d4 (diff)
unusedcode.easy: svxIconChoiceCtrl_Impl
Doing List cleanup, I ran into SaveSelection() and decided to delete it. While I was in the class, I went ahead and cleanup them all up.
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/contnr/imivctl.hxx33
-rw-r--r--svtools/source/contnr/imivctl1.cxx391
2 files changed, 5 insertions, 419 deletions
diff --git a/svtools/source/contnr/imivctl.hxx b/svtools/source/contnr/imivctl.hxx
index 74bce9b33532..2d9f04241589 100644
--- a/svtools/source/contnr/imivctl.hxx
+++ b/svtools/source/contnr/imivctl.hxx
@@ -311,7 +311,6 @@ class SvxIconChoiceCtrl_Impl
sal_Bool bSelect,
sal_Bool bSyncPaint
);
- void SaveSelection( List** );
void RepaintEntries( sal_uInt16 nEntryFlagsMask );
void SetListPositions();
void SetDefaultTextSize();
@@ -330,7 +329,6 @@ class SvxIconChoiceCtrl_Impl
DECL_LINK( TextEditEndedHdl, IcnViewEdit_Impl* );
void ShowFocus ( Rectangle& rRect );
- void HideFocus ();
void DrawFocusRect ( OutputDevice* pOut );
sal_Bool IsMnemonicChar( sal_Unicode cChar, sal_uLong& rPos ) const;
@@ -400,7 +398,6 @@ public:
);
void InvalidateEntry( SvxIconChoiceCtrlEntry* );
- IcnViewFieldType GetItem( SvxIconChoiceCtrlEntry*, const Point& rAbsPos );
void SetNoSelection();
@@ -442,13 +439,14 @@ public:
const Point& rPos,
const Size& rBoundingSize
);
- // berechnet alle BoundRects neu
- void RecalcAllBoundingRects();
// berechnet alle ungueltigen BoundRects neu
void RecalcAllBoundingRectsSmart();
const Rectangle& GetEntryBoundRect( SvxIconChoiceCtrlEntry* );
- void InvalidateBoundingRect( SvxIconChoiceCtrlEntry* );
- void InvalidateBoundingRect( Rectangle& rRect ) { rRect.Right() = LONG_MAX; bBoundRectsDirty = sal_True; }
+ void InvalidateBoundingRect( Rectangle& rRect )
+ {
+ rRect.Right() = LONG_MAX;
+ bBoundRectsDirty = sal_True;
+ }
sal_Bool IsBoundingRectValid( const Rectangle& rRect ) const { return (sal_Bool)( rRect.Right() != LONG_MAX ); }
void PaintEmphasis(
@@ -474,28 +472,18 @@ public:
// berechnet alle BoundingRects neu, wenn bMustRecalcBoundingRects == sal_True
void CheckBoundingRects() { if (bBoundRectsDirty) RecalcAllBoundingRectsSmart(); }
// berechnet alle invalidierten BoundingRects neu
- void UpdateBoundingRects();
void ShowTargetEmphasis( SvxIconChoiceCtrlEntry* pEntry, sal_Bool bShow );
- void PrepareCommandEvent( const CommandEvent& );
void Command( const CommandEvent& rCEvt );
void ToTop( SvxIconChoiceCtrlEntry* );
sal_uLong GetSelectionCount() const;
void SetGrid( const Size& );
Size GetMinGrid() const;
- sal_uLong GetGridCount(
- const Size& rSize,
- sal_Bool bCheckScrBars,
- sal_Bool bSmartScrBar ) const;
void Scroll( long nDeltaX, long nDeltaY, sal_Bool bScrollBar = sal_False );
const Size& GetItemSize( SvxIconChoiceCtrlEntry*, IcnViewFieldType ) const;
void HideDDIcon();
void ShowDDIcon( SvxIconChoiceCtrlEntry* pRefEntry, const Point& rPos );
- void HideShowDDIcon(
- SvxIconChoiceCtrlEntry* pRefEntry,
- const Point& rPos
- );
sal_Bool IsOver(
SvPtrarr* pSelectedRectList,
@@ -528,14 +516,11 @@ public:
SvxIconChoiceCtrlTextMode,
SvxIconChoiceCtrlEntry* pEntry = 0
);
- SvxIconChoiceCtrlTextMode GetTextMode( const SvxIconChoiceCtrlEntry* pEntry = 0 ) const;
- void ShowEntryFocusRect( const SvxIconChoiceCtrlEntry* pEntry );
void EnableEntryEditing( sal_Bool bEnable ) { bEntryEditingEnabled = bEnable; }
sal_Bool IsEntryEditingEnabled() const { return bEntryEditingEnabled; }
sal_Bool IsEntryEditing() const { return (sal_Bool)(pCurEditedEntry!=0); }
void EditEntry( SvxIconChoiceCtrlEntry* pEntry );
void StopEntryEditing( sal_Bool bCancel );
- void LockEntryPos( SvxIconChoiceCtrlEntry* pEntry, sal_Bool bLock );
size_t GetEntryCount() const { return aEntries.size(); }
SvxIconChoiceCtrlEntry* GetEntry( size_t nPos )
{
@@ -562,18 +547,13 @@ public:
nFlags &= ~(F_MOVED_ENTRIES);
}
sal_uLong GetEntryListPos( SvxIconChoiceCtrlEntry* ) const;
- void SetEntryListPos( SvxIconChoiceCtrlEntry* pEntry, sal_uLong nNewPos );
void SetEntryImageSize( const Size& rSize ) { aImageSize = rSize; }
- void SetEntryFlags( SvxIconChoiceCtrlEntry* pEntry, sal_uInt16 nFlags );
- SvxIconChoiceCtrlEntry* GoLeftRight( SvxIconChoiceCtrlEntry*, sal_Bool bRight );
- SvxIconChoiceCtrlEntry* GoUpDown( SvxIconChoiceCtrlEntry*, sal_Bool bDown );
void InitSettings();
Rectangle GetOutputRect() const;
sal_Bool ArePredecessorsSet() const { return (sal_Bool)(pHead != 0); }
SvxIconChoiceCtrlEntry* GetPredecessorHead() const { return pHead; }
void SetEntryPredecessor(SvxIconChoiceCtrlEntry* pEntry,SvxIconChoiceCtrlEntry* pPredecessor);
- sal_Bool GetEntryPredecessor(SvxIconChoiceCtrlEntry* pEntry,SvxIconChoiceCtrlEntry** ppPredecessor);
// liefert gueltige Ergebnisse nur im AutoArrange-Modus!
SvxIconChoiceCtrlEntry* FindEntryPredecessor( SvxIconChoiceCtrlEntry* pEntry, const Point& );
@@ -583,7 +563,6 @@ public:
void Flush();
void SetColumn( sal_uInt16 nIndex, const SvxIconChoiceCtrlColumnInfo& );
const SvxIconChoiceCtrlColumnInfo* GetColumn( sal_uInt16 nIndex ) const;
- const SvxIconChoiceCtrlColumnInfo* GetItemColumn( sal_uInt16 nSubItem, long& rLeft ) const;
Rectangle GetDocumentRect() const { return Rectangle( Point(), aVirtOutputSize ); }
Rectangle GetVisibleRect() const { return GetOutputRect(); }
@@ -599,8 +578,6 @@ public:
sal_Bool bHide
);
void StopSelectTimer() { aCallSelectHdlTimer.Stop(); }
- void Tracking( const TrackingEvent& rTEvt );
- Point GetPopupMenuPosPixel() const;
sal_Bool HandleShortCutKey( const KeyEvent& rKeyEvent );
diff --git a/svtools/source/contnr/imivctl1.cxx b/svtools/source/contnr/imivctl1.cxx
index b2ec187b370a..625b04a0d7a2 100644
--- a/svtools/source/contnr/imivctl1.cxx
+++ b/svtools/source/contnr/imivctl1.cxx
@@ -856,20 +856,6 @@ void SvxIconChoiceCtrl_Impl::InitScrollBarBox()
aScrBarBox.SetPosPixel( Point(aSize.Width()-nVerSBarWidth+1, aSize.Height()-nHorSBarHeight+1));
}
-IcnViewFieldType SvxIconChoiceCtrl_Impl::GetItem( SvxIconChoiceCtrlEntry* pEntry,
- const Point& rAbsPos )
-{
- Rectangle aRect( CalcTextRect( pEntry ) );
- if( aRect.IsInside( rAbsPos ) )
- return IcnViewFieldTypeText;
-
- aRect = CalcBmpRect( pEntry );
- if( aRect.IsInside( rAbsPos ) )
- return IcnViewFieldTypeImage;
-
- return IcnViewFieldTypeDontknow;
-}
-
sal_Bool SvxIconChoiceCtrl_Impl::MouseButtonDown( const MouseEvent& rMEvt)
{
sal_Bool bHandled = sal_True;
@@ -1091,44 +1077,6 @@ sal_Bool SvxIconChoiceCtrl_Impl::MouseMove( const MouseEvent& rMEvt )
return sal_True;
}
-void SvxIconChoiceCtrl_Impl::Tracking( const TrackingEvent& rTEvt )
-{
- if ( rTEvt.IsTrackingEnded() )
- {
- // Das Rechteck darf nicht "justified" sein, da seine
- // TopLeft-Position u.U. zur Berechnung eines Ankers
- // benutzt wird.
- AddSelectedRect( aCurSelectionRect );
- pView->HideTracking();
- nFlags &= ~(F_ADD_MODE);
- if( rTEvt.IsTrackingCanceled() )
- SetNoSelection();
- }
- else
- {
- Point aPosPixel = rTEvt.GetMouseEvent().GetPosPixel();
- Point aDocPos( aPosPixel );
- ToDocPos( aDocPos );
-
- long nScrollDX, nScrollDY;
-
- CalcScrollOffsets( aPosPixel, nScrollDX, nScrollDY, sal_False );
- if( nScrollDX || nScrollDY )
- {
- pView->HideTracking();
- pView->Scroll( nScrollDX, nScrollDY );
- }
- Rectangle aRect( aCurSelectionRect.TopLeft(), aDocPos );
- if( aRect != aCurSelectionRect )
- {
- pView->HideTracking();
- sal_Bool bAdd = (nFlags & F_ADD_MODE) ? sal_True : sal_False;
- SelectRect( aRect, bAdd, &aSelectedRectList );
- }
- pView->ShowTracking( aRect, SHOWTRACK_SMALL | SHOWTRACK_CLIP );
- }
-}
-
void SvxIconChoiceCtrl_Impl::SetCursor_Impl( SvxIconChoiceCtrlEntry* pOldCursor,
SvxIconChoiceCtrlEntry* pNewCursor, sal_Bool bMod1, sal_Bool bShift, sal_Bool bPaintSync )
{
@@ -2327,40 +2275,6 @@ Size SvxIconChoiceCtrl_Impl::CalcBoundingSize( SvxIconChoiceCtrlEntry* pEntry )
CalcBoundingHeight( pEntry ) );
}
-void SvxIconChoiceCtrl_Impl::RecalcAllBoundingRects()
-{
- nMaxBoundHeight = 0;
- pZOrderList->clear();
- size_t nCount = aEntries.size();
- size_t nCur;
- SvxIconChoiceCtrlEntry* pEntry;
-
- if( !IsAutoArrange() || !pHead )
- {
- for( nCur = 0; nCur < nCount; nCur++ )
- {
- pEntry = aEntries[ nCur ];
- FindBoundingRect( pEntry );
- pZOrderList->push_back( pEntry );
- }
- }
- else
- {
- nCur = 0;
- pEntry = pHead;
- while( nCur != nCount )
- {
- DBG_ASSERT(pEntry->pflink&&pEntry->pblink,"SvxIconChoiceCtrl_Impl::RecalcAllBoundingRect > Bad link(s)");
- FindBoundingRect( pEntry );
- pZOrderList->push_back( pEntry );
- pEntry = pEntry->pflink;
- nCur++;
- }
- }
- bBoundRectsDirty = sal_False;
- AdjustScrollBars();
-}
-
void SvxIconChoiceCtrl_Impl::RecalcAllBoundingRectsSmart()
{
nMaxBoundHeight = 0;
@@ -2408,16 +2322,6 @@ void SvxIconChoiceCtrl_Impl::RecalcAllBoundingRectsSmart()
AdjustScrollBars();
}
-void SvxIconChoiceCtrl_Impl::UpdateBoundingRects()
-{
- const size_t nCount = aEntries.size();
- for( size_t nCur = 0; nCur < nCount; nCur++ )
- {
- SvxIconChoiceCtrlEntry* pEntry = aEntries[ nCur ];
- GetEntryBoundRect( pEntry );
- }
-}
-
void SvxIconChoiceCtrl_Impl::FindBoundingRect( SvxIconChoiceCtrlEntry* pEntry )
{
DBG_ASSERT(!pEntry->IsPosLocked(),"Locked entry pos in FindBoundingRect");
@@ -2561,101 +2465,6 @@ void SvxIconChoiceCtrl_Impl::ShowDDIcon( SvxIconChoiceCtrlEntry* pRefEntry, cons
pRefEntry->SetFlags( ICNVIEW_FLAG_SELECTED );
}
-void SvxIconChoiceCtrl_Impl::HideShowDDIcon( SvxIconChoiceCtrlEntry* pRefEntry, const Point& rPosPix )
-{
-/* In Notfaellen folgenden flackernden Code aktivieren:
-
- HideDDIcon();
- ShowDDIcon( pRefEntry, rPosPix );
- return;
-*/
- if( !pDDDev )
- {
- ShowDDIcon( pRefEntry, rPosPix );
- return;
- }
-
- if( pRefEntry != pDDRefEntry )
- {
- HideDDIcon();
- ShowDDIcon( pRefEntry, rPosPix );
- return;
- }
-
- Point aEmptyPoint;
-
- Point aCurEntryPos( rPosPix );
- ToDocPos( aCurEntryPos );
-
- const Rectangle& rRect = GetEntryBoundRect( pRefEntry );
- Size aEntrySize( rRect.GetSize() );
- Rectangle aPrevEntryRect( aDDLastEntryPos, aEntrySize );
- Rectangle aCurEntryRect( aCurEntryPos, aEntrySize );
-
- if( !aPrevEntryRect.IsOver( aCurEntryRect ) )
- {
- HideDDIcon();
- ShowDDIcon( pRefEntry, rPosPix );
- return;
- }
-
- // Ueberlappung des neuen und alten D&D-Pointers!
-
- Rectangle aFullRect( aPrevEntryRect.Union( aCurEntryRect ) );
- if( !pDDTempDev )
- {
- pDDTempDev = new VirtualDevice( *pView );
- pDDTempDev->SetFont( pView->GetFont() );
- }
-
- Size aFullSize( aFullRect.GetSize() );
- Point aFullPos( aFullRect.TopLeft() );
-
- pDDTempDev->SetOutputSizePixel( aFullSize );
-
- // Hintergrund (mit dem alten D&D-Pointer!) sichern
- pDDTempDev->DrawOutDev( aEmptyPoint, aFullSize, aFullPos, aFullSize, *pView );
- // den alten Buffer in den neuen Buffer pasten
- aDDLastRectPos = aDDLastRectPos - aFullPos;
-
- pDDTempDev->DrawOutDev(
- aDDLastRectPos,
- pDDDev->GetOutputSizePixel(),
- aEmptyPoint,
- pDDDev->GetOutputSizePixel(),
- *pDDDev );
-
- // Swap
- VirtualDevice* pTemp = pDDDev;
- pDDDev = pDDTempDev;
- pDDTempDev = pTemp;
-
- // in den restaurierten Hintergrund den neuen D&D-Pointer zeichnen
- pDDTempDev->SetOutputSizePixel( pDDDev->GetOutputSizePixel() );
- pDDTempDev->DrawOutDev(
- aEmptyPoint, aFullSize, aEmptyPoint, aFullSize, *pDDDev );
- Point aRelPos = aCurEntryPos - aFullPos;
- pRefEntry->SetFlags( ICNVIEW_FLAG_BLOCK_EMPHASIS );
- PaintEntry( pRefEntry, aRelPos, pDDTempDev );
- pRefEntry->ClearFlags( ICNVIEW_FLAG_BLOCK_EMPHASIS );
-
- aDDLastRectPos = aFullPos;
- aDDLastEntryPos = aCurEntryPos;
-
- pView->DrawOutDev(
- aDDLastRectPos,
- pDDDev->GetOutputSizePixel(),
- aEmptyPoint,
- pDDDev->GetOutputSizePixel(),
- *pDDTempDev );
-}
-
-void SvxIconChoiceCtrl_Impl::InvalidateBoundingRect( SvxIconChoiceCtrlEntry* pEntry )
-{
- InvalidateBoundingRect( pEntry->aRect );
-}
-
-
sal_Bool SvxIconChoiceCtrl_Impl::HandleScrollCommand( const CommandEvent& rCmd )
{
Rectangle aDocRect( GetDocumentRect() );
@@ -3382,15 +3191,6 @@ IMPL_LINK(SvxIconChoiceCtrl_Impl, DocRectChangedHdl, void*, EMPTYARG )
return 0;
}
-void SvxIconChoiceCtrl_Impl::PrepareCommandEvent( const CommandEvent& rCEvt )
-{
- StopEditTimer();
- SvxIconChoiceCtrlEntry* pEntry = pView->GetEntry( rCEvt.GetMousePosPixel() );
- if( (nFlags & F_DOWN_CTRL) && pEntry && !pEntry->IsSelected() )
- SelectEntry( pEntry, sal_True, sal_True );
- nFlags &= ~(F_DOWN_CTRL | F_DOWN_DESELECT);
-}
-
sal_Bool SvxIconChoiceCtrl_Impl::IsTextHit( SvxIconChoiceCtrlEntry* pEntry, const Point& rDocPos )
{
Rectangle aRect( CalcTextRect( pEntry ));
@@ -3525,13 +3325,6 @@ void SvxIconChoiceCtrl_Impl::SetEntryTextMode( SvxIconChoiceCtrlTextMode eMode,
}
}
-SvxIconChoiceCtrlTextMode SvxIconChoiceCtrl_Impl::GetTextMode( const SvxIconChoiceCtrlEntry* pEntry ) const
-{
- if( !pEntry )
- return eTextMode;
- return pEntry->GetTextMode();
-}
-
SvxIconChoiceCtrlTextMode SvxIconChoiceCtrl_Impl::GetEntryTextModeSmart( const SvxIconChoiceCtrlEntry* pEntry ) const
{
DBG_ASSERT(pEntry,"GetEntryTextModeSmart: Entry not set");
@@ -3541,19 +3334,6 @@ SvxIconChoiceCtrlTextMode SvxIconChoiceCtrl_Impl::GetEntryTextModeSmart( const S
return eMode;
}
-void SvxIconChoiceCtrl_Impl::ShowEntryFocusRect( const SvxIconChoiceCtrlEntry* pEntry )
-{
- if( !pEntry )
- {
- pView->HideFocus();
- }
- else
- {
- Rectangle aRect ( CalcFocusRect( (SvxIconChoiceCtrlEntry*)pEntry ) );
- /*pView->*/ShowFocus( aRect );
- }
-}
-
////////////////////////////////////////////////////////////////////////////////////////////////
//
// Draw my own focusrect, because the focusrect of the outputdevice has got the inverted color
@@ -3575,11 +3355,6 @@ void SvxIconChoiceCtrl_Impl::ShowFocus ( Rectangle& rRect )
aFocus.aRect = rRect;
}
-void SvxIconChoiceCtrl_Impl::HideFocus ()
-{
- aFocus.bOn = sal_False;
-}
-
void SvxIconChoiceCtrl_Impl::DrawFocusRect ( OutputDevice* pOut )
{
pOut->SetLineColor( aFocus.aPenColor );
@@ -3728,14 +3503,6 @@ void SvxIconChoiceCtrl_Impl::StopEntryEditing( sal_Bool bCancel )
pEdit->StopEditing( bCancel );
}
-void SvxIconChoiceCtrl_Impl::LockEntryPos( SvxIconChoiceCtrlEntry* pEntry, sal_Bool bLock )
-{
- if( bLock )
- pEntry->SetFlags( ICNVIEW_FLAG_POS_LOCKED );
- else
- pEntry->ClearFlags( ICNVIEW_FLAG_POS_LOCKED );
-}
-
SvxIconChoiceCtrlEntry* SvxIconChoiceCtrl_Impl::GetFirstSelectedEntry( sal_uLong& rPos ) const
{
if( !GetSelectionCount() )
@@ -3832,19 +3599,6 @@ void SvxIconChoiceCtrl_Impl::SelectAll( sal_Bool bSelect, sal_Bool bPaint )
pAnchor = 0;
}
-void SvxIconChoiceCtrl_Impl::SaveSelection( List** ppList )
-{
- if( !*ppList )
- *ppList = new List;
- sal_uLong nPos;
- SvxIconChoiceCtrlEntry* pEntry = GetFirstSelectedEntry( nPos );
- while( pEntry && GetSelectionCount() != (*ppList)->Count() )
- {
- (*ppList)->Insert( pEntry, LIST_APPEND );
- pEntry = GetNextSelectedEntry( nPos );
- }
-}
-
IcnViewEdit_Impl::IcnViewEdit_Impl( SvtIconChoiceCtrl* pParent, const Point& rPos,
const Size& rSize, const XubString& rData, const Link& rNotifyEditEnd ) :
MultiLineEdit( pParent, (pParent->GetStyle() & WB_ICON) ? WB_CENTER : WB_LEFT),
@@ -3980,49 +3734,6 @@ sal_uLong SvxIconChoiceCtrl_Impl::GetEntryListPos( SvxIconChoiceCtrlEntry* pEntr
return pEntry->nPos;
}
-void SvxIconChoiceCtrl_Impl::SetEntryListPos( SvxIconChoiceCtrlEntry* pListEntry, sal_uLong nNewPos )
-{
- size_t nCurPos = GetEntryListPos( pListEntry );
- if( nCurPos == nNewPos )
- return;
- aEntries.remove( nCurPos );
- aEntries.insert( nNewPos, pListEntry );
- // Eintragspositionen anpassen
- size_t nStart, nEnd;
- if( nNewPos < nCurPos )
- {
- nStart = nNewPos;
- nEnd = nCurPos;
- }
- else
- {
- nStart = nCurPos;
- nEnd = nNewPos;
- }
- for( ; nStart <= nEnd; nStart++ )
- {
- SvxIconChoiceCtrlEntry* pEntry = aEntries[ nStart ];
- pEntry->nPos = nStart;
- }
-}
-
-void SvxIconChoiceCtrl_Impl::SetEntryFlags( SvxIconChoiceCtrlEntry* pEntry, sal_uInt16 nEntryFlags )
-{
- pEntry->nFlags = nEntryFlags;
- if( nEntryFlags & ICNVIEW_FLAG_POS_MOVED )
- nFlags |= F_MOVED_ENTRIES;
-}
-
-SvxIconChoiceCtrlEntry* SvxIconChoiceCtrl_Impl::GoLeftRight( SvxIconChoiceCtrlEntry* pStart, sal_Bool bRight )
-{
- return pImpCursor->GoLeftRight( pStart, bRight );
-}
-
-SvxIconChoiceCtrlEntry* SvxIconChoiceCtrl_Impl::GoUpDown( SvxIconChoiceCtrlEntry* pStart, sal_Bool bDown )
-{
- return pImpCursor->GoUpDown( pStart, bDown );
-}
-
void SvxIconChoiceCtrl_Impl::InitSettings()
{
const StyleSettings& rStyleSettings = pView->GetSettings().GetStyleSettings();
@@ -4157,26 +3868,8 @@ void SvxIconChoiceCtrl_Impl::SetPositionMode( SvxIconChoiceCtrlPositionMode eMod
// positionieren wir verschobene Eintraege 'hart' gibts noch Probleme
// mit ungewollten Ueberlappungen, da diese Eintrage im Arrange
// nicht beruecksichtigt werden.
-#if 1
if( aEntries.size() )
aAutoArrangeTimer.Start();
-#else
- if( pHead )
- {
- // verschobene Eintraege 'hart' auf ihre Position setzen
- nCur = nCount;
- SvxIconChoiceCtrlEntry* pEntry = pHead;
- while( nCur )
- {
- SvxIconChoiceCtrlEntry* pPred;
- if( GetEntryPredecessor( pEntry, &pPred ))
- SetEntryFlags( pEntry, ICNVIEW_FLAG_POS_MOVED );
- pEntry = pEntry->pflink;
- nCur--;
- }
- ClearPredecessors();
- }
-#endif
return;
}
@@ -4260,29 +3953,6 @@ void SvxIconChoiceCtrl_Impl::SetEntryPredecessor( SvxIconChoiceCtrlEntry* pEntry
aAutoArrangeTimer.Start();
}
-sal_Bool SvxIconChoiceCtrl_Impl::GetEntryPredecessor( SvxIconChoiceCtrlEntry* pEntry,
- SvxIconChoiceCtrlEntry** ppPredecessor )
-{
- *ppPredecessor = 0;
- if( !pHead )
- return sal_False;
- DBG_ASSERT(pEntry->pblink,"GetEntryPredecessor: Backward link not set");
- DBG_ASSERT(pEntry->pflink,"GetEntryPredecessor: Forward link not set");
-
- if( pEntry == pHead )
- {
- SvxIconChoiceCtrlEntry* pFirst = aEntries[ 0 ];
- if( pFirst != pEntry )
- return sal_True;
- return sal_False;
- }
- *ppPredecessor = pEntry->pblink;
- if( !(pEntry->nFlags & ICNVIEW_FLAG_PRED_SET) &&
- (GetEntryListPos( *ppPredecessor ) + 1) == GetEntryListPos( pEntry ))
- return sal_False;
- return sal_True;
-}
-
SvxIconChoiceCtrlEntry* SvxIconChoiceCtrl_Impl::FindEntryPredecessor( SvxIconChoiceCtrlEntry* pEntry,
const Point& rPosTopLeft )
{
@@ -4435,24 +4105,6 @@ const SvxIconChoiceCtrlColumnInfo* SvxIconChoiceCtrl_Impl::GetColumn( sal_uInt16
return (const SvxIconChoiceCtrlColumnInfo*)pColumns->GetObject( nIndex );
}
-const SvxIconChoiceCtrlColumnInfo* SvxIconChoiceCtrl_Impl::GetItemColumn( sal_uInt16 nSubItem,
- long& rLeft ) const
-{
- rLeft = 0;
- if( !pColumns )
- return 0;
- const sal_uInt16 nCount = pColumns->Count();
- const SvxIconChoiceCtrlColumnInfo* pCol = 0;
- for( sal_uInt16 nCur = 0; nCur < nCount; nCur++ )
- {
- pCol = (const SvxIconChoiceCtrlColumnInfo*)pColumns->GetObject( nCur );
- if( !pCol || pCol->GetSubItem() == nSubItem )
- return pCol;
- rLeft += pCol->GetWidth();
- }
- return pCol;
-}
-
void SvxIconChoiceCtrl_Impl::DrawHighlightFrame(
OutputDevice* pOut, const Rectangle& rBmpRect, sal_Bool bHide )
{
@@ -4537,27 +4189,6 @@ IMPL_LINK( SvxIconChoiceCtrl_Impl, CallSelectHdlHdl, void*, EMPTYARG )
return 0;
}
-Point SvxIconChoiceCtrl_Impl::GetPopupMenuPosPixel() const
-{
- Point aResult;
- if( !GetSelectionCount() )
- return aResult;
-
- SvxIconChoiceCtrlEntry* pEntry = GetCurEntry();
- if( !pEntry || !pEntry->IsSelected() )
- {
- sal_uLong nNext;
- pEntry = GetFirstSelectedEntry( nNext );
- }
- if( pEntry )
- {
- Rectangle aRect( ((SvxIconChoiceCtrl_Impl*)this)->CalcBmpRect( pEntry ) );
- aResult = aRect.Center();
- aResult = pView->GetPixelPos( aResult );
- }
- return aResult;
-}
-
void SvxIconChoiceCtrl_Impl::SetOrigin( const Point& rPos, sal_Bool bDoNotUpdateWallpaper )
{
MapMode aMapMode( pView->GetMapMode() );
@@ -4576,28 +4207,6 @@ void SvxIconChoiceCtrl_Impl::SetOrigin( const Point& rPos, sal_Bool bDoNotUpdate
}
}
-sal_uLong SvxIconChoiceCtrl_Impl::GetGridCount( const Size& rSize, sal_Bool bCheckScrBars,
- sal_Bool bSmartScrBar ) const
-{
- Size aSize( rSize );
- if( bCheckScrBars && aHorSBar.IsVisible() )
- aSize.Height() -= nHorSBarHeight;
- else if( bSmartScrBar && (nWinBits & WB_ALIGN_LEFT) )
- aSize.Height() -= nHorSBarHeight;
-
- if( bCheckScrBars && aVerSBar.IsVisible() )
- aSize.Width() -= nVerSBarWidth;
- else if( bSmartScrBar && (nWinBits & WB_ALIGN_TOP) )
- aSize.Width() -= nVerSBarWidth;
-
- if( aSize.Width() < 0 )
- aSize.Width() = 0;
- if( aSize.Height() < 0 )
- aSize.Height() = 0;
-
- return IcnGridMap_Impl::GetGridCount( aSize, (sal_uInt16)nGridDX, (sal_uInt16)nGridDY );
-}
-
sal_Bool SvxIconChoiceCtrl_Impl::HandleShortCutKey( const KeyEvent& rKEvt )
{
StopEditTimer();