From a3de32acc06cfcf9bb343a29c4b9854c92645f70 Mon Sep 17 00:00:00 2001 From: Matteo Casalin Date: Wed, 28 Oct 2015 11:23:36 +0100 Subject: Rename (private) Date::init and reuse it Change-Id: I3123876860cf6cce1e16c8f516f3d08fa7e15d83 --- include/tools/date.hxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include/tools') diff --git a/include/tools/date.hxx b/include/tools/date.hxx index 22cec9abf78f..ffb425c2a0ff 100644 --- a/include/tools/date.hxx +++ b/include/tools/date.hxx @@ -32,7 +32,7 @@ class TOOLS_DLLPUBLIC SAL_WARN_UNUSED Date { private: sal_uInt32 nDate; - void init( sal_uInt16 nDay, sal_uInt16 nMonth, sal_uInt16 nYear ) + void setDateFromDMY( sal_uInt16 nDay, sal_uInt16 nMonth, sal_uInt16 nYear ) { nDate = ( sal_uInt32( nDay % 100 ) ) + ( ( sal_uInt32( nMonth % 100 ) ) * 100 ) + ( ( sal_uInt32( nYear % 10000 ) ) * 10000); } @@ -56,11 +56,11 @@ public: Date( const Date& rDate ) { nDate = rDate.nDate; } Date( sal_uInt16 nDay, sal_uInt16 nMonth, sal_uInt16 nYear ) - { init(nDay, nMonth, nYear); } + { setDateFromDMY(nDay, nMonth, nYear); } Date( const css::util::Date& _rDate ) { SAL_WARN_IF(_rDate.Year < 0, "tools.datetime", "Negative year in css::util::Date to ::Date conversion"); - init(_rDate.Day, _rDate.Month, _rDate.Year); + setDateFromDMY(_rDate.Day, _rDate.Month, _rDate.Year); } Date( const css::util::DateTime& _rDateTime ); -- cgit