|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric7.WebBrowser.Bookmarks.BookmarksDialog</title> |
|
4 <meta charset="UTF-8"> |
|
5 <link rel="stylesheet" href="styles.css"> |
|
6 </head> |
|
7 <body> |
|
8 <a NAME="top" ID="top"></a> |
|
9 <h1>eric7.WebBrowser.Bookmarks.BookmarksDialog</h1> |
|
10 |
|
11 <p> |
|
12 Module implementing a dialog to manage bookmarks. |
|
13 </p> |
|
14 <h3>Global Attributes</h3> |
|
15 |
|
16 <table> |
|
17 <tr><td>None</td></tr> |
|
18 </table> |
|
19 <h3>Classes</h3> |
|
20 |
|
21 <table> |
|
22 |
|
23 <tr> |
|
24 <td><a href="#BookmarksDialog">BookmarksDialog</a></td> |
|
25 <td>Class implementing a dialog to manage bookmarks.</td> |
|
26 </tr> |
|
27 </table> |
|
28 <h3>Functions</h3> |
|
29 |
|
30 <table> |
|
31 <tr><td>None</td></tr> |
|
32 </table> |
|
33 <hr /> |
|
34 <hr /> |
|
35 <a NAME="BookmarksDialog" ID="BookmarksDialog"></a> |
|
36 <h2>BookmarksDialog</h2> |
|
37 |
|
38 <p> |
|
39 Class implementing a dialog to manage bookmarks. |
|
40 </p> |
|
41 <h3>Signals</h3> |
|
42 <dl> |
|
43 |
|
44 <dt>newBackgroundTab(QUrl, str)</dt> |
|
45 <dd> |
|
46 emitted to open a URL in a new |
|
47 background tab |
|
48 </dd> |
|
49 <dt>newTab(QUrl, str)</dt> |
|
50 <dd> |
|
51 emitted to open a URL in a new tab |
|
52 </dd> |
|
53 <dt>newWindow(QUrl, str)</dt> |
|
54 <dd> |
|
55 emitted to open a URL in a new window |
|
56 </dd> |
|
57 <dt>openUrl(QUrl, str)</dt> |
|
58 <dd> |
|
59 emitted to open a URL in the current tab |
|
60 </dd> |
|
61 </dl> |
|
62 <h3>Derived from</h3> |
|
63 QDialog, Ui_BookmarksDialog |
|
64 <h3>Class Attributes</h3> |
|
65 |
|
66 <table> |
|
67 <tr><td>None</td></tr> |
|
68 </table> |
|
69 <h3>Class Methods</h3> |
|
70 |
|
71 <table> |
|
72 <tr><td>None</td></tr> |
|
73 </table> |
|
74 <h3>Methods</h3> |
|
75 |
|
76 <table> |
|
77 |
|
78 <tr> |
|
79 <td><a href="#BookmarksDialog.__init__">BookmarksDialog</a></td> |
|
80 <td>Constructor</td> |
|
81 </tr> |
|
82 <tr> |
|
83 <td><a href="#BookmarksDialog.__activated">__activated</a></td> |
|
84 <td>Private slot to handle the activation of an entry.</td> |
|
85 </tr> |
|
86 <tr> |
|
87 <td><a href="#BookmarksDialog.__customContextMenuRequested">__customContextMenuRequested</a></td> |
|
88 <td>Private slot to handle the context menu request for the bookmarks tree.</td> |
|
89 </tr> |
|
90 <tr> |
|
91 <td><a href="#BookmarksDialog.__edit">__edit</a></td> |
|
92 <td>Private slot to edit a bookmarks properties.</td> |
|
93 </tr> |
|
94 <tr> |
|
95 <td><a href="#BookmarksDialog.__editAddress">__editAddress</a></td> |
|
96 <td>Private slot to edit the address part of a bookmark.</td> |
|
97 </tr> |
|
98 <tr> |
|
99 <td><a href="#BookmarksDialog.__editName">__editName</a></td> |
|
100 <td>Private slot to edit the name part of a bookmark.</td> |
|
101 </tr> |
|
102 <tr> |
|
103 <td><a href="#BookmarksDialog.__expandNodes">__expandNodes</a></td> |
|
104 <td>Private method to expand all child nodes of a node.</td> |
|
105 </tr> |
|
106 <tr> |
|
107 <td><a href="#BookmarksDialog.__newFolder">__newFolder</a></td> |
|
108 <td>Private slot to add a new bookmarks folder.</td> |
|
109 </tr> |
|
110 <tr> |
|
111 <td><a href="#BookmarksDialog.__openBookmark">__openBookmark</a></td> |
|
112 <td>Private method to open a bookmark.</td> |
|
113 </tr> |
|
114 <tr> |
|
115 <td><a href="#BookmarksDialog.__openBookmarkInCurrentTab">__openBookmarkInCurrentTab</a></td> |
|
116 <td>Private slot to open a bookmark in the current browser tab.</td> |
|
117 </tr> |
|
118 <tr> |
|
119 <td><a href="#BookmarksDialog.__openBookmarkInNewBackgroundTab">__openBookmarkInNewBackgroundTab</a></td> |
|
120 <td>Private slot to open a bookmark in a new browser tab.</td> |
|
121 </tr> |
|
122 <tr> |
|
123 <td><a href="#BookmarksDialog.__openBookmarkInNewTab">__openBookmarkInNewTab</a></td> |
|
124 <td>Private slot to open a bookmark in a new browser tab.</td> |
|
125 </tr> |
|
126 <tr> |
|
127 <td><a href="#BookmarksDialog.__openBookmarkInNewWindow">__openBookmarkInNewWindow</a></td> |
|
128 <td>Private slot to open a bookmark in a new browser window.</td> |
|
129 </tr> |
|
130 <tr> |
|
131 <td><a href="#BookmarksDialog.__openBookmarkInPrivateWindow">__openBookmarkInPrivateWindow</a></td> |
|
132 <td>Private slot to open a bookmark in a new private browser window.</td> |
|
133 </tr> |
|
134 <tr> |
|
135 <td><a href="#BookmarksDialog.__saveExpandedNodes">__saveExpandedNodes</a></td> |
|
136 <td>Private method to save the child nodes of an expanded node.</td> |
|
137 </tr> |
|
138 <tr> |
|
139 <td><a href="#BookmarksDialog.__shutdown">__shutdown</a></td> |
|
140 <td>Private method to perform shutdown actions for the dialog.</td> |
|
141 </tr> |
|
142 <tr> |
|
143 <td><a href="#BookmarksDialog.closeEvent">closeEvent</a></td> |
|
144 <td>Protected method to handle the closing of the dialog.</td> |
|
145 </tr> |
|
146 <tr> |
|
147 <td><a href="#BookmarksDialog.reject">reject</a></td> |
|
148 <td>Public method called when the dialog is rejected.</td> |
|
149 </tr> |
|
150 </table> |
|
151 <h3>Static Methods</h3> |
|
152 |
|
153 <table> |
|
154 <tr><td>None</td></tr> |
|
155 </table> |
|
156 |
|
157 <a NAME="BookmarksDialog.__init__" ID="BookmarksDialog.__init__"></a> |
|
158 <h4>BookmarksDialog (Constructor)</h4> |
|
159 <b>BookmarksDialog</b>(<i>parent=None, manager=None</i>) |
|
160 |
|
161 <p> |
|
162 Constructor |
|
163 </p> |
|
164 <dl> |
|
165 |
|
166 <dt><i>parent</i></dt> |
|
167 <dd> |
|
168 reference to the parent widget (QWidget |
|
169 </dd> |
|
170 <dt><i>manager</i></dt> |
|
171 <dd> |
|
172 reference to the bookmarks manager object |
|
173 (BookmarksManager) |
|
174 </dd> |
|
175 </dl> |
|
176 <a NAME="BookmarksDialog.__activated" ID="BookmarksDialog.__activated"></a> |
|
177 <h4>BookmarksDialog.__activated</h4> |
|
178 <b>__activated</b>(<i>idx</i>) |
|
179 |
|
180 <p> |
|
181 Private slot to handle the activation of an entry. |
|
182 </p> |
|
183 <dl> |
|
184 |
|
185 <dt><i>idx</i></dt> |
|
186 <dd> |
|
187 reference to the entry index (QModelIndex) |
|
188 </dd> |
|
189 </dl> |
|
190 <a NAME="BookmarksDialog.__customContextMenuRequested" ID="BookmarksDialog.__customContextMenuRequested"></a> |
|
191 <h4>BookmarksDialog.__customContextMenuRequested</h4> |
|
192 <b>__customContextMenuRequested</b>(<i>pos</i>) |
|
193 |
|
194 <p> |
|
195 Private slot to handle the context menu request for the bookmarks tree. |
|
196 </p> |
|
197 <dl> |
|
198 |
|
199 <dt><i>pos</i></dt> |
|
200 <dd> |
|
201 position the context menu was requested (QPoint) |
|
202 </dd> |
|
203 </dl> |
|
204 <a NAME="BookmarksDialog.__edit" ID="BookmarksDialog.__edit"></a> |
|
205 <h4>BookmarksDialog.__edit</h4> |
|
206 <b>__edit</b>(<i></i>) |
|
207 |
|
208 <p> |
|
209 Private slot to edit a bookmarks properties. |
|
210 </p> |
|
211 <a NAME="BookmarksDialog.__editAddress" ID="BookmarksDialog.__editAddress"></a> |
|
212 <h4>BookmarksDialog.__editAddress</h4> |
|
213 <b>__editAddress</b>(<i></i>) |
|
214 |
|
215 <p> |
|
216 Private slot to edit the address part of a bookmark. |
|
217 </p> |
|
218 <a NAME="BookmarksDialog.__editName" ID="BookmarksDialog.__editName"></a> |
|
219 <h4>BookmarksDialog.__editName</h4> |
|
220 <b>__editName</b>(<i></i>) |
|
221 |
|
222 <p> |
|
223 Private slot to edit the name part of a bookmark. |
|
224 </p> |
|
225 <a NAME="BookmarksDialog.__expandNodes" ID="BookmarksDialog.__expandNodes"></a> |
|
226 <h4>BookmarksDialog.__expandNodes</h4> |
|
227 <b>__expandNodes</b>(<i>node</i>) |
|
228 |
|
229 <p> |
|
230 Private method to expand all child nodes of a node. |
|
231 </p> |
|
232 <dl> |
|
233 |
|
234 <dt><i>node</i></dt> |
|
235 <dd> |
|
236 reference to the bookmark node to expand (BookmarkNode) |
|
237 </dd> |
|
238 </dl> |
|
239 <a NAME="BookmarksDialog.__newFolder" ID="BookmarksDialog.__newFolder"></a> |
|
240 <h4>BookmarksDialog.__newFolder</h4> |
|
241 <b>__newFolder</b>(<i></i>) |
|
242 |
|
243 <p> |
|
244 Private slot to add a new bookmarks folder. |
|
245 </p> |
|
246 <a NAME="BookmarksDialog.__openBookmark" ID="BookmarksDialog.__openBookmark"></a> |
|
247 <h4>BookmarksDialog.__openBookmark</h4> |
|
248 <b>__openBookmark</b>(<i>newTab=False, newWindow=False, privateWindow=False, background=False</i>) |
|
249 |
|
250 <p> |
|
251 Private method to open a bookmark. |
|
252 </p> |
|
253 <dl> |
|
254 |
|
255 <dt><i>newTab</i> (bool)</dt> |
|
256 <dd> |
|
257 flag indicating to open the bookmark in a new tab |
|
258 </dd> |
|
259 <dt><i>newWindow</i> (bool)</dt> |
|
260 <dd> |
|
261 flag indicating to open the bookmark in a new window |
|
262 </dd> |
|
263 <dt><i>privateWindow</i> (bool)</dt> |
|
264 <dd> |
|
265 flag indicating to open the bookmark in a new |
|
266 private window |
|
267 </dd> |
|
268 <dt><i>background</i> (bool)</dt> |
|
269 <dd> |
|
270 flag indicating to open the bookmark in a new |
|
271 background tab |
|
272 </dd> |
|
273 </dl> |
|
274 <a NAME="BookmarksDialog.__openBookmarkInCurrentTab" ID="BookmarksDialog.__openBookmarkInCurrentTab"></a> |
|
275 <h4>BookmarksDialog.__openBookmarkInCurrentTab</h4> |
|
276 <b>__openBookmarkInCurrentTab</b>(<i></i>) |
|
277 |
|
278 <p> |
|
279 Private slot to open a bookmark in the current browser tab. |
|
280 </p> |
|
281 <a NAME="BookmarksDialog.__openBookmarkInNewBackgroundTab" ID="BookmarksDialog.__openBookmarkInNewBackgroundTab"></a> |
|
282 <h4>BookmarksDialog.__openBookmarkInNewBackgroundTab</h4> |
|
283 <b>__openBookmarkInNewBackgroundTab</b>(<i></i>) |
|
284 |
|
285 <p> |
|
286 Private slot to open a bookmark in a new browser tab. |
|
287 </p> |
|
288 <a NAME="BookmarksDialog.__openBookmarkInNewTab" ID="BookmarksDialog.__openBookmarkInNewTab"></a> |
|
289 <h4>BookmarksDialog.__openBookmarkInNewTab</h4> |
|
290 <b>__openBookmarkInNewTab</b>(<i></i>) |
|
291 |
|
292 <p> |
|
293 Private slot to open a bookmark in a new browser tab. |
|
294 </p> |
|
295 <a NAME="BookmarksDialog.__openBookmarkInNewWindow" ID="BookmarksDialog.__openBookmarkInNewWindow"></a> |
|
296 <h4>BookmarksDialog.__openBookmarkInNewWindow</h4> |
|
297 <b>__openBookmarkInNewWindow</b>(<i></i>) |
|
298 |
|
299 <p> |
|
300 Private slot to open a bookmark in a new browser window. |
|
301 </p> |
|
302 <a NAME="BookmarksDialog.__openBookmarkInPrivateWindow" ID="BookmarksDialog.__openBookmarkInPrivateWindow"></a> |
|
303 <h4>BookmarksDialog.__openBookmarkInPrivateWindow</h4> |
|
304 <b>__openBookmarkInPrivateWindow</b>(<i></i>) |
|
305 |
|
306 <p> |
|
307 Private slot to open a bookmark in a new private browser window. |
|
308 </p> |
|
309 <a NAME="BookmarksDialog.__saveExpandedNodes" ID="BookmarksDialog.__saveExpandedNodes"></a> |
|
310 <h4>BookmarksDialog.__saveExpandedNodes</h4> |
|
311 <b>__saveExpandedNodes</b>(<i>parent</i>) |
|
312 |
|
313 <p> |
|
314 Private method to save the child nodes of an expanded node. |
|
315 </p> |
|
316 <dl> |
|
317 |
|
318 <dt><i>parent</i></dt> |
|
319 <dd> |
|
320 index of the parent node (QModelIndex) |
|
321 </dd> |
|
322 </dl> |
|
323 <dl> |
|
324 <dt>Return:</dt> |
|
325 <dd> |
|
326 flag indicating a change (boolean) |
|
327 </dd> |
|
328 </dl> |
|
329 <a NAME="BookmarksDialog.__shutdown" ID="BookmarksDialog.__shutdown"></a> |
|
330 <h4>BookmarksDialog.__shutdown</h4> |
|
331 <b>__shutdown</b>(<i></i>) |
|
332 |
|
333 <p> |
|
334 Private method to perform shutdown actions for the dialog. |
|
335 </p> |
|
336 <a NAME="BookmarksDialog.closeEvent" ID="BookmarksDialog.closeEvent"></a> |
|
337 <h4>BookmarksDialog.closeEvent</h4> |
|
338 <b>closeEvent</b>(<i>evt</i>) |
|
339 |
|
340 <p> |
|
341 Protected method to handle the closing of the dialog. |
|
342 </p> |
|
343 <dl> |
|
344 |
|
345 <dt><i>evt</i></dt> |
|
346 <dd> |
|
347 reference to the event object (QCloseEvent) (ignored) |
|
348 </dd> |
|
349 </dl> |
|
350 <a NAME="BookmarksDialog.reject" ID="BookmarksDialog.reject"></a> |
|
351 <h4>BookmarksDialog.reject</h4> |
|
352 <b>reject</b>(<i></i>) |
|
353 |
|
354 <p> |
|
355 Public method called when the dialog is rejected. |
|
356 </p> |
|
357 <div align="right"><a href="#top">Up</a></div> |
|
358 <hr /> |
|
359 </body></html> |