From 1b694dad643334ec1bab3f823dcd68f44a05ebe3 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 24 Aug 2017 22:14:27 +0200 Subject: loplugin:unusedmethods Change-Id: Iaaf9092ec4d6189492906648b84494d087fed81f Reviewed-on: https://gerrit.libreoffice.org/41539 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svtools/source/control/calendar.cxx | 49 ------------------------------------- svtools/source/control/ruler.cxx | 5 ---- 2 files changed, 54 deletions(-) (limited to 'svtools/source/control') diff --git a/svtools/source/control/calendar.cxx b/svtools/source/control/calendar.cxx index 828e3af37c0d..911f464eac3d 100644 --- a/svtools/source/control/calendar.cxx +++ b/svtools/source/control/calendar.cxx @@ -48,8 +48,6 @@ #define SPIN_OFFX 4 #define SPIN_OFFY TITLE_BORDERY -#define WEEKNUMBER_HEIGHT 85 - #define CALENDAR_HITTEST_DAY ((sal_uInt16)0x0001) #define CALENDAR_HITTEST_MONTHTITLE ((sal_uInt16)0x0004) #define CALENDAR_HITTEST_PREV ((sal_uInt16)0x0008) @@ -69,11 +67,6 @@ static void ImplCalendarSelectDate( IntDateSet* pTable, const Date& rDate, bool -inline void ImplCalendarClearSelectDate( IntDateSet* pTable ) -{ - pTable->clear(); -} - void Calendar::ImplInit( WinBits nWinStyle ) { mpSelectTable = new IntDateSet; @@ -219,16 +212,6 @@ DayOfWeek Calendar::ImplGetWeekStart() const return eDay; } -void Calendar::ImplGetWeekFont( vcl::Font& rFont ) -{ - // weeknumber is displayed in WEEKNUMBER_HEIGHT%-Fontheight - Size aFontSize = rFont.GetFontSize(); - aFontSize.Height() *= WEEKNUMBER_HEIGHT; - aFontSize.Height() /= 100; - rFont.SetFontSize( aFontSize ); - rFont.SetWeight( WEIGHT_NORMAL ); -} - void Calendar::ImplFormat() { if ( !mbFormat ) @@ -1365,38 +1348,6 @@ void Calendar::Select() maSelectHdl.Call( this ); } -void Calendar::SelectDate( const Date& rDate, bool bSelect ) -{ - if ( !rDate.IsValidAndGregorian() ) - return; - - std::unique_ptr pOldSel; - - pOldSel.reset(new IntDateSet( *mpSelectTable )); - - ImplCalendarSelectDate( mpSelectTable, rDate, bSelect ); - - if ( pOldSel ) - ImplUpdateSelection( pOldSel.get() ); -} - -void Calendar::SetNoSelection() -{ - std::unique_ptr pOldSel; - - pOldSel.reset(new IntDateSet( *mpSelectTable )); - - ImplCalendarClearSelectDate( mpSelectTable ); - - if ( pOldSel ) - ImplUpdateSelection( pOldSel.get() ); -} - -bool Calendar::IsDateSelected( const Date& rDate ) const -{ - return mpSelectTable->find( rDate.GetDate() ) != mpSelectTable->end(); -} - Date Calendar::GetFirstSelectedDate() const { if ( !mpSelectTable->empty() ) diff --git a/svtools/source/control/ruler.cxx b/svtools/source/control/ruler.cxx index f4deadc572e1..8392ba2fd678 100644 --- a/svtools/source/control/ruler.cxx +++ b/svtools/source/control/ruler.cxx @@ -2678,11 +2678,6 @@ void Ruler::SetTextRTL(bool bRTL) } -long Ruler::GetPageWidth() const -{ - return mpData->nPageWidth; -} - long Ruler::GetPageOffset() const { return mpData->nPageOff; -- cgit