Tue, 13 Sep 2011 18:39:41 +0200
Added the "Do Not Track" feature.
diff -r 063bc4545f75 -r 7e7b88c58fda Helpviewer/Network/NetworkAccessManager.py --- a/Helpviewer/Network/NetworkAccessManager.py Mon Sep 12 18:03:05 2011 +0200 +++ b/Helpviewer/Network/NetworkAccessManager.py Tue Sep 13 18:39:41 2011 +0200 @@ -90,6 +90,8 @@ self.proxyAuthenticationRequired.connect(proxyAuthenticationRequired) self.authenticationRequired.connect(self.__authenticationRequired) + self.__doNotTrack = Preferences.getHelp("DoNotTrack") + # register scheme handlers self.setSchemeHandler("qthelp", QtHelpAccessHandler(engine, self)) self.setSchemeHandler("pyrc", PyrcAccessHandler(self)) @@ -152,6 +154,10 @@ reply.setParent(self) return reply + # Do Not Track feature + if self.__doNotTrack: + req.setRawHeader("DNT", "1") + reply = QNetworkAccessManager.createRequest(self, op, req, outgoingData) self.requestCreated.emit(op, req, reply) @@ -320,6 +326,8 @@ Public slot to signal a change of preferences. """ self.__setDiskCache() + + self.__doNotTrack = Preferences.getHelp("DoNotTrack") def languagesChanged(self): """
diff -r 063bc4545f75 -r 7e7b88c58fda Preferences/ConfigurationPages/HelpWebBrowserPage.py --- a/Preferences/ConfigurationPages/HelpWebBrowserPage.py Mon Sep 12 18:03:05 2011 +0200 +++ b/Preferences/ConfigurationPages/HelpWebBrowserPage.py Tue Sep 13 18:39:41 2011 +0200 @@ -65,6 +65,8 @@ Preferences.getHelp("JavaScriptCanAccessClipboard")) self.pluginsCheckBox.setChecked( Preferences.getHelp("PluginsEnabled")) + self.doNotTrackCheckBox.setChecked( + Preferences.getHelp("DoNotTrack")) self.diskCacheCheckBox.setChecked( Preferences.getHelp("DiskCacheEnabled")) @@ -145,6 +147,8 @@ self.jsClipboardCheckBox.isChecked()) Preferences.setHelp("PluginsEnabled", self.pluginsCheckBox.isChecked()) + Preferences.setHelp("DoNotTrack", + self.doNotTrackCheckBox.isChecked()) Preferences.setHelp("DiskCacheEnabled", self.diskCacheCheckBox.isChecked())
diff -r 063bc4545f75 -r 7e7b88c58fda Preferences/ConfigurationPages/HelpWebBrowserPage.ui --- a/Preferences/ConfigurationPages/HelpWebBrowserPage.ui Mon Sep 12 18:03:05 2011 +0200 +++ b/Preferences/ConfigurationPages/HelpWebBrowserPage.ui Tue Sep 13 18:39:41 2011 +0200 @@ -10,7 +10,7 @@ <height>1021</height> </rect> </property> - <layout class="QVBoxLayout" name="verticalLayout_4"> + <layout class="QVBoxLayout" name="verticalLayout_2"> <item> <widget class="QLabel" name="headerLabel"> <property name="text"> @@ -206,7 +206,7 @@ <string>Privacy</string> </property> <layout class="QGridLayout" name="gridLayout"> - <item row="0" column="0"> + <item row="0" column="0" colspan="2"> <widget class="QCheckBox" name="javaCheckBox"> <property name="toolTip"> <string>Select to enable Java</string> @@ -216,7 +216,7 @@ </property> </widget> </item> - <item row="1" column="0"> + <item row="1" column="0" colspan="2"> <widget class="QCheckBox" name="javaScriptCheckBox"> <property name="toolTip"> <string>Select to enable JavaScript</string> @@ -246,7 +246,7 @@ </property> </widget> </item> - <item row="3" column="0"> + <item row="3" column="0" colspan="2"> <widget class="QCheckBox" name="pluginsCheckBox"> <property name="toolTip"> <string>Select to enable plugins in web pages</string> @@ -256,6 +256,23 @@ </property> </widget> </item> + <item row="4" column="0" colspan="2"> + <widget class="Line" name="line"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + </widget> + </item> + <item row="5" column="0" colspan="2"> + <widget class="QCheckBox" name="doNotTrackCheckBox"> + <property name="toolTip"> + <string>Select to enabled the "Do Not Track" feature</string> + </property> + <property name="text"> + <string>Tell web sites I do not want to be tracked</string> + </property> + </widget> + </item> </layout> </widget> </item> @@ -506,6 +523,7 @@ <tabstop>jsOpenWindowsCheckBox</tabstop> <tabstop>jsClipboardCheckBox</tabstop> <tabstop>pluginsCheckBox</tabstop> + <tabstop>doNotTrackCheckBox</tabstop> <tabstop>expireHistory</tabstop> <tabstop>diskCacheCheckBox</tabstop> <tabstop>cacheKeepButton</tabstop>
diff -r 063bc4545f75 -r 7e7b88c58fda Preferences/__init__.py --- a/Preferences/__init__.py Mon Sep 12 18:03:05 2011 +0200 +++ b/Preferences/__init__.py Tue Sep 13 18:39:41 2011 +0200 @@ -638,6 +638,7 @@ "VirusTotalServiceKey": "", "VirusTotalSecure": False, "SearchLanguage": QLocale().language(), + "DoNotTrack": False, } websettings = QWebSettings.globalSettings() @@ -1975,7 +1976,7 @@ "JavaScriptCanAccessClipboard", "PluginsEnabled", "DnsPrefetchEnabled", "OfflineStorageDatabaseEnabled", "OfflineWebApplicationCacheEnabled", "LocalStorageEnabled", "ShowPreview", "AccessKeysEnabled", - "VirusTotalEnabled", "VirusTotalSecure"]: + "VirusTotalEnabled", "VirusTotalSecure", "DoNotTrack"]: return toBool(prefClass.settings.value("Help/" + key, prefClass.helpDefaults[key])) elif key in ["AdBlockSubscriptions"]:
diff -r 063bc4545f75 -r 7e7b88c58fda changelog --- a/changelog Mon Sep 12 18:03:05 2011 +0200 +++ b/changelog Tue Sep 13 18:39:41 2011 +0200 @@ -32,6 +32,8 @@ file first (created by an hg incoming) --- added support for importing patches --- added configuration option to create backup files when reverting changes +- enhancements to the web browser + -- added the "Do Not Track" feature Version 5.2-snapshot-20110724: - bug fixes