1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include <svl/srchitem.hxx>
21 #include <sfx2/app.hxx>
22 #include <svx/svxids.hrc>
24 #include <comphelper/classids.hxx>
25 #include <sfx2/objface.hxx>
27 #include <sfx2/msg.hxx>
30 #include "swtypes.hxx"
32 #include "shellio.hxx"
33 // just because of the itemtypes
38 #include "swslots.hxx"
43 SFX_IMPL_INTERFACE( SwWebDocShell
, SfxObjectShell
, SW_RES(0) )
47 TYPEINIT1(SwWebDocShell
, SwDocShell
);
49 SFX_IMPL_OBJECTFACTORY(SwWebDocShell
, SvGlobalName(SO3_SWWEB_CLASSID
), SFXOBJECTSHELL_STD_NORMAL
|SFXOBJECTSHELL_HASMENU
, "swriter/web" )
51 SwWebDocShell::SwWebDocShell(SfxObjectCreateMode eMode
) :
57 SwWebDocShell::~SwWebDocShell()
63 void SwWebDocShell::FillClass( SvGlobalName
* pClassName
,
64 sal_uInt32
* pClipFormat
,
65 OUString
* /*pAppName*/,
66 OUString
* pLongUserName
,
69 sal_Bool bTemplate
/* = sal_False */) const
72 OSL_ENSURE( bTemplate
== sal_False
, "No template for Writer Web" );
74 if (nVersion
== SOFFICE_FILEFORMAT_60
)
76 *pClassName
= SvGlobalName( SO3_SWWEB_CLASSID_60
);
77 *pClipFormat
= SOT_FORMATSTR_ID_STARWRITERWEB_60
;
78 *pLongUserName
= SW_RESSTR(STR_WRITER_WEBDOC_FULLTYPE
);
80 else if (nVersion
== SOFFICE_FILEFORMAT_8
)
82 *pClassName
= SvGlobalName( SO3_SWWEB_CLASSID_60
);
83 *pClipFormat
= SOT_FORMATSTR_ID_STARWRITERWEB_8
;
84 *pLongUserName
= SW_RESSTR(STR_WRITER_WEBDOC_FULLTYPE
);
86 *pUserName
= SW_RESSTR(STR_HUMAN_SWWEBDOC_NAME
);
91 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */