]> git.saurik.com Git - wxWidgets.git/blame - src/palmos/clipbrd.cpp
Fixes/makefiles for building data view control on Windows
[wxWidgets.git] / src / palmos / clipbrd.cpp
CommitLineData
ffecfa5a 1/////////////////////////////////////////////////////////////////////////////
e2731512 2// Name: src/palmos/clipbrd.cpp
ffecfa5a 3// Purpose: Clipboard functionality
e2731512 4// Author: William Osborne - minimal working wxPalmOS port
ffecfa5a
JS
5// Modified by:
6// Created: 10/13/04
e2731512 7// RCS-ID: $Id$
ffecfa5a
JS
8// Copyright: (c) William Osborne
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12// ===========================================================================
13// declarations
14// ===========================================================================
15
16// ---------------------------------------------------------------------------
17// headers
18// ---------------------------------------------------------------------------
19
ffecfa5a
JS
20// For compilers that support precompilation, includes "wx.h".
21#include "wx/wxprec.h"
22
23#ifdef __BORLANDC__
24 #pragma hdrstop
25#endif
26
ffecfa5a
JS
27#if wxUSE_CLIPBOARD
28
29#ifndef WX_PRECOMP
30 #include "wx/object.h"
31 #include "wx/event.h"
32 #include "wx/app.h"
33 #include "wx/frame.h"
34 #include "wx/bitmap.h"
35 #include "wx/utils.h"
36 #include "wx/intl.h"
37#endif
38
39#if wxUSE_METAFILE
40 #include "wx/metafile.h"
41#endif
42
43#include "wx/log.h"
44#include "wx/clipbrd.h"
45
46#include <string.h>
47
48#include "wx/palmos/private.h"
49
50#if wxUSE_WXDIB
51#include "wx/palmos/dib.h"
52#endif
53
54#if wxUSE_DATAOBJ
55 #include "wx/dataobj.h"
56#endif
57
58#if wxUSE_OLE && !defined(__WXWINCE__)
59 // use OLE clipboard
60 #define wxUSE_OLE_CLIPBOARD 1
61#else // !wxUSE_DATAOBJ
62 // use Win clipboard API
63 #define wxUSE_OLE_CLIPBOARD 0
64#endif
65
66#if wxUSE_OLE_CLIPBOARD
67 #include <ole2.h>
68#endif // wxUSE_OLE_CLIPBOARD
69
70// ===========================================================================
71// implementation
72// ===========================================================================
73
74// ---------------------------------------------------------------------------
75// old-style clipboard functions
76// ---------------------------------------------------------------------------
77
78static bool gs_wxClipboardIsOpen = FALSE;
79
80bool wxOpenClipboard()
81{
82 return false;
83}
84
85bool wxCloseClipboard()
86{
87 return false;
88}
89
90bool wxEmptyClipboard()
91{
92 return false;
93}
94
95bool wxIsClipboardOpened()
96{
97 return false;
98}
99
100bool wxIsClipboardFormatAvailable(wxDataFormat dataFormat)
101{
102 return false;
103}
104
105
106bool wxSetClipboardData(wxDataFormat dataFormat,
107 const void *data,
108 int width, int height)
109{
110 return false;
111}
112
113void *wxGetClipboardData(wxDataFormat dataFormat, long *len)
114{
115 void *retval = NULL;
116
117 return retval;
118}
119
120wxDataFormat wxEnumClipboardFormats(wxDataFormat dataFormat)
121{
122 return (wxDataFormat::NativeFormat)::EnumClipboardFormats(dataFormat);
123}
124
125int wxRegisterClipboardFormat(wxChar *formatName)
126{
127 return ::RegisterClipboardFormat(formatName);
128}
129
130bool wxGetClipboardFormatName(wxDataFormat dataFormat,
131 wxChar *formatName,
132 int maxCount)
133{
134 return false;
135}
136
137// ---------------------------------------------------------------------------
138// wxClipboard
139// ---------------------------------------------------------------------------
140
141IMPLEMENT_DYNAMIC_CLASS(wxClipboard, wxObject)
142
143wxClipboard::wxClipboard()
144{
145 m_clearOnExit = FALSE;
146 m_isOpened = FALSE;
147}
148
149wxClipboard::~wxClipboard()
150{
151 if ( m_clearOnExit )
152 {
153 Clear();
154 }
155}
156
157void wxClipboard::Clear()
158{
159}
160
161bool wxClipboard::Flush()
162{
163 return false;
164}
165
166bool wxClipboard::Open()
167{
168 return wxOpenClipboard();
169}
170
171bool wxClipboard::IsOpened() const
172{
173 return wxIsClipboardOpened();
174}
175
176bool wxClipboard::SetData( wxDataObject *data )
177{
178 return false;
179}
180
181bool wxClipboard::AddData( wxDataObject *data )
182{
183 return false;
184}
185
186void wxClipboard::Close()
187{
188 wxCloseClipboard();
189}
190
191bool wxClipboard::IsSupported( wxDataFormat format )
192{
193 return wxIsClipboardFormatAvailable(format);
194}
195
196bool wxClipboard::GetData( wxDataObject& data )
197{
198 return false;
199}
200
201#endif // wxUSE_CLIPBOARD