89 @pyqtSlot() |
89 @pyqtSlot() |
90 def on_blockButton_clicked(self): |
90 def on_blockButton_clicked(self): |
91 """ |
91 """ |
92 Private slot to block cookies of a domain. |
92 Private slot to block cookies of a domain. |
93 """ |
93 """ |
94 from .CookieJar import CookieJar |
94 from .CookieJar import CookieExceptionRuleType |
95 |
95 |
96 self.__exceptionsModel.addRule(self.domainEdit.text(), CookieJar.Block) |
96 self.__exceptionsModel.addRule( |
|
97 self.domainEdit.text(), CookieExceptionRuleType.Block |
|
98 ) |
97 self.domainEdit.clear() |
99 self.domainEdit.clear() |
98 |
100 |
99 @pyqtSlot() |
101 @pyqtSlot() |
100 def on_allowForSessionButton_clicked(self): |
102 def on_allowForSessionButton_clicked(self): |
101 """ |
103 """ |
102 Private slot to allow cookies of a domain for the current session only. |
104 Private slot to allow cookies of a domain for the current session only. |
103 """ |
105 """ |
104 from .CookieJar import CookieJar |
106 from .CookieJar import CookieExceptionRuleType |
105 |
107 |
106 self.__exceptionsModel.addRule( |
108 self.__exceptionsModel.addRule( |
107 self.domainEdit.text(), CookieJar.AllowForSession |
109 self.domainEdit.text(), CookieExceptionRuleType.AllowForSession |
108 ) |
110 ) |
109 self.domainEdit.clear() |
111 self.domainEdit.clear() |
110 |
112 |
111 @pyqtSlot() |
113 @pyqtSlot() |
112 def on_allowButton_clicked(self): |
114 def on_allowButton_clicked(self): |
113 """ |
115 """ |
114 Private slot to allow cookies of a domain. |
116 Private slot to allow cookies of a domain. |
115 """ |
117 """ |
116 from .CookieJar import CookieJar |
118 from .CookieJar import CookieExceptionRuleType |
117 |
119 |
118 self.__exceptionsModel.addRule(self.domainEdit.text(), CookieJar.Allow) |
120 self.__exceptionsModel.addRule( |
|
121 self.domainEdit.text(), CookieExceptionRuleType.Allow |
|
122 ) |
119 self.domainEdit.clear() |
123 self.domainEdit.clear() |