mirror of
https://github.com/YACReader/yacreader
synced 2026-03-15 10:10:03 -04:00
a?adido guid para identificar a YACReaderLibrary
a?adidas las clases server y client para los mecanismos IPC que permitir?n la integraci?n entre YACReader y YACReaderLibrary a?adido check que permite ejecutar YACReaderLibray como una aplicaci?n stand alone a?adidos ficheros de clases POCO para gesti?nar los objetos de las bibliotecas eliminado c?digo muerto en LibraryWindow y c?digo comentado en LibraryCreator
This commit is contained in:
@ -11,16 +11,8 @@
|
||||
#include <algorithm>
|
||||
using namespace std;
|
||||
|
||||
//QMutex mutex;
|
||||
#include "poppler-qt4.h"
|
||||
|
||||
|
||||
/*int numThreads = 0;
|
||||
QWaitCondition waitCondition;
|
||||
QMutex mutex;
|
||||
*/
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------
|
||||
LibraryCreator::LibraryCreator()
|
||||
:creation(false)
|
||||
@ -143,39 +135,6 @@ qulonglong LibraryCreator::insertFolders()
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*qulonglong LibraryCreator::insertFolder(qulonglong parentId,const Folder & folder)
|
||||
{
|
||||
QSqlQuery query(_database);
|
||||
query.prepare("INSERT INTO folder (parentId, name, path) "
|
||||
"VALUES (:parentId, :name, :path)");
|
||||
query.bindValue(":parentId", parentId);
|
||||
query.bindValue(":name", folder.name);
|
||||
query.bindValue(":path", folder.path);
|
||||
query.exec();
|
||||
return query.lastInsertId().toULongLong();
|
||||
}*/
|
||||
|
||||
/*qulonglong LibraryCreator::insertComic(const Comic & comic)
|
||||
{
|
||||
//TODO comprobar si ya hay comic info con ese hash
|
||||
QSqlQuery comicInfoInsert(_database);
|
||||
comicInfoInsert.prepare("INSERT INTO comic_info (hash) "
|
||||
"VALUES (:hash)");
|
||||
comicInfoInsert.bindValue(":hash", comic.hash);
|
||||
comicInfoInsert.exec();
|
||||
qulonglong comicInfoId =comicInfoInsert.lastInsertId().toULongLong();
|
||||
|
||||
QSqlQuery query(_database);
|
||||
query.prepare("INSERT INTO comic (parentId, comicInfoId, fileName, path) "
|
||||
"VALUES (:parentId,:comicInfoId,:name, :path)");
|
||||
query.bindValue(":parentId", comic.parentId);
|
||||
query.bindValue(":comicInfoId", comicInfoId);
|
||||
query.bindValue(":name", comic.name);
|
||||
query.bindValue(":path", comic.path);
|
||||
query.exec();
|
||||
return query.lastInsertId().toULongLong();
|
||||
}*/
|
||||
|
||||
void LibraryCreator::create(QDir dir)
|
||||
{
|
||||
dir.setNameFilters(_nameFilter);
|
||||
@ -525,26 +484,3 @@ void ThumbnailCreator::create()
|
||||
delete _7z;
|
||||
}
|
||||
}
|
||||
|
||||
/*void ThumbnailCreator::openingError(QProcess::ProcessError error)
|
||||
{
|
||||
//TODO : move to the gui thread
|
||||
switch(error)
|
||||
{
|
||||
case QProcess::FailedToStart:
|
||||
QMessageBox::critical(NULL,tr("7z not found"),tr("7z wasn't found in your PATH."));
|
||||
break;
|
||||
case QProcess::Crashed:
|
||||
QMessageBox::critical(NULL,tr("7z crashed"),tr("7z crashed."));
|
||||
break;
|
||||
case QProcess::ReadError:
|
||||
QMessageBox::critical(NULL,tr("7z reading"),tr("problem reading from 7z"));
|
||||
break;
|
||||
case QProcess::UnknownError:
|
||||
QMessageBox::critical(NULL,tr("7z problem"),tr("Unknown error 7z"));
|
||||
break;
|
||||
default:
|
||||
//TODO
|
||||
break;
|
||||
}
|
||||
}*/
|
||||
|
||||
Reference in New Issue
Block a user