Commit f4b18958 authored by Denis Khachko's avatar Denis Khachko

Set task title

parent 7da3b3ed
...@@ -92,6 +92,7 @@ void Plugin::setPreProgram(QVariant param) ...@@ -92,6 +92,7 @@ void Plugin::setPreProgram(QVariant param)
QUrl base=QUrl(MW->baseCourseFile());//path to kurs.xml file QUrl base=QUrl(MW->baseCourseFile());//path to kurs.xml file
base.setScheme("Course"); base.setScheme("Course");
text.url=base; text.url=base;
text.title=MW->task.name;
qDebug()<<base.isLocalFile()<<base.path (); qDebug()<<base.isLocalFile()<<base.path ();
gui->setProgramSource(text); gui->setProgramSource(text);
......
...@@ -328,6 +328,7 @@ void MainWindowTask::loadCourse() ...@@ -328,6 +328,7 @@ void MainWindowTask::loadCourse()
QDir chD(dir); QDir chD(dir);
QDir resDir=interface->myResourcesDir(); QDir resDir=interface->myResourcesDir();
resDir.cdUp(); resDir.cdUp();
resDir.cd("courses");
if(!chD.exists())dir=resDir.canonicalPath(); if(!chD.exists())dir=resDir.canonicalPath();
// QFileDialog dialog(this,trUtf8("Открыть файл"),dir, "(*.kurs.xml *.work.xml)"); // QFileDialog dialog(this,trUtf8("Открыть файл"),dir, "(*.kurs.xml *.work.xml)");
// dialog.setAcceptMode(QFileDialog::AcceptOpen); // dialog.setAcceptMode(QFileDialog::AcceptOpen);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment