Skip to content

Commit

Permalink
remove 'default' workspace
Browse files Browse the repository at this point in the history
  • Loading branch information
wschweer committed Aug 29, 2014
1 parent 4f11576 commit abc70ae
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions mscore/workspace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
namespace Ms {

bool Workspace::workspacesRead = false;
QList<Workspace*> Workspace::_workspaces;
Workspace* Workspace::currentWorkspace;

Workspace Workspace::_advancedWorkspace {
Expand All @@ -42,6 +41,11 @@ Workspace Workspace::_basicWorkspace {
tr("Basic"), QString("Basic"), false, true
};

QList<Workspace*> Workspace::_workspaces {
&_basicWorkspace,
&_advancedWorkspace
};

//---------------------------------------------------------
// undoWorkspace
//---------------------------------------------------------
Expand Down Expand Up @@ -199,11 +203,8 @@ void Workspace::initWorkspace()
break;
}
}
if (currentWorkspace == 0) {
currentWorkspace = new Workspace;
currentWorkspace->setName("default");
Workspace::workspaces().append(currentWorkspace);
}
if (currentWorkspace == 0)
currentWorkspace = Workspace::workspaces().at(0);
}

//---------------------------------------------------------
Expand Down Expand Up @@ -398,9 +399,6 @@ void Workspace::save()
QList<Workspace*>& Workspace::workspaces()
{
if (!workspacesRead) {
_workspaces.append(&_advancedWorkspace);
_workspaces.append(&_basicWorkspace);

QStringList path;
path << mscoreGlobalShare + "workspaces";
path << dataPath + "/workspaces";
Expand Down

0 comments on commit abc70ae

Please sign in to comment.