diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-12-21 09:26:31 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-12-21 09:30:20 +0000 |
commit | c1c3ef64bca25183979f666aef51ab2854d628d8 (patch) | |
tree | 03a9e9518dcb9bb80833e79400b98dcbc80bfad3 /chart2 | |
parent | 725f7d0171985ff858af2436c553b4906bd060f6 (diff) |
callcatcher: remove some unused code
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/view/axes/DateHelper.cxx | 15 | ||||
-rw-r--r-- | chart2/source/view/inc/DateHelper.hxx | 1 |
2 files changed, 1 insertions, 15 deletions
diff --git a/chart2/source/view/axes/DateHelper.cxx b/chart2/source/view/axes/DateHelper.cxx index 247e0f66c16a..41f6aa13bc5e 100644 --- a/chart2/source/view/axes/DateHelper.cxx +++ b/chart2/source/view/axes/DateHelper.cxx @@ -41,25 +41,12 @@ bool DateHelper::IsInSameYear( const Date& rD1, const Date& rD2 ) { return rD1.GetYear() == rD2.GetYear(); } + bool DateHelper::IsInSameMonth( const Date& rD1, const Date& rD2 ) { return (rD1.GetYear() == rD2.GetYear()) && (rD1.GetMonth() == rD2.GetMonth()); } -long DateHelper::GetMonthsBetweenDates( Date aD1, Date aD2 ) -{ - Date aHelp = aD1; - long nSign = 1; - if( aD1 < aD2 ) - { - aD1 = aD2; - aD2 = aHelp; - nSign = -1; - } - - return nSign*( ( aD1.GetMonth() - aD2.GetMonth() ) - + ( aD1.GetYear() - aD2.GetYear() )*12 ); -} Date DateHelper::GetDateSomeMonthsAway( const Date& rD, long nMonthDistance ) { diff --git a/chart2/source/view/inc/DateHelper.hxx b/chart2/source/view/inc/DateHelper.hxx index 7891035fc338..427a230f2bbe 100644 --- a/chart2/source/view/inc/DateHelper.hxx +++ b/chart2/source/view/inc/DateHelper.hxx @@ -46,7 +46,6 @@ public: static bool IsInSameYear( const Date& rD1, const Date& rD2 ); static bool IsInSameMonth( const Date& rD1, const Date& rD2 ); - static long GetMonthsBetweenDates( Date aD1, Date aD2 ); static Date GetDateSomeMonthsAway( const Date& rD, long nMonthDistance ); static Date GetDateSomeYearsAway( const Date& rD, long nYearDistance ); static bool IsLessThanOneMonthAway( const Date& rD1, const Date& rD2 ); |