2010-10-12 15:53:47 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2004-06-28 13:05:08 +00:00
|
|
|
/*************************************************************************
|
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2010-02-12 15:01:35 +01:00
|
|
|
* Copyright 2000, 2010 Oracle and/or its affiliates.
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* OpenOffice.org - a multi-platform office productivity suite
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* This file is part of OpenOffice.org.
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* OpenOffice.org is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU Lesser General Public License version 3
|
|
|
|
* only, as published by the Free Software Foundation.
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* OpenOffice.org is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU Lesser General Public License version 3 for more details
|
|
|
|
* (a copy is included in the LICENSE file that accompanied this code).
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
2008-04-10 23:05:04 +00:00
|
|
|
* You should have received a copy of the GNU Lesser General Public License
|
|
|
|
* version 3 along with OpenOffice.org. If not, see
|
|
|
|
* <http://www.openoffice.org/license.html>
|
|
|
|
* for a copy of the LGPLv3 License.
|
2004-06-28 13:05:08 +00:00
|
|
|
*
|
|
|
|
************************************************************************/
|
|
|
|
|
2006-09-17 03:41:53 +00:00
|
|
|
// MARKER(update_precomp.py): autogen include statement, do not remove
|
|
|
|
#include "precompiled_svx.hxx"
|
2010-04-20 15:55:51 +02:00
|
|
|
#include <svx/swframeposstrings.hxx>
|
2004-06-28 13:05:08 +00:00
|
|
|
#include <tools/rc.hxx>
|
|
|
|
#include <tools/debug.hxx>
|
2007-06-27 16:42:56 +00:00
|
|
|
#include <svx/dialmgr.hxx>
|
|
|
|
#include <svx/dialogs.hrc>
|
2004-06-28 13:05:08 +00:00
|
|
|
|
|
|
|
class SvxSwFramePosString_Impl : public Resource
|
|
|
|
{
|
|
|
|
friend class SvxSwFramePosString;
|
|
|
|
String aStrings[SvxSwFramePosString::STR_MAX];
|
|
|
|
public:
|
|
|
|
SvxSwFramePosString_Impl();
|
|
|
|
};
|
|
|
|
SvxSwFramePosString_Impl::SvxSwFramePosString_Impl() :
|
|
|
|
Resource(SVX_RES(RID_SVXSW_FRAMEPOSITIONS))
|
|
|
|
{
|
2011-01-10 16:11:35 +01:00
|
|
|
for(sal_uInt16 i = 0; i < SvxSwFramePosString::STR_MAX; i++)
|
2004-06-28 13:05:08 +00:00
|
|
|
{
|
|
|
|
//string ids have to start at 1
|
2007-04-26 06:43:51 +00:00
|
|
|
aStrings[i] = String(SVX_RES(i + 1));
|
2004-06-28 13:05:08 +00:00
|
|
|
}
|
|
|
|
FreeResource();
|
|
|
|
}
|
|
|
|
|
|
|
|
SvxSwFramePosString::SvxSwFramePosString() :
|
|
|
|
pImpl(new SvxSwFramePosString_Impl)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
SvxSwFramePosString::~SvxSwFramePosString()
|
|
|
|
{
|
|
|
|
delete pImpl;
|
|
|
|
}
|
|
|
|
|
|
|
|
const String& SvxSwFramePosString::GetString(StringId eId)
|
|
|
|
{
|
2008-11-10 15:06:12 +00:00
|
|
|
DBG_ASSERT(eId >= 0 && eId < STR_MAX, "invalid StringId");
|
2004-06-28 13:05:08 +00:00
|
|
|
if(!(eId >= 0 && eId < STR_MAX))
|
|
|
|
eId = LEFT;
|
|
|
|
return pImpl->aStrings[eId];
|
|
|
|
}
|
2010-10-12 15:53:47 +02:00
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|