|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.Helpviewer.AdBlock.AdBlockDialog</title> |
|
4 <meta charset="UTF-8"> |
|
5 <style> |
|
6 body { |
|
7 background: #EDECE6; |
|
8 margin: 0em 1em 10em 1em; |
|
9 color: black; |
|
10 } |
|
11 |
|
12 h1 { color: white; background: #85774A; } |
|
13 h2 { color: white; background: #85774A; } |
|
14 h3 { color: white; background: #9D936E; } |
|
15 h4 { color: white; background: #9D936E; } |
|
16 |
|
17 a { color: #BA6D36; } |
|
18 |
|
19 </style> |
|
20 </head> |
|
21 <body><a NAME="top" ID="top"></a> |
|
22 <h1>eric6.Helpviewer.AdBlock.AdBlockDialog</h1> |
|
23 <p> |
|
24 Module implementing the AdBlock configuration dialog. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr> |
|
33 <td><a href="#AdBlockDialog">AdBlockDialog</a></td> |
|
34 <td>Class implementing the AdBlock configuration dialog.</td> |
|
35 </tr> |
|
36 </table> |
|
37 <h3>Functions</h3> |
|
38 <table> |
|
39 <tr><td>None</td></tr> |
|
40 </table> |
|
41 <hr /><hr /> |
|
42 <a NAME="AdBlockDialog" ID="AdBlockDialog"></a> |
|
43 <h2>AdBlockDialog</h2> |
|
44 <p> |
|
45 Class implementing the AdBlock configuration dialog. |
|
46 </p> |
|
47 <h3>Derived from</h3> |
|
48 QDialog, Ui_AdBlockDialog |
|
49 <h3>Class Attributes</h3> |
|
50 <table> |
|
51 <tr><td>None</td></tr> |
|
52 </table> |
|
53 <h3>Class Methods</h3> |
|
54 <table> |
|
55 <tr><td>None</td></tr> |
|
56 </table> |
|
57 <h3>Methods</h3> |
|
58 <table> |
|
59 <tr> |
|
60 <td><a href="#AdBlockDialog.__init__">AdBlockDialog</a></td> |
|
61 <td>Constructor</td> |
|
62 </tr><tr> |
|
63 <td><a href="#AdBlockDialog.__aboutToShowActionMenu">__aboutToShowActionMenu</a></td> |
|
64 <td>Private slot to show the actions menu.</td> |
|
65 </tr><tr> |
|
66 <td><a href="#AdBlockDialog.__addCustomRule">__addCustomRule</a></td> |
|
67 <td>Private slot to add a custom AdBlock rule.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#AdBlockDialog.__browseSubscriptions">__browseSubscriptions</a></td> |
|
70 <td>Private slot to browse the list of available AdBlock subscriptions.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#AdBlockDialog.__learnAboutWritingFilters">__learnAboutWritingFilters</a></td> |
|
73 <td>Private slot to show the web page about how to write filters.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#AdBlockDialog.__load">__load</a></td> |
|
76 <td>Private slot to populate the tab widget with subscriptions.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#AdBlockDialog.__loadSubscriptions">__loadSubscriptions</a></td> |
|
79 <td>Private slot to load the AdBlock subscription rules.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#AdBlockDialog.__removeCustomRule">__removeCustomRule</a></td> |
|
82 <td>Private slot to remove a custom AdBlock rule.</td> |
|
83 </tr><tr> |
|
84 <td><a href="#AdBlockDialog.__removeSubscription">__removeSubscription</a></td> |
|
85 <td>Private slot to remove the selected subscription.</td> |
|
86 </tr><tr> |
|
87 <td><a href="#AdBlockDialog.__setSubscriptionEnabled">__setSubscriptionEnabled</a></td> |
|
88 <td>Private slot to set the enabled state of a subscription.</td> |
|
89 </tr><tr> |
|
90 <td><a href="#AdBlockDialog.__switchSubscriptionEnabled">__switchSubscriptionEnabled</a></td> |
|
91 <td>Private slot to switch the enabled state of the selected subscription.</td> |
|
92 </tr><tr> |
|
93 <td><a href="#AdBlockDialog.__updateAllSubscriptions">__updateAllSubscriptions</a></td> |
|
94 <td>Private slot to update all subscriptions.</td> |
|
95 </tr><tr> |
|
96 <td><a href="#AdBlockDialog.__updateSubscription">__updateSubscription</a></td> |
|
97 <td>Private slot to update the selected subscription.</td> |
|
98 </tr><tr> |
|
99 <td><a href="#AdBlockDialog.addCustomRule">addCustomRule</a></td> |
|
100 <td>Public slot to add a custom AdBlock rule.</td> |
|
101 </tr><tr> |
|
102 <td><a href="#AdBlockDialog.addSubscription">addSubscription</a></td> |
|
103 <td>Public slot adding a subscription to the list.</td> |
|
104 </tr><tr> |
|
105 <td><a href="#AdBlockDialog.on_adBlockGroup_toggled">on_adBlockGroup_toggled</a></td> |
|
106 <td>Private slot handling the enabling/disabling of AdBlock.</td> |
|
107 </tr><tr> |
|
108 <td><a href="#AdBlockDialog.on_searchEdit_textChanged">on_searchEdit_textChanged</a></td> |
|
109 <td>Private slot to set a new filter on the current widget.</td> |
|
110 </tr><tr> |
|
111 <td><a href="#AdBlockDialog.on_subscriptionsTabWidget_currentChanged">on_subscriptionsTabWidget_currentChanged</a></td> |
|
112 <td>Private slot handling the selection of another tab.</td> |
|
113 </tr><tr> |
|
114 <td><a href="#AdBlockDialog.on_updateSpinBox_valueChanged">on_updateSpinBox_valueChanged</a></td> |
|
115 <td>Private slot to handle changes of the update period.</td> |
|
116 </tr><tr> |
|
117 <td><a href="#AdBlockDialog.showRule">showRule</a></td> |
|
118 <td>Public slot to show the given rule.</td> |
|
119 </tr> |
|
120 </table> |
|
121 <h3>Static Methods</h3> |
|
122 <table> |
|
123 <tr><td>None</td></tr> |
|
124 </table> |
|
125 <a NAME="AdBlockDialog.__init__" ID="AdBlockDialog.__init__"></a> |
|
126 <h4>AdBlockDialog (Constructor)</h4> |
|
127 <b>AdBlockDialog</b>(<i>parent=None</i>) |
|
128 <p> |
|
129 Constructor |
|
130 </p><dl> |
|
131 <dt><i>parent</i></dt> |
|
132 <dd> |
|
133 reference to the parent object (QWidget) |
|
134 </dd> |
|
135 </dl><a NAME="AdBlockDialog.__aboutToShowActionMenu" ID="AdBlockDialog.__aboutToShowActionMenu"></a> |
|
136 <h4>AdBlockDialog.__aboutToShowActionMenu</h4> |
|
137 <b>__aboutToShowActionMenu</b>(<i></i>) |
|
138 <p> |
|
139 Private slot to show the actions menu. |
|
140 </p><a NAME="AdBlockDialog.__addCustomRule" ID="AdBlockDialog.__addCustomRule"></a> |
|
141 <h4>AdBlockDialog.__addCustomRule</h4> |
|
142 <b>__addCustomRule</b>(<i></i>) |
|
143 <p> |
|
144 Private slot to add a custom AdBlock rule. |
|
145 </p><a NAME="AdBlockDialog.__browseSubscriptions" ID="AdBlockDialog.__browseSubscriptions"></a> |
|
146 <h4>AdBlockDialog.__browseSubscriptions</h4> |
|
147 <b>__browseSubscriptions</b>(<i></i>) |
|
148 <p> |
|
149 Private slot to browse the list of available AdBlock subscriptions. |
|
150 </p><a NAME="AdBlockDialog.__learnAboutWritingFilters" ID="AdBlockDialog.__learnAboutWritingFilters"></a> |
|
151 <h4>AdBlockDialog.__learnAboutWritingFilters</h4> |
|
152 <b>__learnAboutWritingFilters</b>(<i></i>) |
|
153 <p> |
|
154 Private slot to show the web page about how to write filters. |
|
155 </p><a NAME="AdBlockDialog.__load" ID="AdBlockDialog.__load"></a> |
|
156 <h4>AdBlockDialog.__load</h4> |
|
157 <b>__load</b>(<i></i>) |
|
158 <p> |
|
159 Private slot to populate the tab widget with subscriptions. |
|
160 </p><a NAME="AdBlockDialog.__loadSubscriptions" ID="AdBlockDialog.__loadSubscriptions"></a> |
|
161 <h4>AdBlockDialog.__loadSubscriptions</h4> |
|
162 <b>__loadSubscriptions</b>(<i></i>) |
|
163 <p> |
|
164 Private slot to load the AdBlock subscription rules. |
|
165 </p><a NAME="AdBlockDialog.__removeCustomRule" ID="AdBlockDialog.__removeCustomRule"></a> |
|
166 <h4>AdBlockDialog.__removeCustomRule</h4> |
|
167 <b>__removeCustomRule</b>(<i></i>) |
|
168 <p> |
|
169 Private slot to remove a custom AdBlock rule. |
|
170 </p><a NAME="AdBlockDialog.__removeSubscription" ID="AdBlockDialog.__removeSubscription"></a> |
|
171 <h4>AdBlockDialog.__removeSubscription</h4> |
|
172 <b>__removeSubscription</b>(<i></i>) |
|
173 <p> |
|
174 Private slot to remove the selected subscription. |
|
175 </p><a NAME="AdBlockDialog.__setSubscriptionEnabled" ID="AdBlockDialog.__setSubscriptionEnabled"></a> |
|
176 <h4>AdBlockDialog.__setSubscriptionEnabled</h4> |
|
177 <b>__setSubscriptionEnabled</b>(<i>subscription, enable</i>) |
|
178 <p> |
|
179 Private slot to set the enabled state of a subscription. |
|
180 </p><dl> |
|
181 <dt><i>subscription</i></dt> |
|
182 <dd> |
|
183 subscription to set the state for |
|
184 (AdBlockSubscription) |
|
185 </dd><dt><i>enable</i></dt> |
|
186 <dd> |
|
187 state to set to (boolean) |
|
188 </dd> |
|
189 </dl><a NAME="AdBlockDialog.__switchSubscriptionEnabled" ID="AdBlockDialog.__switchSubscriptionEnabled"></a> |
|
190 <h4>AdBlockDialog.__switchSubscriptionEnabled</h4> |
|
191 <b>__switchSubscriptionEnabled</b>(<i></i>) |
|
192 <p> |
|
193 Private slot to switch the enabled state of the selected subscription. |
|
194 </p><a NAME="AdBlockDialog.__updateAllSubscriptions" ID="AdBlockDialog.__updateAllSubscriptions"></a> |
|
195 <h4>AdBlockDialog.__updateAllSubscriptions</h4> |
|
196 <b>__updateAllSubscriptions</b>(<i></i>) |
|
197 <p> |
|
198 Private slot to update all subscriptions. |
|
199 </p><a NAME="AdBlockDialog.__updateSubscription" ID="AdBlockDialog.__updateSubscription"></a> |
|
200 <h4>AdBlockDialog.__updateSubscription</h4> |
|
201 <b>__updateSubscription</b>(<i></i>) |
|
202 <p> |
|
203 Private slot to update the selected subscription. |
|
204 </p><a NAME="AdBlockDialog.addCustomRule" ID="AdBlockDialog.addCustomRule"></a> |
|
205 <h4>AdBlockDialog.addCustomRule</h4> |
|
206 <b>addCustomRule</b>(<i>filter</i>) |
|
207 <p> |
|
208 Public slot to add a custom AdBlock rule. |
|
209 </p><dl> |
|
210 <dt><i>filter</i></dt> |
|
211 <dd> |
|
212 filter to be added (string) |
|
213 </dd> |
|
214 </dl><a NAME="AdBlockDialog.addSubscription" ID="AdBlockDialog.addSubscription"></a> |
|
215 <h4>AdBlockDialog.addSubscription</h4> |
|
216 <b>addSubscription</b>(<i>subscription, refresh=True</i>) |
|
217 <p> |
|
218 Public slot adding a subscription to the list. |
|
219 </p><dl> |
|
220 <dt><i>subscription</i></dt> |
|
221 <dd> |
|
222 reference to the subscription to be |
|
223 added (AdBlockSubscription) |
|
224 </dd><dt><i>refresh</i></dt> |
|
225 <dd> |
|
226 flag indicating to refresh the tree (boolean) |
|
227 </dd> |
|
228 </dl><a NAME="AdBlockDialog.on_adBlockGroup_toggled" ID="AdBlockDialog.on_adBlockGroup_toggled"></a> |
|
229 <h4>AdBlockDialog.on_adBlockGroup_toggled</h4> |
|
230 <b>on_adBlockGroup_toggled</b>(<i>state</i>) |
|
231 <p> |
|
232 Private slot handling the enabling/disabling of AdBlock. |
|
233 </p><dl> |
|
234 <dt><i>state</i></dt> |
|
235 <dd> |
|
236 state of the toggle (boolean) |
|
237 </dd> |
|
238 </dl><a NAME="AdBlockDialog.on_searchEdit_textChanged" ID="AdBlockDialog.on_searchEdit_textChanged"></a> |
|
239 <h4>AdBlockDialog.on_searchEdit_textChanged</h4> |
|
240 <b>on_searchEdit_textChanged</b>(<i>filter</i>) |
|
241 <p> |
|
242 Private slot to set a new filter on the current widget. |
|
243 </p><dl> |
|
244 <dt><i>filter</i></dt> |
|
245 <dd> |
|
246 filter to be set (string) |
|
247 </dd> |
|
248 </dl><a NAME="AdBlockDialog.on_subscriptionsTabWidget_currentChanged" ID="AdBlockDialog.on_subscriptionsTabWidget_currentChanged"></a> |
|
249 <h4>AdBlockDialog.on_subscriptionsTabWidget_currentChanged</h4> |
|
250 <b>on_subscriptionsTabWidget_currentChanged</b>(<i>index</i>) |
|
251 <p> |
|
252 Private slot handling the selection of another tab. |
|
253 </p><dl> |
|
254 <dt><i>index</i></dt> |
|
255 <dd> |
|
256 index of the new current tab (integer) |
|
257 </dd> |
|
258 </dl><a NAME="AdBlockDialog.on_updateSpinBox_valueChanged" ID="AdBlockDialog.on_updateSpinBox_valueChanged"></a> |
|
259 <h4>AdBlockDialog.on_updateSpinBox_valueChanged</h4> |
|
260 <b>on_updateSpinBox_valueChanged</b>(<i>value</i>) |
|
261 <p> |
|
262 Private slot to handle changes of the update period. |
|
263 </p><dl> |
|
264 <dt><i>value</i></dt> |
|
265 <dd> |
|
266 update period (integer) |
|
267 </dd> |
|
268 </dl><a NAME="AdBlockDialog.showRule" ID="AdBlockDialog.showRule"></a> |
|
269 <h4>AdBlockDialog.showRule</h4> |
|
270 <b>showRule</b>(<i>rule</i>) |
|
271 <p> |
|
272 Public slot to show the given rule. |
|
273 </p><dl> |
|
274 <dt><i>rule</i></dt> |
|
275 <dd> |
|
276 rule to be shown (AdBlockRule) |
|
277 </dd> |
|
278 </dl> |
|
279 <div align="right"><a href="#top">Up</a></div> |
|
280 <hr /> |
|
281 </body></html> |