#endif
#include "wx/defs.h"
+
+#if wxUSE_DOC_VIEW_ARCHITECTURE
+
#include "wx/list.h"
#include "wx/cmndata.h"
#include "wx/string.h"
class WXDLLEXPORT wxConfigBase;
#if wxUSE_STD_IOSTREAM
- #include "wx/ioswrap.h"
+ #include "wx/iosfwrap.h"
#else
#include "wx/stream.h"
#endif
private:
DECLARE_ABSTRACT_CLASS(wxDocument)
+ DECLARE_NO_COPY_CLASS(wxDocument)
};
class WXDLLEXPORT wxView: public wxEvtHandler
wxDocument* m_viewDocument;
wxString m_viewTypeName;
wxWindow* m_viewFrame;
-
+
private:
DECLARE_ABSTRACT_CLASS(wxView)
+ DECLARE_NO_COPY_CLASS(wxView)
};
// Represents user interface (and other) properties of documents and views
private:
DECLARE_CLASS(wxDocTemplate)
+ DECLARE_NO_COPY_CLASS(wxDocTemplate)
};
// One object of this class may be created in an application, to manage all
// File history management
virtual void AddFileToHistory(const wxString& file);
- virtual void RemoveFileFromHistory(int i);
- virtual int GetNoHistoryFiles() const;
- virtual wxString GetHistoryFile(int i) const;
+ virtual void RemoveFileFromHistory(size_t i);
+ virtual size_t GetNoHistoryFiles() const;
+ virtual wxString GetHistoryFile(size_t i) const;
virtual void FileHistoryUseMenu(wxMenu *menu);
virtual void FileHistoryRemoveMenu(wxMenu *menu);
#if wxUSE_CONFIG
static wxDocManager* sm_docManager;
DECLARE_EVENT_TABLE()
+ DECLARE_NO_COPY_CLASS(wxDocManager)
};
// ----------------------------------------------------------------------------
private:
DECLARE_CLASS(wxDocChildFrame)
DECLARE_EVENT_TABLE()
+ DECLARE_NO_COPY_CLASS(wxDocChildFrame)
};
// ----------------------------------------------------------------------------
private:
DECLARE_CLASS(wxDocParentFrame)
DECLARE_EVENT_TABLE()
+ DECLARE_NO_COPY_CLASS(wxDocParentFrame)
};
// ----------------------------------------------------------------------------
private:
DECLARE_DYNAMIC_CLASS(wxDocPrintout)
+ DECLARE_NO_COPY_CLASS(wxDocPrintout)
};
#endif // wxUSE_PRINTING_ARCHITECTURE
class WXDLLEXPORT wxFileHistory : public wxObject
{
public:
- wxFileHistory(int maxFiles = 9);
+ wxFileHistory(size_t maxFiles = 9, wxWindowID idBase = wxID_FILE1);
~wxFileHistory();
// Operations
virtual void AddFileToHistory(const wxString& file);
- virtual void RemoveFileFromHistory(int i);
+ virtual void RemoveFileFromHistory(size_t i);
virtual int GetMaxFiles() const { return m_fileMaxFiles; }
virtual void UseMenu(wxMenu *menu);
virtual void AddFilesToMenu(wxMenu* menu); // Single menu
// Accessors
- virtual wxString GetHistoryFile(int i) const;
+ virtual wxString GetHistoryFile(size_t i) const;
// A synonym for GetNoHistoryFiles
- virtual int GetCount() const { return m_fileHistoryN; }
- int GetNoHistoryFiles() const { return m_fileHistoryN; }
+ virtual size_t GetCount() const { return m_fileHistoryN; }
+ size_t GetNoHistoryFiles() const { return m_fileHistoryN; }
wxList& GetMenus() const { return (wxList&) m_fileMenus; }
// Last n files
wxChar** m_fileHistory;
// Number of files saved
- int m_fileHistoryN;
+ size_t m_fileHistoryN;
// Menus to maintain (may need several for an MDI app)
wxList m_fileMenus;
// Max files to maintain
- int m_fileMaxFiles;
+ size_t m_fileMaxFiles;
private:
+ // The ID of the first history menu item (Doesn't have to be wxID_FILE1)
+ wxWindowID m_idBase;
+
DECLARE_DYNAMIC_CLASS(wxFileHistory)
+ DECLARE_NO_COPY_CLASS(wxFileHistory)
};
#if wxUSE_STD_IOSTREAM
// converts from/to a stream to/from a temporary file.
bool WXDLLEXPORT wxTransferFileToStream(const wxString& filename, wxOutputStream& stream);
bool WXDLLEXPORT wxTransferStreamToFile(wxInputStream& stream, const wxString& filename);
-#endif
+#endif // wxUSE_STD_IOSTREAM
+
+#endif // wxUSE_DOC_VIEW_ARCHITECTURE
#endif // _WX_DOCH__