X-Git-Url: https://gitweb.stoutner.com/?p=PrivacyBrowserPC.git;a=blobdiff_plain;f=src%2Fwidgets%2FTabWidget.cpp;fp=src%2Fwidgets%2FTabWidget.cpp;h=dd11a6776c0f0fdc798fe4492879ff2ce5a84a08;hp=2b14018ca6b419a8eb5dec608e66ca83024f43eb;hb=425fed98271cd951cddef9904e5e271f0fb76fc1;hpb=8f1b160582ac3bd86b6e7aeaafcae059aff609c0 diff --git a/src/widgets/TabWidget.cpp b/src/widgets/TabWidget.cpp index 2b14018..dd11a67 100644 --- a/src/widgets/TabWidget.cpp +++ b/src/widgets/TabWidget.cpp @@ -344,12 +344,12 @@ PrivacyWebEngineView* TabWidget::addTab(const bool removeUrlLineEditFocus, const } }); - // Update the zoom factor when changed by CTRL-Scrolling. This can be modified when is fixed. + // Update the zoom actions when changed by CTRL-Scrolling. This can be modified when is fixed. connect(webEnginePagePointer, &QWebEnginePage::contentsSizeChanged, [webEnginePagePointer, this] () { - // Only update the zoom factor action text if this is the current tab. + // Only update the zoom actions if this is the current tab. if (webEnginePagePointer == currentWebEnginePagePointer) - emit updateZoomFactorAction(webEnginePagePointer->zoomFactor()); + emit updateZoomActions(webEnginePagePointer->zoomFactor()); }); // Display find text results. @@ -1071,12 +1071,13 @@ void TabWidget::updateUiFromWebEngineView(const PrivacyWebEngineView *privacyWeb if (privacyWebEngineViewPointer == currentPrivacyWebEngineViewPointer) { // Update the UI. + emit updateDefaultZoomFactor(currentPrivacyWebEngineViewPointer->defaultZoomFactor); emit updateDomainSettingsIndicator(currentPrivacyWebEngineViewPointer->domainSettingsName != QLatin1String("")); emit updateJavaScriptAction(currentWebEngineSettingsPointer->testAttribute(QWebEngineSettings::JavascriptEnabled)); emit updateLocalStorageAction(currentPrivacyWebEngineViewPointer->localStorageEnabled); emit updateDomStorageAction(currentWebEngineSettingsPointer->testAttribute(QWebEngineSettings::LocalStorageEnabled)); emit updateUserAgentActions(currentWebEngineProfilePointer->httpUserAgent(), true); - emit updateZoomFactorAction(currentPrivacyWebEngineViewPointer->zoomFactor()); + emit updateZoomActions(currentPrivacyWebEngineViewPointer->zoomFactor()); } } @@ -1094,6 +1095,7 @@ void TabWidget::updateUiWithTabSettings() emit clearUrlLineEditFocus(); // Update the actions. + emit updateDefaultZoomFactor(currentPrivacyWebEngineViewPointer->defaultZoomFactor); emit updateBackAction(currentWebEngineHistoryPointer->canGoBack()); emit updateCookiesAction(currentPrivacyWebEngineViewPointer->cookieListPointer->size()); emit updateDomStorageAction(currentWebEngineSettingsPointer->testAttribute(QWebEngineSettings::LocalStorageEnabled)); @@ -1101,7 +1103,7 @@ void TabWidget::updateUiWithTabSettings() emit updateJavaScriptAction(currentWebEngineSettingsPointer->testAttribute(QWebEngineSettings::JavascriptEnabled)); emit updateLocalStorageAction(currentPrivacyWebEngineViewPointer->localStorageEnabled); emit updateUserAgentActions(currentWebEngineProfilePointer->httpUserAgent(), true); - emit updateZoomFactorAction(currentPrivacyWebEngineViewPointer->zoomFactor()); + emit updateZoomActions(currentPrivacyWebEngineViewPointer->zoomFactor()); // Update the URL. emit updateWindowTitle(currentPrivacyWebEngineViewPointer->title());