Code::Blocks  SVN r11506
projectlayoutloader.h
Go to the documentation of this file.
1 /*
2  * This file is part of the Code::Blocks IDE and licensed under the GNU Lesser General Public License, version 3
3  * http://www.gnu.org/licenses/lgpl-3.0.html
4  */
5 
6 #ifndef PROJECTLAYOUTLOADER_H
7 #define PROJECTLAYOUTLOADER_H
8 
9 #ifndef CB_PRECOMP
10  #include <wx/string.h>
11  #include "cbauibook.h"
12 #endif
13 
14 #define PROJECT_LAYOUT_FILE_VERSION_MAJOR 1
15 #define PROJECT_LAYOUT_FILE_VERSION_MINOR 0
16 
17 class cbProject;
18 
20 {
21  public:
23  virtual ~ProjectLayoutLoader();
24 
25  bool Open(const wxString& filename);
26  bool Save(const wxString& filename);
27 
29  {
30  return Manager::Get()->GetEditorManager()->GetNotebook()->LoadPerspective( m_NotebookLayout,
31  !Manager::Get()->GetProjectManager()->IsLoadingWorkspace());
32  }
33 
34  ProjectFile* GetTopProjectFile() { return m_TopProjectFile; }
35  protected:
36  private:
40 };
41 
42 #endif // PROJECTLAYOUTLOADER_H
43 
bool LoadPerspective(const wxString &layout, bool mergeLayouts=false)
Loads serialized notebook layout.
Definition: cbauibook.cpp:803
static Manager * Get()
Use Manager::Get() to get a pointer to its instance Manager::Get() is guaranteed to never return an i...
Definition: manager.cpp:182
Represents a file in a Code::Blocks project.
Definition: projectfile.h:39
ProjectFile * m_TopProjectFile
EditorManager * GetEditorManager() const
Definition: manager.cpp:434
#define DLLIMPORT
Definition: settings.h:16
Represents a Code::Blocks project.
Definition: cbproject.h:96
cbAuiNotebook * GetNotebook()
Definition: editormanager.h:73
ProjectFile * GetTopProjectFile()