xref: /aoo4110/main/sw/source/ui/shells/olesh.cxx (revision b1cdbd2c)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 // MARKER(update_precomp.py): autogen include statement, do not remove
25 #include "precompiled_sw.hxx"
26 
27 
28 #include <sfx2/app.hxx>
29 #include <sfx2/request.hxx>
30 #include <sfx2/objface.hxx>
31 #include <sfx2/objitem.hxx>
32 #include <sfx2/sidebar/EnumContext.hxx>
33 #include <wrtsh.hxx>
34 #include <view.hxx>
35 #ifndef _HELPID_H
36 #include <helpid.h>
37 #endif
38 #ifndef _GLOBALS_HRC
39 #include <globals.hrc>
40 #endif
41 #include <frmsh.hxx>
42 #ifndef _OLESH_HXX
43 #include <olesh.hxx>
44 #endif
45 
46 #ifndef _CMDID_H
47 #include <cmdid.h>
48 #endif
49 #ifndef _POPUP_HRC
50 #include <popup.hrc>
51 #endif
52 #ifndef _SHELLS_HRC
53 #include <shells.hrc>
54 #endif
55 
56 
57 #define SwOleShell
58 #include <sfx2/msg.hxx>
59 #include <swslots.hxx>
60 
61 
SFX_IMPL_INTERFACE(SwOleShell,SwFrameShell,SW_RES (STR_SHELLNAME_OBJECT))62 SFX_IMPL_INTERFACE(SwOleShell, SwFrameShell, SW_RES(STR_SHELLNAME_OBJECT))
63 {
64 	SFX_POPUPMENU_REGISTRATION(SW_RES(MN_OLE_POPUPMENU));
65 	SFX_OBJECTBAR_REGISTRATION(SFX_OBJECTBAR_OBJECT, SW_RES(RID_OLE_TOOLBOX));
66 }
67 
68 
SwOleShell(SwView & _rView)69 SwOleShell::SwOleShell(SwView &_rView) :
70     SwFrameShell(_rView)
71 
72 {
73 	SetName(String::CreateFromAscii("Object"));
74 	SetHelpId(SW_OLESHELL);
75     SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_OLE));
76 }
77