diff --git a/linux/applications/qupzilla.desktop b/linux/applications/qupzilla.desktop index 149c4fd9f..3d7b8198d 100644 --- a/linux/applications/qupzilla.desktop +++ b/linux/applications/qupzilla.desktop @@ -52,7 +52,7 @@ Name=Open new window Name[cs]=Otevřít nové okno Name[de]=Neues Fenster öffnen Name[el]=Άνοιγμα νέου παράθυρου -Name[es]=Abrir una ventana nueva +Name[es]=Abrir nueva ventana Name[fr]=Ouvrir une nouvelle fenêtre Name[it]=Apri una nuova finestra Name[nl]=Nieuw venster openen diff --git a/src/app/qupzilla.cpp b/src/app/qupzilla.cpp index 8d3bfc25e..403886f5d 100644 --- a/src/app/qupzilla.cpp +++ b/src/app/qupzilla.cpp @@ -1254,6 +1254,7 @@ void QupZilla::fullScreen(bool make) statusBar()->hide(); bookmarksToolbar()->hide(); m_navigationBar->hide(); + m_tabWidget->getTabBar()->hide(); } else { setWindowState(windowState() & ~Qt::WindowFullScreen); @@ -1262,11 +1263,11 @@ void QupZilla::fullScreen(bool make) statusBar()->setVisible(m_statusBarVisible); m_bookmarksToolbar->setVisible(m_bookmarksToolBarVisible); m_navigationBar->setVisible(m_navigationVisible); + m_tabWidget->showTabBar(); } m_actionShowFullScreen->setChecked(make); m_navigationBar->buttonExitFullscreen()->setVisible(make); - m_tabWidget->getTabBar()->setVisible(!make); emit setWebViewMouseTracking(make); } diff --git a/src/webview/tabwidget.cpp b/src/webview/tabwidget.cpp index 3eab8546e..8aa642847 100644 --- a/src/webview/tabwidget.cpp +++ b/src/webview/tabwidget.cpp @@ -344,14 +344,21 @@ void TabWidget::closeTab(int index) setCurrentIndex(m_lastTabIndex); } - widget(index)->deleteLater(); - - if (count() == 1 && m_hideTabBarWithOneTab) { + if (count() == 2 && m_hideTabBarWithOneTab) { tabBar()->setVisible(false); } -// if (count() < 1) -// p_QupZilla->close(); + widget(index)->deleteLater(); +} + +void TabWidget::showTabBar() +{ + if (count() == 1 && m_hideTabBarWithOneTab) { + tabBar()->hide(); + } + else { + tabBar()->show(); + } } void TabWidget::tabMoved(int before, int after) diff --git a/src/webview/tabwidget.h b/src/webview/tabwidget.h index edc5536a6..119a7db79 100644 --- a/src/webview/tabwidget.h +++ b/src/webview/tabwidget.h @@ -62,6 +62,7 @@ public: ToolButton* buttonAddTab() { return m_buttonAddTab; } void createKeyPressEvent(QKeyEvent* event); + void showTabBar(); signals: void pinnedTabClosed();