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 #ifndef INCLUDED_EMBEDSERV_SOURCE_INC_EMBEDDOCACCESS_HXX
21 #define INCLUDED_EMBEDSERV_SOURCE_INC_EMBEDDOCACCESS_HXX
23 #define OLESERV_SAVEOBJECT 1
24 #define OLESERV_CLOSE 2
25 #define OLESERV_NOTIFY 3
26 #define OLESERV_NOTIFYCLOSING 4
27 #define OLESERV_SHOWOBJECT 5
28 #define OLESERV_DEACTIVATE 6
32 #pragma warning(disable : 4265)
34 #pragma clang diagnostic push
35 #pragma clang diagnostic ignored "-Wall"
36 #pragma clang diagnostic ignored "-Wextra"
37 #pragma clang diagnostic ignored "-Wmicrosoft"
38 #pragma clang diagnostic ignored "-Wnon-virtual-dtor"
42 #pragma clang diagnostic pop
45 #include <cppuhelper/weak.hxx>
47 class EmbedDocument_Impl
;
48 struct LockedEmbedDocument_Impl
51 EmbedDocument_Impl
* m_pEmbedDocument
;
54 LockedEmbedDocument_Impl();
55 LockedEmbedDocument_Impl( EmbedDocument_Impl
* pEmbedDocument
);
56 LockedEmbedDocument_Impl( const LockedEmbedDocument_Impl
& aDocLock
);
58 ~LockedEmbedDocument_Impl();
60 LockedEmbedDocument_Impl
& operator=( const LockedEmbedDocument_Impl
& aDocLock
);
62 EmbedDocument_Impl
* GetEmbedDocument() { return m_pEmbedDocument
; }
64 void ExecuteMethod( sal_Int16 nId
);
67 class EmbeddedDocumentInstanceAccess_Impl
: public ::cppu::OWeakObject
69 ::osl::Mutex m_aMutex
;
70 EmbedDocument_Impl
* m_pEmbedDocument
;
73 EmbeddedDocumentInstanceAccess_Impl( EmbedDocument_Impl
* pDoc
)
74 : m_pEmbedDocument( pDoc
)
77 LockedEmbedDocument_Impl
GetEmbedDocument();
78 void ClearEmbedDocument();
83 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */