|
1 # -*- coding: utf-8 -*- |
|
2 |
|
3 # Copyright (c) 2009 Detlev Offenbach <detlev@die-offenbachs.de> |
|
4 # |
|
5 |
|
6 """ |
|
7 Module implementing a dialog to select which private data to clear. |
|
8 """ |
|
9 |
|
10 from PyQt4.QtGui import QDialog |
|
11 from PyQt4.QtCore import pyqtSlot, qVersion |
|
12 |
|
13 from Ui_HelpClearPrivateDataDialog import Ui_HelpClearPrivateDataDialog |
|
14 |
|
15 class HelpClearPrivateDataDialog(QDialog, Ui_HelpClearPrivateDataDialog): |
|
16 """ |
|
17 Class implementing a dialog to select which private data to clear. |
|
18 """ |
|
19 def __init__(self, parent = None): |
|
20 """ |
|
21 Constructor |
|
22 |
|
23 @param parent reference to the parent widget (QWidget) |
|
24 """ |
|
25 QDialog.__init__(self, parent) |
|
26 self.setupUi(self) |
|
27 |
|
28 def getData(self): |
|
29 """ |
|
30 Public method to get the data from the dialog. |
|
31 |
|
32 @return tuple of flags indicating which data to clear (browsing history, |
|
33 search history, favicons, disk cache, cookies, passwords) (list of boolean) |
|
34 """ |
|
35 return (self.historyCheckBox.isChecked(), |
|
36 self.searchCheckBox.isChecked(), |
|
37 self.iconsCheckBox.isChecked(), |
|
38 self.cacheCheckBox.isChecked(), |
|
39 self.cookiesCheckBox.isChecked(), |
|
40 self.passwordsCheckBox.isChecked()) |