| 1 |
#ifndef IMPORTFROMXRC_H |
| 2 |
#define IMPORTFROMXRC_H |
| 3 |
|
| 4 |
#include "import_dlg.h" |
| 5 |
#include "wxc_widget.h" |
| 6 |
|
| 7 |
class wxWindow; |
| 8 |
class NotebookPageWrapper; |
| 9 |
|
| 10 |
class ImportFromXrc |
| 11 |
{ |
| 12 |
public: |
| 13 |
ImportFromXrc(wxWindow* parent); |
| 14 |
~ImportFromXrc(); |
| 15 |
|
| 16 |
bool ImportProject(ImportDlg::ImportFileData& data) const; |
| 17 |
bool GetProject() const; |
| 18 |
static void DoProcessButtonNode(const wxXmlNode* node, wxcWidget* wrapper); |
| 19 |
static void ProcessBitmapProperty(const wxXmlNode* node, wxcWidget* wrapper, |
| 20 |
const wxString& property = PROP_BITMAP_PATH, const wxString& client_hint = ""); |
| 21 |
void ProcessNamedNode(wxXmlNode* node, wxcWidget* parentwrapper, |
| 22 |
const wxString& name) const; // Used for auitoolbar dropdown nodes |
| 23 |
|
| 24 |
protected: |
| 25 |
bool ParseFile(wxXmlDocument& doc, wxcWidget::List_t& toplevels) const; |
| 26 |
wxcWidget* ParseNode(wxXmlNode* node, wxcWidget* parentwrapper, bool& alreadyParented) const; |
| 27 |
void GetSizeritemContents(const wxXmlNode* node, wxcWidget* wrapper) const; |
| 28 |
void GetBookitemContents(const wxXmlNode* node, NotebookPageWrapper* wrapper, int& depth) const; |
| 29 |
void ProcessButtonNode(const wxXmlNode* node, wxcWidget* wrapper) const; |
| 30 |
wxWindow* m_Parent; |
| 31 |
}; |
| 32 |
|
| 33 |
#endif // IMPORTFROMXRC_H |