OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
opensave.cpp
Go to the documentation of this file.
1//----------------------------------------------------------------------------
2// ObjectWindows
3// Copyright (c) 1992, 1996 by Borland International, All Rights Reserved
4//
5/// \file
6/// Implementation of OpenSave abstract, FileOpen, FileSave Common Dialog
7/// classes
8//----------------------------------------------------------------------------
9#include <owl/pch.h>
10#include <owl/opensave.h>
11#include <owl/commctrl.h>
12#include <algorithm>
13#include <memory>
14#include <set>
15
16#if defined(BI_MULTI_THREAD_RTL)
17#include <owl/thread.h>
18#endif
19
20namespace owl {
21
23
24namespace
25{
26
27 //
28 // Converts a string read from a persistent stream to tstring. A null-pointer yields an empty
29 // string.
30 //
31 auto StreamedStringToTString_(const char* s) -> tstring
32 {
33 if (!s) return tstring{};
35 return tstring{_A2W(s)};
36 }
37
38 //
39 // Returns a pointer to a process-lifetime copy of the given string, or nullptr if the given
40 // string is null. Equal strings share the same copy, so repeated calls with the same strings do
41 // not use any more memory.
42 //
43 // This is used by TOpenSaveDialog::TData::Read to provide storage for the non-owning members
44 // InitialDir and DefExt, since TData has no way to own these strings itself.
45 //
46 auto InternStreamedString_(const char* s) -> LPCTSTR
47 {
48 if (!s) return nullptr;
49 static std::set<tstring> pool;
50#if defined(BI_MULTI_THREAD_RTL)
51 static TCriticalSection section;
52 TCriticalSection::TLock lock{section};
53#endif
54 return pool.insert(StreamedStringToTString_(s)).first->c_str();
55 }
56
57 //
58 // Converts the internal filter buffer, a sequence of null-terminated strings terminated by an
59 // empty string, back into the vertical line separated form accepted by SetFilter.
60 //
61 auto GetFilterSpecification_(LPCTSTR filter) -> tstring
62 {
63 auto s = tstring{};
64 for (auto p = filter; p && *p; p += ::_tcslen(p) + 1)
65 s.append(p).append(1, _T('|'));
66 return s;
67 }
68
69} // namespace
70
71
72//
73/// Constructs a TOpenSaveDialog::TData structure.
74//
76 uint32 flags,
77 LPCTSTR filter,
78 LPTSTR, // customFilter, // Dummy for backward compatibility.
79 LPCTSTR initialDir,
80 LPCTSTR defExt,
81 int maxPath,
82 int filterIndex,
83 uint32 flagsEx
84 )
85 : Flags(flags),
86 FlagsEx(flagsEx),
87 Error(0),
88 FileName(nullptr),
89 Filter(nullptr),
90 FilterIndex(filterIndex),
91 InitialDir(initialDir),
92 DefExt(defExt),
93 MaxPath(maxPath ? maxPath : _MAX_PATH)
94{
95 FileName = new tchar[MaxPath];
96 *FileName = 0;
97 SetFilter(filter);
98
99 // OFN_EXPLORER implies long names, but we include OFN_LONGNAMES in case OFN_EXPLORER is turned
100 // off by user code later.
101 //
102 Flags |= OFN_EXPLORER | OFN_LONGNAMES;
103}
104
105//
106/// String-aware overload
107/// TODO: Add string support for all parameters.
108//
110 uint32 flags,
111 const tstring& filter,
112 LPTSTR, // customFilter, // Dummy for backward compatibility.
113 LPCTSTR initialDir,
114 LPCTSTR defExt,
115 int maxPath,
116 int filterIndex,
117 uint32 flagsEx
118 )
119 : Flags(flags),
120 FlagsEx(flagsEx),
121 Error(0),
122 FileName(nullptr),
123 Filter(nullptr),
124 FilterIndex(filterIndex),
125 InitialDir(initialDir),
126 DefExt(defExt),
127 MaxPath(maxPath ? maxPath : _MAX_PATH)
128{
129 FileName = new tchar[MaxPath];
130 *FileName = 0;
131 SetFilter(filter);
132 Flags |= OFN_EXPLORER | OFN_LONGNAMES;
133}
134
135//
136//
137//
139 : Flags(src.Flags),
140 FlagsEx(src.FlagsEx),
141 Error(src.Error),
142 FileName(nullptr),
143 Filter(nullptr),
146 DefExt(src.DefExt),
147 MaxPath(src.MaxPath)
148{
150 SetFilter(src.Filter);
151}
152
153//
154/// Destructs a TOpenSaveDialog::TData structure.
155//
157{
158 delete[] FileName;
159 delete[] Filter;
160}
161
162//
163//
164//
167{
168 Flags = src.Flags;
169 FlagsEx = src.FlagsEx;
170 Error = src.Error;
173 DefExt = src.DefExt;
174 MaxPath = src.MaxPath;
175
176 delete[] FileName;
178
179 SetFilter(src.Filter);
180
181 return *this;
182}
183
184//
185/// Makes a copy of the filter list used to display the file names.
186//
187/// Set the file list box filter strings. Translates '|'s into 0s so that the
188/// string can be kept as a resource with imbeded '|'s like:
189/// \code
190/// "Text Files(*.txt)|*.TXT|All Files(*.*)|*.*|"
191/// \endcode
192/// Can also handle already processed filter strings.
193//
194void
196{
197 // Copy filter string
198 //
199 if (filter) {
200 delete[] Filter;
201 if (_tcschr(filter, _T('|'))) {
202 uint len = static_cast<uint>(::_tcslen(filter)) + 2; // one for each terminating 0
203 Filter = ::_tcscpy(new tchar[len], filter);
204 Filter[len-1] = 0; // in case trailing '|' is missing
205 }
206 else {
207 LPCTSTR p = filter;
208 while (*p)
209 p += ::_tcslen(p) + 1; // scan for 00 at end
210 uint len = uint(p - filter) + 1; // one more for last 0
211 Filter = new tchar[len];
212 memcpy(Filter, filter, sizeof(tchar) * len);
213 }
214 }
215 // Stomp |s with 0s
216 //
217 if (Filter) {
218 for (TCharIterator<tchar> i(Filter); ; i++) {
219 if (!*i.Current())
220 break;
221 if (*i.Current() == _T('|'))
222 *i.Current() = 0;
223 }
224 }
225}
226
227
228//----------------------------------------------------------------------------
229
232
233const uint TOpenSaveDialog::ShareViMsgId = ::RegisterWindowMessage(SHAREVISTRING);
234
235
236//
237/// Initializes a TOpenSaveDialog object with the current resource ID.
238//
239void
241{
242 memset(&ofn, 0, sizeof(OPENFILENAME));
243#if defined(OPENFILENAME_SIZE_VERSION_400)
244 ofn.lStructSize = TSystem::GetMajorVersion() < 5 ?
245 OPENFILENAME_SIZE_VERSION_400 : sizeof(OPENFILENAME);
246#else
247 ofn.lStructSize = sizeof(OPENFILENAME);
248#endif
249 ofn.hwndOwner = GetParentO() ? GetParentO()->GetHandle() : nullptr;
250 ofn.hInstance = *GetModule();
251 ofn.Flags = OFN_ENABLEHOOK | Data.Flags;
252 if (templateId) {
253 ofn.lpTemplateName = templateId;
254 ofn.Flags |= OFN_ENABLETEMPLATE;
255 }
256 else
257 ofn.Flags &= ~OFN_ENABLETEMPLATE;
258#if WINVER >= 0x500 && !defined(WINELIB)
259 ofn.FlagsEx = Data.FlagsEx;
260#endif
261 ofn.lpfnHook = nullptr;
262
263 ofn.lpstrFilter = Data.Filter;
264 ofn.nFilterIndex = Data.FilterIndex;
265 ofn.lpstrFile = Data.FileName;
266 ofn.nMaxFile = Data.MaxPath;
267 ofn.lpstrInitialDir = Data.InitialDir;
268 ofn.lpstrDefExt = Data.DefExt;
269}
270
271//
272/// Constructs an open save dialog box object with the supplied parent window, data,
273/// resource ID, title, and current module object.
274//
276:
277 TCommonDialog(parent, nullptr, module),
278 Data(data)
279{
280}
281
282//
283//
284//
286 TData& data,
287 TResId templateId,
288 LPCTSTR title,
289 TModule* module)
290:
291 TCommonDialog(parent, nullptr, module),
292 Data(data),
293 Title(title ? title : _T(""))
294{
295 Init(templateId);
296 ofn.lpstrTitle = title ? &Title[0] : nullptr;
297}
298
299//
300/// String-aware overload
301//
303 TWindow* parent,
304 TData& data,
305 TResId templateId,
306 const tstring& title,
307 TModule* module)
308:
309 TCommonDialog(parent, nullptr, module),
310 Data(data),
311 Title(title)
312{
313 Init(templateId);
314 ofn.lpstrTitle = &Title[0];
315}
316
317//
318/// Handles CDN_SHAREVIOLATION and the older SHAREVISTRING registered message.
319/// Calls the base implementation to handle all other messages.
320//
321INT_PTR
323{
324 const bool explorerStyle = ofn.Flags & OFN_EXPLORER;
325
326 // First check for the new message.
327 //
328 TNotify* n = (msg == WM_NOTIFY) ? reinterpret_cast<TNotify*>(param2) : nullptr;
329 if (n && n->code == CDN_SHAREVIOLATION)
330 {
331 WARN(!explorerStyle, _T("CDN_SHAREVIOLATION was sent to old-style dialog."));
332 int r = ShareViolation();
333
334 // The documentation for CDN_SHAREVIOLATION states that 0 should be
335 // returned to get the standard warning message for a sharing violation.
336 // It does not list OFN_SHAREWARN as a valid DWL_MSGRESULT value.
337 // Note that this causes the old SHAREVISTRING to be sent; see below.
338 //
339 if (r == OFN_SHAREWARN)
340 return 0;
341
342 CHECK(!OWL_STRICT || r == OFN_SHAREFALLTHROUGH || r == OFN_SHARENOWARN);
343 WARN(r != OFN_SHAREFALLTHROUGH && r != OFN_SHARENOWARN, _T("ShareViolation returned undefined value: ") << r);
344 return SetMsgResult(r);
345 }
346
347 // Now check for the old message.
348 //
349 else if (msg == TOpenSaveDialog::ShareViMsgId)
350 {
351 int r = ShareViolation();
352
353 // Do not handle SHAREVISTRING for Explorer-style dialogs.
354 // The message is a result of the default handling for CDN_SHAREVIOLATION, i.e.
355 // when CDN_SHAREVIOLATION returns 0 then SHAREVISTRING is sent.
356 //
357 if (explorerStyle)
358 {
359 WARN(r != OFN_SHAREWARN, _T("ShareViolation returned unexpected value in Explorer-style dialog:") << r);
360 return 0;
361 }
362
363 CHECK(!OWL_STRICT || r == OFN_SHAREFALLTHROUGH || r == OFN_SHARENOWARN || r == OFN_SHAREWARN);
364 WARN(r != OFN_SHAREFALLTHROUGH && r != OFN_SHARENOWARN && r != OFN_SHAREWARN,
365 _T("ShareViolation returned undefined value: ") << r);
366
367 // The documentation for SHAREVISTRING states that the result should be
368 // returned directly, rather than through DWL_MSGRESULT.
369 //
370 return r;
371 }
372
373 // If we get here, pass the message on to the base.
374 //
375 return TCommonDialog::DialogFunction(msg, param1, param2);
376}
377
378//
379/// If a sharing violation occurs when a file is opened or saved, ShareViolation is
380/// called to obtain a response. The default return value is OFN_SHAREWARN. Other
381/// sharing violation responses are listed in the following table.
382/// - \c \b OFN_SHAREFALLTHROUGH Specifies that the file name can be used and that the
383/// dialog box should return it to the application.
384/// - \c \b OFN_SHARENOWARN Instructs the dialog box to perform no further action with
385/// the file name and not to warn the user of the situation.
386/// - \c \b OFN_SHAREWARN This is the default response that is defined as 0. Instructs the
387/// dialog box to display a standard warning message.
388//
389int
391{
392 return OFN_SHAREWARN;
393}
394
395//----------------------------------------------------------------------------
396
397//
398/// Constructs and initializes the TFileOpen object based on information in the
399/// TOpenSaveDialog::TData data structure. The parent argument points to the dialog
400/// box's parent window. data is a reference to the TData object. templateID is the
401/// ID for a custom template. title is an optional title. module points to the
402/// module instance.
403//
405 TData& data,
406 TResId templateId,
407 LPCTSTR title,
408 TModule* module)
409:
410 TOpenSaveDialog(parent, data, templateId, title, module)
411{
412}
413
414//
415/// Creates the TFileOpenDialog object.
416//
417int
419{
420 ofn.lpfnHook = LPOFNHOOKPROC(StdDlgProc);
421 int ret = GetOpenFileName(&ofn);
422 Data.Error = CommDlgExtendedError();
423 if (ret) {
424 Data.Flags = ofn.Flags;
425 Data.FilterIndex = static_cast<int>(ofn.nFilterIndex);
426 }
427 return ret ? IDOK : IDCANCEL;
428}
429
430
431//----------------------------------------------------------------------------
432
433//
434/// Constructs and initializes the TFileOpen object based on the
435/// TOpenSaveDialog::TData structure, which contains information about the file
436/// name, file directory, and file name search filers.
437//
439 TData& data,
440 TResId templateId,
441 LPCTSTR title,
442 TModule* module)
443:
444 TOpenSaveDialog(parent, data, templateId, title, module)
445{
446}
447
448//
449/// Creates the TFileSaveDialog object.
450//
451int
453{
454 ofn.lpfnHook = LPOFNHOOKPROC(StdDlgProc);
455 int ret = GetSaveFileName(&ofn);
456 Data.Error = CommDlgExtendedError();
457 if (ret) {
458 Data.Flags = ofn.Flags;
459 Data.FilterIndex = ofn.nFilterIndex;
460 }
461 return ret ? IDOK : IDCANCEL;
462}
463
464
465//
466/// Reads the data from the given persistent stream.
467///
468/// MaxPath is not stored in the stream, so the current value is kept, and the file name buffer is
469/// reallocated with that size. A streamed file name that does not fit is truncated.
470///
471/// The filter is passed through SetFilter. If the streamed filter has no vertical line separator,
472/// it was written by an older version of Write, which only stored the first filter description.
473/// Such a filter is unusable, so the current filter is kept instead.
474///
475/// \note InitialDir and DefExt are non-owning pointers, so the streamed strings are stored in an
476/// internal process-lifetime string pool, in which equal strings are shared.
477//
478void
480{
482 using TStreamedString = std::unique_ptr<char[]>;
483
484 uint32 flags;
485 is >> flags;
486 const auto fileName = TStreamedString{is.readString()};
487 const auto filter = TStreamedString{is.freadString()};
488 const auto customFilter = TStreamedString{is.freadString()}; // Dummy for backward compatibility.
489 int filterIndex;
490 is >> filterIndex;
491 const auto initialDir = TStreamedString{is.freadString()};
492 const auto defExt = TStreamedString{is.freadString()};
493 uint32 flagsEx;
494 is >> flagsEx;
495 if (!is.good()) return; // Leave the object unchanged.
496
497 // Create the new file name buffer first, for strong exception safety.
498 //
499 const auto f = StreamedStringToTString_(fileName.get());
500 const auto n = std::min(f.size(), static_cast<size_t>(MaxPath - 1));
501 WARN(n < f.size(), _T("TOpenSaveDialog::TData::Read: File name truncated to MaxPath: ") << f);
502 const auto fileNameBuffer = new tchar[MaxPath];
503 f.copy(fileNameBuffer, n);
504 fileNameBuffer[n] = _T('\0');
505 delete[] FileName;
506 FileName = fileNameBuffer;
507
508 if (!filter || !*filter.get())
509 {
510 delete[] Filter;
511 Filter = nullptr;
512 }
513 else if (strchr(filter.get(), '|'))
514 SetFilter(StreamedStringToTString_(filter.get()));
515
516 Flags = flags;
517 FilterIndex = filterIndex;
518 InitialDir = InternStreamedString_(initialDir.get());
519 DefExt = InternStreamedString_(defExt.get());
520 FlagsEx = flagsEx;
521}
522
523//
524/// Writes the data to the given persistent stream.
525///
526/// The filter is written in the vertical line separated form accepted by SetFilter.
527//
528void
530{
532
533 os << Flags;
535 os.fwriteString(Filter ? _W2A(GetFilterSpecification_(Filter).c_str()) : nullptr);
536 const auto customFilter = nullptr; // Dummy for backward compatibility.
537 os.fwriteString(customFilter);
538 os << FilterIndex;
541 os << FlagsEx;
542}
543
544//
545/// Returns a vector containing the full paths of every file entry in member FileName.
546/// This function is only useful in conjunction with a multi-selection TFileOpenDialog using the
547/// Explorer style.
548///
549/// \note It is assumed that the buffer pointed to by member FileName contains a null-separated
550/// list of file names terminated by two null characters, as will be the case if filled in by a
551/// multi-selection Explorer-style TFileOpenDialog. Note that this function does not work unless
552/// the flags OFN_EXPLORER and OFN_ALLOWMULTISELECT were both set!
553///
554/// Usage:
555///
556/// \code
557/// void TBmpViewWindow::CmFileOpen()
558/// {
559/// TOpenSaveDialog::TData data
560/// {
561/// OFN_EXPLORER | OFN_ALLOWMULTISELECT | OFN_FILEMUSTEXIST, // flags
562/// "Bitmap Files (*.bmp)|*.bmp", // filter
563/// nullptr, // customFilter
564/// nullptr, // initialDir
565/// nullptr, // defExt
566/// 65536 // maxPath (ample buffer space for multiple selections)
567/// };
568/// TFileOpenDialog dlg{this, data};
569/// const auto r = dlg.Execute();
570/// if (CommDlgExtendedError() == FNERR_BUFFERTOOSMALL)
571/// {
572/// MessageBox("Buffer too small!", "File Open Error", MB_OK | MB_ICONEXCLAMATION);
573/// return;
574/// }
575/// if (r == IDOK)
576/// for (const auto& f : data.GetFileNames())
577/// OpenFile(f);
578/// }
579/// \endcode
580///
581/// \sa http://docs.microsoft.com/en-us/windows/desktop/api/Commdlg/ns-commdlg-tagofna
582//
584{
585 PRECONDITION((Flags & OFN_EXPLORER) && (Flags & OFN_ALLOWMULTISELECT));
586
587 auto v = std::vector<tstring>{};
588 auto p = FileName;
589 const auto d = tstring{p};
590 p += d.size() + 1;
591 CHECK(static_cast<int>(p - FileName) < MaxPath);
592
593 // NOTE: We assume double null-termination here, even for a single file!
594 //
595 if (*p == _T('\0'))
596 {
597 // We have a single entry, being the full path to the file.
598 //
599 v.push_back(d);
600 }
601 else
602 {
603 // We have multiple entries following the directory path, each being the bare file name without a path.
604 // Compose the full path to each file by prepending the directory path.
605 //
606 while (*p != _T('\0'))
607 {
608 const auto n = tstring{p};
609 const auto f = d + _T('\\') + n;
610 v.push_back(f);
611 p += n.size() + 1;
612 CHECK(static_cast<int>(p - FileName) < MaxPath);
613 }
614 }
615 return v;
616}
617
618} // OWL namespace
619/* ========================================================================== */
620
#define CHECK(condition)
Definition checks.h:239
#define WARN(condition, message)
Definition checks.h:273
#define PRECONDITION(condition)
Definition checks.h:227
TCommonDialog(TWindow *parent, LPCTSTR title=nullptr, TModule *module=nullptr)
Invokes a TWindow constructor, passing the parent window parent, and constructs a common dialog box t...
Definition commdial.cpp:34
This nested class handles locking and unlocking critical sections.
Definition thread.h:326
Lightweight intra-process thread synchronization.
Definition thread.h:308
bool SetMsgResult(TResult result)
Sets the dialog procedure message result (DWLP_MSGRESULT) and returns true.
Definition dialog.h:282
virtual INT_PTR DialogFunction(TMsgId, TParam1, TParam2)
Override this to process messages within the dialog function.
Definition dialog.cpp:353
static INT_PTR CALLBACK StdDlgProc(HWND, UINT, WPARAM, LPARAM) noexcept
Callback procs for hooking TDialog to native window.
Definition dialog.cpp:440
int DoExecute()
Creates the TFileOpenDialog object.
Definition opensave.cpp:418
TFileOpenDialog(TWindow *parent, TData &data, TResId templateId=0, LPCTSTR title=nullptr, TModule *module=nullptr)
Constructs and initializes the TFileOpen object based on information in the TOpenSaveDialog::TData da...
Definition opensave.cpp:404
int DoExecute()
Creates the TFileSaveDialog object.
Definition opensave.cpp:452
TFileSaveDialog(TWindow *parent, TData &data, TResId templateId=0, LPCTSTR title=nullptr, TModule *module=nullptr)
Constructs and initializes the TFileOpen object based on the TOpenSaveDialog::TData structure,...
Definition opensave.cpp:438
ObjectWindows dynamic-link libraries (DLLs) construct an instance of TModule, which acts as an object...
Definition module.h:78
TNotify is a thin wrapper around the NMHDR structure.
Definition commctrl.h:91
TOpenSaveDialog structure contains information about the user's file open or save selection.
Definition opensave.h:44
TData & operator=(const TData &src)
Definition opensave.cpp:166
TCHAR * FileName
Holds the name of the file to be saved or opened.
Definition opensave.h:112
TData(uint32 flags=0, LPCTSTR filter=nullptr, TCHAR *customFilter=nullptr, LPCTSTR initialDir=nullptr, LPCTSTR defExt=nullptr, int maxPath=0, int filterIndex=0, uint32 flagsEx=0)
Constructs a TOpenSaveDialog::TData structure.
Definition opensave.cpp:75
int FilterIndex
FilterIndex indicates which filter to use initially when displaying file names.
Definition opensave.h:119
void Read(ipstream &is)
Reads the data from the given persistent stream.
Definition opensave.cpp:479
LPCTSTR InitialDir
Directory to use initially when displaying file names.
Definition opensave.h:123
~TData()
Destructs a TOpenSaveDialog::TData structure.
Definition opensave.cpp:156
uint32 Flags
Flag contains one or more of the following constants:
Definition opensave.h:80
void Write(opstream &os)
Writes the data to the given persistent stream.
Definition opensave.cpp:529
TCHAR * Filter
Filter holds the filter to use initially when displaying file names.
Definition opensave.h:116
uint32 Error
This is the return value from calling CommDlgExtendedError after executing the dialog in the implemen...
Definition opensave.h:108
LPCTSTR DefExt
Default extension to use when saving file names.
Definition opensave.h:127
auto GetFileNames() const -> std::vector< tstring >
Returns a vector containing the full paths of every file entry in member FileName.
Definition opensave.cpp:583
void SetFilter(LPCTSTR filter=nullptr)
Makes a copy of the filter list used to display the file names.
Definition opensave.cpp:195
TOpenSaveDialog(TWindow *parent, TData &data, TResId templateId=0, LPCTSTR title=nullptr, TModule *module=nullptr)
Definition opensave.cpp:285
auto DialogFunction(TMsgId, TParam1, TParam2) -> INT_PTR override
Handles CDN_SHAREVIOLATION and the older SHAREVISTRING registered message.
Definition opensave.cpp:322
virtual int ShareViolation()
If a sharing violation occurs when a file is opened or saved, ShareViolation is called to obtain a re...
Definition opensave.cpp:390
void Init(TResId templateId)
Initializes a TOpenSaveDialog object with the current resource ID.
Definition opensave.cpp:240
static uint GetMajorVersion()
Definition system.cpp:81
TWindow, derived from TEventHandler and TStreamableBase, provides window-specific behavior and encaps...
Definition window.h:414
TWindow * GetParentO() const
Return the OWL's parent for this window.
Definition window.h:2006
TModule * GetModule() const
Returns a pointer to the module object.
Definition window.h:1841
HWND GetHandle() const
Returns the handle of the window.
Definition window.h:2020
ipstream, a specialized input stream derivative of pstream, is the base class for reading (extracting...
Definition objstrm.h:391
LPSTR readString()
Allocates a buffer large enough to contain the string at the current stream position and reads the st...
Definition objstrm.cpp:461
char * freadString()
Reads a string from the stream.
Definition objstrm.cpp:503
Base class for writing streamable objects.
Definition objstrm.h:480
void writeString(const char *)
Writes str to the stream.
Definition objstrm.cpp:810
void fwriteString(const char *str)
Writes the specified far character string (str) to the stream.
Definition objstrm.cpp:825
Definition of classes for CommonControl encapsulation.
#define _tcscpy
Definition cygwin.h:79
#define _MAX_PATH
Definition cygwin.h:97
#define _tcslen
Definition cygwin.h:74
#define _T(x)
Definition cygwin.h:51
#define _tcschr
Definition cygwin.h:85
#define DEFINE_RESPONSE_TABLE1(cls, base)
Macro to define a response table for a class with one base.
Definition eventhan.h:492
int good() const
Returns nonzero if no error states have been recorded for the stream (that is, no errors have occurre...
Definition objstrm.h:666
#define _W2A(lpw)
Definition memory.h:219
char * strnewdup(const char *s, size_t minAllocSize=0)
Definition memory.cpp:25
#define _A2W(lpw)
Definition memory.h:220
#define _USES_CONVERSION
Definition memory.h:217
Object Windows Library (OWLNext Core).
Definition animctrl.h:22
UINT TMsgId
Message ID type.
Definition dispatch.h:53
unsigned long uint32
Definition number.h:34
char tchar
Definition defs.h:77
LPARAM TParam2
Second parameter type.
Definition dispatch.h:55
WPARAM TParam1
First parameter type.
Definition dispatch.h:54
OWL_DIAGINFO
Definition animctrl.cpp:14
END_RESPONSE_TABLE
Definition button.cpp:26
std::string tstring
Definition defs.h:79
unsigned int uint
Definition number.h:25
Definition of TOpenSave abstract, TFileOpen, TFileSave common Dialog classes.
#define OWL_STRICT
Definition defs.h:220