mirror of
https://github.com/YACReader/yacreader
synced 2025-06-04 01:28:55 -04:00
merge
This commit is contained in:
parent
445f725ee2
commit
4b078a9f15
@ -578,6 +578,7 @@ void MainWindowViewer::createToolBars()
|
|||||||
viewer->addAction(leftRotationAction);
|
viewer->addAction(leftRotationAction);
|
||||||
viewer->addAction(rightRotationAction);
|
viewer->addAction(rightRotationAction);
|
||||||
viewer->addAction(doublePageAction);
|
viewer->addAction(doublePageAction);
|
||||||
|
viewer->addAction(doubleMangaPageAction);
|
||||||
YACReader::addSperator(viewer);
|
YACReader::addSperator(viewer);
|
||||||
|
|
||||||
viewer->addAction(showMagnifyingGlassAction);
|
viewer->addAction(showMagnifyingGlassAction);
|
||||||
|
@ -849,7 +849,7 @@ void Render::nextPage()
|
|||||||
update();
|
update();
|
||||||
emit pageChanged(currentIndex);
|
emit pageChanged(currentIndex);
|
||||||
}
|
}
|
||||||
else
|
else if (hasLoadedComic() && (currentIndex == numPages()-1))
|
||||||
{
|
{
|
||||||
emit isLast();
|
emit isLast();
|
||||||
}
|
}
|
||||||
@ -873,7 +873,7 @@ void Render::nextDoublePage()
|
|||||||
update();
|
update();
|
||||||
emit pageChanged(currentIndex);
|
emit pageChanged(currentIndex);
|
||||||
}
|
}
|
||||||
else
|
else if (hasLoadedComic() && (currentIndex >= numPages()-2))
|
||||||
{
|
{
|
||||||
emit isLast();
|
emit isLast();
|
||||||
}
|
}
|
||||||
@ -894,7 +894,7 @@ void Render::previousPage()
|
|||||||
update();
|
update();
|
||||||
emit pageChanged(currentIndex);
|
emit pageChanged(currentIndex);
|
||||||
}
|
}
|
||||||
else
|
else if (hasLoadedComic() && (currentIndex == 0))
|
||||||
{
|
{
|
||||||
emit isCover();
|
emit isCover();
|
||||||
}
|
}
|
||||||
|
@ -95,7 +95,7 @@ void logSystemAndConfig()
|
|||||||
#ifdef Q_OS_WIN
|
#ifdef Q_OS_WIN
|
||||||
if(QLibrary::isLibrary(QApplication::applicationDirPath()+"/utils/7z.dll"))
|
if(QLibrary::isLibrary(QApplication::applicationDirPath()+"/utils/7z.dll"))
|
||||||
#elif defined Q_OS_UNIX && !defined Q_OS_MAC
|
#elif defined Q_OS_UNIX && !defined Q_OS_MAC
|
||||||
if(QLibrary::isLibrary(QString(LIBDIR)+"/p7zip/7z.so"))
|
if(QLibrary::isLibrary(QString(LIBDIR)+"/yacreader/7z.so") | QLibrary::isLibrary(QString(LIBDIR)+"/p7zip/7z.so"))
|
||||||
#else
|
#else
|
||||||
if(QLibrary::isLibrary(QApplication::applicationDirPath()+"/utils/7z.so"))
|
if(QLibrary::isLibrary(QApplication::applicationDirPath()+"/utils/7z.so"))
|
||||||
#endif
|
#endif
|
||||||
|
@ -730,11 +730,13 @@ void PDFComic::process()
|
|||||||
_index = _firstPage;
|
_index = _firstPage;
|
||||||
emit(openAt(_index));
|
emit(openAt(_index));
|
||||||
|
|
||||||
for(int i=_index;i<nPages;i++)
|
//buffer index to avoid race conditions
|
||||||
|
int buffered_index = _index;
|
||||||
|
for(int i=buffered_index;i<nPages;i++)
|
||||||
renderPage(i);
|
renderPage(i);
|
||||||
for(int i=0;i<_index;i++)
|
for(int i=0;i<buffered_index;i++)
|
||||||
renderPage(i);
|
renderPage(i);
|
||||||
|
|
||||||
delete pdfComic;
|
delete pdfComic;
|
||||||
emit imagesLoaded();
|
emit imagesLoaded();
|
||||||
moveToThread(QApplication::instance()->thread());
|
moveToThread(QApplication::instance()->thread());
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
#include "extract_delegate.h"
|
#include "extract_delegate.h"
|
||||||
|
|
||||||
#include <QLibrary>
|
#include <QLibrary>
|
||||||
|
#include <QFileInfo>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
|
|
||||||
@ -201,7 +202,16 @@ bool CompressedArchive::loadFunctions()
|
|||||||
#if defined Q_OS_MAC
|
#if defined Q_OS_MAC
|
||||||
rarLib = new QLibrary(QApplication::applicationDirPath()+"/utils/Codecs/Rar29");
|
rarLib = new QLibrary(QApplication::applicationDirPath()+"/utils/Codecs/Rar29");
|
||||||
#else
|
#else
|
||||||
rarLib = new QLibrary(QString(LIBDIR)+"/p7zip/Codecs/Rar29.so");
|
//check if a yacreader specific version of p7zip exists on the system
|
||||||
|
QFileInfo rarCodec(QString(LIBDIR)+"/yacreader/Codecs/Rar29.so");
|
||||||
|
if (rarCodec.exists())
|
||||||
|
{
|
||||||
|
rarLib = new QLibrary(rarCodec.absoluteFilePath());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
rarLib = new QLibrary(QString(LIBDIR)+"/p7zip/Codecs/Rar29.so");
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
if(!rarLib->load())
|
if(!rarLib->load())
|
||||||
{
|
{
|
||||||
@ -211,7 +221,15 @@ bool CompressedArchive::loadFunctions()
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#if defined Q_OS_UNIX && !defined Q_OS_MAC
|
#if defined Q_OS_UNIX && !defined Q_OS_MAC
|
||||||
sevenzLib = new QLibrary(QString(LIBDIR)+"/p7zip/7z.so");
|
QFileInfo sevenzlibrary(QString(LIBDIR)+"/yacreader/7z.so");
|
||||||
|
if (sevenzlibrary.exists())
|
||||||
|
{
|
||||||
|
sevenzLib = new QLibrary(sevenzlibrary.absoluteFilePath());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sevenzLib = new QLibrary(QString(LIBDIR)+"/p7zip/7z.so");
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
sevenzLib = new QLibrary(QApplication::applicationDirPath()+"/utils/7z");
|
sevenzLib = new QLibrary(QApplication::applicationDirPath()+"/utils/7z");
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user