Merged in daisuke_cato/yacreader/dev_cato7 (pull request #42)

Horizontal aware auto scrolling (target branch = develop)
This commit is contained in:
Luis Ángel San Martín
2016-10-28 17:31:52 +00:00
11 changed files with 123 additions and 28 deletions

View File

@ -225,6 +225,12 @@ void GoToFlow::updateConfig(QSettings * settings)
{
Q_UNUSED(settings)
}
void GoToFlow::setFlowRightToLeft(bool b)
{
flow->setFlowRightToLeft(b);
}
//-----------------------------------------------------------------------------
//SlideInitializer
//-----------------------------------------------------------------------------

View File

@ -63,6 +63,8 @@ private slots:
void setFlowType(FlowType flowType);
void updateSize();
void updateConfig(QSettings * settings);
void setFlowRightToLeft(bool b);
signals:
void goToPage(unsigned int page);

View File

@ -164,3 +164,8 @@ void GoToFlowGL::resizeEvent(QResizeEvent *event)
toolBar->move(0, event->size().height() - toolBar->height());
toolBar->setFixedWidth(width());
}
void GoToFlowGL::setFlowRightToLeft(bool b)
{
flow->setFlowRightToLeft(b);
}

View File

@ -26,6 +26,7 @@ public:
void updateSize();
void updateConfig(QSettings * settings);
void setFlowRightToLeft(bool b);
signals:
void goToPage(unsigned int page);

View File

@ -29,6 +29,7 @@ public slots:
virtual void setImageReady(int index,const QByteArray & image) = 0;
virtual void updateSize() = 0;
virtual void updateConfig(QSettings * settings) = 0;
virtual void setFlowRightToLeft(bool b) = 0;
protected:
void keyPressEvent(QKeyEvent* event);

View File

@ -963,6 +963,7 @@ void Viewer::doubleMangaPageSwitch()
doubleMangaPage = !doubleMangaPage;
render->doubleMangaPageSwitch();
Configuration::getConfiguration().setDoubleMangaPage(doubleMangaPage);
goToFlow->setFlowRightToLeft(doubleMangaPage);
}
void Viewer::resetContent()