]> git.saurik.com Git - wxWidgets.git/blame - src/common/arcfind.cpp
wxDialogBase only has one ctor, so just do initialization in ctor instead of Init()
[wxWidgets.git] / src / common / arcfind.cpp
CommitLineData
1b79dad4
MW
1/////////////////////////////////////////////////////////////////////////////
2// Name: src/common/arcfind.cpp
3// Purpose: Streams for archive formats
4// Author: Mike Wetherell
1b79dad4
MW
5// Copyright: (c) Mike Wetherell
6// Licence: wxWindows licence
7/////////////////////////////////////////////////////////////////////////////
8
9// For compilers that support precompilation, includes "wx.h".
10#include "wx/wxprec.h"
11
12#ifdef __BORLANDC__
13 #pragma hdrstop
14#endif
15
16#if wxUSE_ARCHIVE_STREAMS
17
18#include "wx/archive.h"
19
20// These functions are in a separate file so that statically linked apps
21// that do not call them to search for archive handlers will only link in
22// the archive classes they use.
23
24const wxArchiveClassFactory *
86501081 25wxArchiveClassFactory::Find(const wxString& protocol, wxStreamProtocolType type)
1b79dad4
MW
26{
27 for (const wxArchiveClassFactory *f = GetFirst(); f; f = f->GetNext())
28 if (f->CanHandle(protocol, type))
29 return f;
30
31 return NULL;
32}
33
34// static
35const wxArchiveClassFactory *wxArchiveClassFactory::GetFirst()
36{
37 if (!sm_first)
38 wxUseArchiveClasses();
39 return sm_first;
40}
41
42#endif // wxUSE_ARCHIVE_STREAMS