summaryrefslogtreecommitdiff
path: root/sw/source/ui/app/docsh.cxx
diff options
context:
space:
mode:
authorjp <jp@openoffice.org>2001-05-16 14:27:01 +0000
committerjp <jp@openoffice.org>2001-05-16 14:27:01 +0000
commitf17d119b9ff80d0d004d4fa9a51406442e6db0e4 (patch)
tree7a711c4531b491d0146678508907fc3254790261 /sw/source/ui/app/docsh.cxx
parent8cff975a9a9279c5d5ae492f046f5295f78c212b (diff)
Bug #87096#: GetState - use Numberformatter only if it's needed
Diffstat (limited to 'sw/source/ui/app/docsh.cxx')
-rw-r--r--sw/source/ui/app/docsh.cxx13
1 files changed, 9 insertions, 4 deletions
diff --git a/sw/source/ui/app/docsh.cxx b/sw/source/ui/app/docsh.cxx
index bfe9644787cd..4b84039f1a13 100644
--- a/sw/source/ui/app/docsh.cxx
+++ b/sw/source/ui/app/docsh.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: docsh.cxx,v $
*
- * $Revision: 1.14 $
+ * $Revision: 1.15 $
*
- * last change: $Author: jp $ $Date: 2001-03-23 15:51:47 $
+ * last change: $Author: jp $ $Date: 2001-05-16 15:27:01 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -1241,8 +1241,13 @@ void SwDocShell::GetState(SfxItemSet& rSet)
break;
case SID_ATTR_YEAR2000:
- rSet.Put(SfxUInt16Item(nWhich, pDoc->GetNumberFormatter(TRUE)->GetYear2000()));
- break;
+ {
+ const SvNumberFormatter* pFmtr = pDoc->GetNumberFormatter(FALSE);
+ rSet.Put( SfxUInt16Item( nWhich,
+ pFmtr ? pFmtr->GetYear2000()
+ : SvNumberFormatter::GetYear2000Default() ));
+ }
+ break;
default: DBG_ASSERT(!this,"Hier darfst Du nicht hinein!");