mirror of
https://github.com/YACReader/yacreader
synced 2026-02-12 18:13:01 -05:00
removed setCurrentIndex(0) after removing a library
This commit is contained in:
@ -1181,7 +1181,7 @@ void LibraryWindow::deleteCurrentLibrary()
|
|||||||
QString path = libraries.value(selectedLibrary->currentText());
|
QString path = libraries.value(selectedLibrary->currentText());
|
||||||
libraries.remove(selectedLibrary->currentText());
|
libraries.remove(selectedLibrary->currentText());
|
||||||
selectedLibrary->removeItem(selectedLibrary->currentIndex());
|
selectedLibrary->removeItem(selectedLibrary->currentIndex());
|
||||||
selectedLibrary->setCurrentIndex(0);
|
//selectedLibrary->setCurrentIndex(0);
|
||||||
path = path+"/.yacreaderlibrary";
|
path = path+"/.yacreaderlibrary";
|
||||||
|
|
||||||
QDir d(path);
|
QDir d(path);
|
||||||
@ -1206,7 +1206,7 @@ void LibraryWindow::removeLibrary()
|
|||||||
{
|
{
|
||||||
libraries.remove(currentLibrary);
|
libraries.remove(currentLibrary);
|
||||||
selectedLibrary->removeItem(selectedLibrary->currentIndex());
|
selectedLibrary->removeItem(selectedLibrary->currentIndex());
|
||||||
selectedLibrary->setCurrentIndex(0);
|
//selectedLibrary->setCurrentIndex(0);
|
||||||
if(libraries.size()==0)//no more libraries avaliable.
|
if(libraries.size()==0)//no more libraries avaliable.
|
||||||
{
|
{
|
||||||
comicView->setModel(NULL);
|
comicView->setModel(NULL);
|
||||||
|
|||||||
Reference in New Issue
Block a user