Changeset 618 in dev for trunk/ab5.0/abdev/abdev/include
- Timestamp:
- May 19, 2008, 5:10:15 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ab5.0/abdev/abdev/include/ProjectManager/ProjectManager.h
r615 r618 1 1 #pragma once 2 2 3 struct PROJECTINFO{ 3 4 namespace ActiveBasic{ namespace IDE{ 5 6 class Project 7 { 8 public: 4 9 DWORD dwModuleType; 5 10 … … 39 44 _int8 ModifuOfResource; 40 45 _int8 modify; 41 };42 43 namespace ActiveBasic{ namespace IDE{44 45 class Project46 {47 std::string name;48 ActiveBasic::Common::TargetModuleType::EnumType moduleType;49 public:50 void Open( const std::string &projectFileName );51 void Close() const;52 void Save() const;53 };54 typedef std::vector<Project *> Projects;55 56 class ProjectManager57 {58 Projects projects;59 Project *pCurrentProject;60 public:61 ProjectManager()62 : pCurrentProject( NULL )63 {64 }65 ~ProjectManager()66 {67 if( IsOpenedProject() )68 {69 throw;70 }71 }72 const Project &GetCurrentProject() const73 {74 return *pCurrentProject;75 }76 Project &GetCurrentProject()77 {78 return *pCurrentProject;79 }80 46 81 47 bool IsOpenedProject() const 82 48 { 83 return !projects.empty();49 return ( name[0] != '\0' ); 84 50 } 85 void OpenProject( const std::string &projectFileName );86 void CloseProject( const std::string &projectName );87 88 void CloseAllProjects();89 51 }; 90 52 … … 92 54 }} 93 55 94 extern ActiveBasic::IDE::ProjectManager projectManager; 95 extern PROJECTINFO ProjectInfo; 56 extern ActiveBasic::IDE::Project projectInfo;
Note:
See TracChangeset
for help on using the changeset viewer.