mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 23:34:06 +00:00
clean: remove useless code and refactor
This commit is contained in:
parent
3b6cae9fba
commit
3a46dd290b
|
@ -1853,11 +1853,9 @@ void MainWindow::closeCurrentTab()
|
||||||
|
|
||||||
void MainWindow::closeAllTabs()
|
void MainWindow::closeAllTabs()
|
||||||
{
|
{
|
||||||
while ( ui.tabWidget->count() > 1 )
|
while ( ui.tabWidget->count() > 0 ) {
|
||||||
closeCurrentTab();
|
closeCurrentTab();
|
||||||
|
}
|
||||||
// close last tab
|
|
||||||
closeCurrentTab();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::closeRestTabs()
|
void MainWindow::closeRestTabs()
|
||||||
|
@ -1897,19 +1895,13 @@ void MainWindow::switchToPrevTab()
|
||||||
|
|
||||||
void MainWindow::backClicked()
|
void MainWindow::backClicked()
|
||||||
{
|
{
|
||||||
GD_DPRINTF( "Back\n" );
|
|
||||||
|
|
||||||
ArticleView * view = getCurrentArticleView();
|
ArticleView * view = getCurrentArticleView();
|
||||||
|
|
||||||
view->back();
|
view->back();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::forwardClicked()
|
void MainWindow::forwardClicked()
|
||||||
{
|
{
|
||||||
GD_DPRINTF( "Forward\n" );
|
|
||||||
|
|
||||||
ArticleView * view = getCurrentArticleView();
|
ArticleView * view = getCurrentArticleView();
|
||||||
|
|
||||||
view->forward();
|
view->forward();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue