LibreOffice Module svl (master) 1
ddeimp.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19
20#ifndef INCLUDED_SVL_SOURCE_SVDDE_DDEIMP_HXX
21#define INCLUDED_SVL_SOURCE_SVDDE_DDEIMP_HXX
22
23#if !defined WIN32_LEAN_AND_MEAN
24# define WIN32_LEAN_AND_MEAN
25#endif
26#include <windows.h>
27#include <ddeml.h>
28
29#include <rtl/ustring.hxx>
30#include <svl/svdde.hxx>
31#include <vector>
32
33
35{
38};
39
40
42{
43public:
44 static HDDEDATA CALLBACK CliCallback
45 ( UINT, UINT, HCONV, HSZ, HSZ, HDDEDATA, ULONG_PTR, ULONG_PTR );
46 static HDDEDATA CALLBACK SvrCallback
47 ( UINT, UINT, HCONV, HSZ, HSZ, HDDEDATA, ULONG_PTR, ULONG_PTR );
48 static DdeService* FindService( HSZ );
49 static DdeTopic* FindTopic( DdeService&, HSZ );
50 static DdeItem* FindItem( DdeTopic&, HSZ );
51 static void DisconnectTopic(DdeTopic &, HCONV);
52 static void IncMonitor(DdeItem *pItem, HCONV);
53 static void DecMonitor(DdeItem *pItem, HCONV);
54};
55
56
58{
59private:
60 OUString m_aString;
61protected:
63 DWORD hInst;
64
65public:
66 DdeString( DWORD, const OUString& );
67 ~DdeString();
68
69 bool operator==( HSZ ) const;
70 HSZ getHSZ();
71 const OUString & toOUString() const { return m_aString; }
72};
73
74
76{
77 HDDEDATA hData;
78 void const * pData;
79 DWORD nData;
81};
82
83class DdeConnection;
84
86{
87public:
88 sal_uInt16 nRefCount;
89 std::vector<DdeConnection*> aConnections;
90 // Server
94 // Client
97
99 : nRefCount(0)
100 , hDdeInstSvr(0)
101 , nInstanceSvr(0)
102 , pServicesSvr(nullptr)
103 , hDdeInstCli(0)
104 , nInstanceCli(0)
105 {
106 }
107 DdeInstData(const DdeInstData&) = delete;
109};
110
113void ImpDeinitInstData();
114
115#endif // INCLUDED_SVL_SOURCE_SVDDE_DDEIMP_HXX
116
117/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
DdeInstData & operator=(const DdeInstData &)=delete
std::vector< DdeConnection * > aConnections
Definition: ddeimp.hxx:89
DWORD hDdeInstSvr
Definition: ddeimp.hxx:91
sal_uInt16 nRefCount
Definition: ddeimp.hxx:88
short nInstanceSvr
Definition: ddeimp.hxx:92
short nInstanceCli
Definition: ddeimp.hxx:96
DdeInstData()
Definition: ddeimp.hxx:98
DWORD hDdeInstCli
Definition: ddeimp.hxx:95
DdeInstData(const DdeInstData &)=delete
DdeServices * pServicesSvr
Definition: ddeimp.hxx:93
static HDDEDATA CALLBACK SvrCallback(UINT, UINT, HCONV, HSZ, HSZ, HDDEDATA, ULONG_PTR, ULONG_PTR)
Definition: ddesvr.cxx:48
static void DecMonitor(DdeItem *pItem, HCONV)
Definition: ddesvr.cxx:657
static DdeTopic * FindTopic(DdeService &, HSZ)
Definition: ddesvr.cxx:306
static DdeService * FindService(HSZ)
Definition: ddesvr.cxx:295
static HDDEDATA CALLBACK CliCallback(UINT, UINT, HCONV, HSZ, HSZ, HDDEDATA, ULONG_PTR, ULONG_PTR)
Definition: ddecli.cxx:58
static void DisconnectTopic(DdeTopic &, HCONV)
Definition: ddesvr.cxx:550
static void IncMonitor(DdeItem *pItem, HCONV)
Definition: ddesvr.cxx:632
static DdeItem * FindItem(DdeTopic &, HSZ)
Definition: ddesvr.cxx:318
DdeString(DWORD, const OUString &)
Definition: ddestrg.cxx:25
HSZ getHSZ()
Definition: ddestrg.cxx:42
bool operator==(HSZ) const
Definition: ddestrg.cxx:37
OUString m_aString
Definition: ddeimp.hxx:60
~DdeString()
Definition: ddestrg.cxx:31
DWORD hInst
Definition: ddeimp.hxx:63
const OUString & toOUString() const
Definition: ddeimp.hxx:71
HSZ hString
Definition: ddeimp.hxx:62
void ImpDeinitInstData()
Definition: ddecli.cxx:45
DdeInstData * ImpInitInstData()
Definition: ddecli.cxx:39
DdeInstData * ImpGetInstData()
Definition: ddecli.cxx:34
SotClipboardFormatId
#define CALLBACK
#define HCONV(x)
DdeTopic * pTopic
Definition: ddeimp.hxx:37
HCONV hConv
Definition: ddeimp.hxx:36
DWORD nData
Definition: ddeimp.hxx:79
void const * pData
Definition: ddeimp.hxx:78
HDDEDATA hData
Definition: ddeimp.hxx:77
SotClipboardFormatId nFmt
Definition: ddeimp.hxx:80
::std::vector< DdeService * > DdeServices
Definition: svdde.hxx:41