parent
6549641fe1
commit
2eae1f37c2
@ -0,0 +1,44 @@ |
||||
/*
|
||||
* Copyright (C) 2010-2013 Groupement d'Intérêt Public pour l'Education Numérique en Afrique (GIP ENA) |
||||
* |
||||
* This file is part of Open-Sankoré. |
||||
* |
||||
* Open-Sankoré is free software: you can redistribute it and/or modify |
||||
* it under the terms of the GNU General Public License as published by |
||||
* the Free Software Foundation, version 3 of the License, |
||||
* with a specific linking exception for the OpenSSL project's |
||||
* "OpenSSL" library (or with modified versions of it that use the |
||||
* same license as the "OpenSSL" library). |
||||
* |
||||
* Open-Sankoré is distributed in the hope that it will be useful, |
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
* GNU General Public License for more details. |
||||
* |
||||
* You should have received a copy of the GNU General Public License |
||||
* along with Open-Sankoré. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/ |
||||
|
||||
|
||||
#include <QProcess> |
||||
|
||||
#include "UBOpenSankoreImporter.h" |
||||
#include "UBSettings.h" |
||||
|
||||
#include "core/UBApplication.h" |
||||
#include "gui/UBMainWindow.h" |
||||
|
||||
|
||||
UBOpenSankoreImporter::UBOpenSankoreImporter(QObject *parent) : |
||||
QObject(parent) |
||||
{ |
||||
if(UBSettings::settings()->appLookForOpenSankoreInstall->get().toBool() && |
||||
QDir(UBSettings::userDataDirectory().replace(qApp->applicationName(),"Sankore")).exists()) |
||||
if(UBApplication::mainWindow->yesNoQuestion(tr("Open-Sankoré data detected"),tr("Open-Sankoré directory is present on the disk. It's possible to import the Open-Sankoré documents into OpenBoard as the preferences. Pushing Ok will close OpenBoard and run the importer application."))){ |
||||
QProcess newProcess; |
||||
newProcess.startDetached(qApp->applicationDirPath()+"/Importer/OpenBoardImporter"); |
||||
qApp->exit(0); |
||||
} |
||||
} |
||||
|
||||
|
@ -0,0 +1,40 @@ |
||||
/*
|
||||
* Copyright (C) 2010-2013 Groupement d'Intérêt Public pour l'Education Numérique en Afrique (GIP ENA) |
||||
* |
||||
* This file is part of Open-Sankoré. |
||||
* |
||||
* Open-Sankoré is free software: you can redistribute it and/or modify |
||||
* it under the terms of the GNU General Public License as published by |
||||
* the Free Software Foundation, version 3 of the License, |
||||
* with a specific linking exception for the OpenSSL project's |
||||
* "OpenSSL" library (or with modified versions of it that use the |
||||
* same license as the "OpenSSL" library). |
||||
* |
||||
* Open-Sankoré is distributed in the hope that it will be useful, |
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
* GNU General Public License for more details. |
||||
* |
||||
* You should have received a copy of the GNU General Public License |
||||
* along with Open-Sankoré. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/ |
||||
|
||||
|
||||
#ifndef UBOPENSANKOREIMPORTER_H |
||||
#define UBOPENSANKOREIMPORTER_H |
||||
|
||||
#include <QObject> |
||||
|
||||
class UBOpenSankoreImporter : public QObject |
||||
{ |
||||
Q_OBJECT |
||||
public: |
||||
explicit UBOpenSankoreImporter(QObject *parent = 0); |
||||
|
||||
signals: |
||||
|
||||
public slots: |
||||
|
||||
}; |
||||
|
||||
#endif // UBOPENSANKOREIMPORTER_H
|
Loading…
Reference in new issue