SILICON
Loading...
Searching...
No Matches
ProjectFileController Class Reference

#include <projectFileController.hpp>

Inheritance diagram for ProjectFileController:
Collaboration diagram for ProjectFileController:

Signals

void projectChanged ()

Public Member Functions

 ProjectFileController (ProjectSession &session, EditorWorkspace &workspace, ProjectDocumentController &documents, QUndoStack &undoStack, QWidget *dialogParent)
void newFile ()
void open ()
bool save ()
void confirmSaveIfDirty (std::function< void()> continuation)
void resetProjectState ()
void setFileName (const QString &fileName)

Private Member Functions

void loadProjectContent (const QString &fileName, const QByteArray &fileContent)

Private Attributes

ProjectSession & session
EditorWorkspace & workspace
ProjectDocumentController & documents
QUndoStack & undoStack
QWidget * dialogParent

Detailed Description

Handles project archive persistence and unsaved change prompts.

Definition at line 28 of file projectFileController.hpp.

Constructor & Destructor Documentation

◆ ProjectFileController()

ProjectFileController ( ProjectSession & session,
EditorWorkspace & workspace,
ProjectDocumentController & documents,
QUndoStack & undoStack,
QWidget * dialogParent )

Definition at line 60 of file projectFileController.cpp.

Member Function Documentation

◆ confirmSaveIfDirty()

void confirmSaveIfDirty ( std::function< void()> continuation)

Definition at line 242 of file projectFileController.cpp.

◆ loadProjectContent()

void loadProjectContent ( const QString & fileName,
const QByteArray & fileContent )
private

Definition at line 107 of file projectFileController.cpp.

◆ newFile()

void newFile ( )

Definition at line 84 of file projectFileController.cpp.

◆ open()

void open ( )

Definition at line 153 of file projectFileController.cpp.

◆ projectChanged

void projectChanged ( )
signal

◆ resetProjectState()

void resetProjectState ( )

Definition at line 94 of file projectFileController.cpp.

◆ save()

bool save ( )

Definition at line 165 of file projectFileController.cpp.

◆ setFileName()

void setFileName ( const QString & fileName)

Definition at line 73 of file projectFileController.cpp.

Member Data Documentation

◆ dialogParent

QWidget* dialogParent
private

Definition at line 53 of file projectFileController.hpp.

◆ documents

ProjectDocumentController& documents
private

Definition at line 51 of file projectFileController.hpp.

◆ session

ProjectSession& session
private

Definition at line 49 of file projectFileController.hpp.

◆ undoStack

QUndoStack& undoStack
private

Definition at line 52 of file projectFileController.hpp.

◆ workspace

EditorWorkspace& workspace
private

Definition at line 50 of file projectFileController.hpp.


The documentation for this class was generated from the following files: