|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric7.Project.ProjectBaseBrowser</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> |
|
22 <a NAME="top" ID="top"></a> |
|
23 <h1>eric7.Project.ProjectBaseBrowser</h1> |
|
24 |
|
25 <p> |
|
26 Module implementing the baseclass for the various project browsers. |
|
27 </p> |
|
28 <h3>Global Attributes</h3> |
|
29 |
|
30 <table> |
|
31 <tr><td>None</td></tr> |
|
32 </table> |
|
33 <h3>Classes</h3> |
|
34 |
|
35 <table> |
|
36 |
|
37 <tr> |
|
38 <td><a href="#ProjectBaseBrowser">ProjectBaseBrowser</a></td> |
|
39 <td>Baseclass implementing common functionality for the various project browsers.</td> |
|
40 </tr> |
|
41 </table> |
|
42 <h3>Functions</h3> |
|
43 |
|
44 <table> |
|
45 <tr><td>None</td></tr> |
|
46 </table> |
|
47 <hr /> |
|
48 <hr /> |
|
49 <a NAME="ProjectBaseBrowser" ID="ProjectBaseBrowser"></a> |
|
50 <h2>ProjectBaseBrowser</h2> |
|
51 |
|
52 <p> |
|
53 Baseclass implementing common functionality for the various project |
|
54 browsers. |
|
55 </p> |
|
56 <h3>Signals</h3> |
|
57 <dl> |
|
58 |
|
59 <dt>closeSourceWindow(str)</dt> |
|
60 <dd> |
|
61 emitted to close a source file |
|
62 </dd> |
|
63 </dl> |
|
64 <h3>Derived from</h3> |
|
65 Browser |
|
66 <h3>Class Attributes</h3> |
|
67 |
|
68 <table> |
|
69 <tr><td>None</td></tr> |
|
70 </table> |
|
71 <h3>Class Methods</h3> |
|
72 |
|
73 <table> |
|
74 <tr><td>None</td></tr> |
|
75 </table> |
|
76 <h3>Methods</h3> |
|
77 |
|
78 <table> |
|
79 |
|
80 <tr> |
|
81 <td><a href="#ProjectBaseBrowser.__init__">ProjectBaseBrowser</a></td> |
|
82 <td>Constructor</td> |
|
83 </tr> |
|
84 <tr> |
|
85 <td><a href="#ProjectBaseBrowser.__checkHookKey">__checkHookKey</a></td> |
|
86 <td>Private method to check a hook key.</td> |
|
87 </tr> |
|
88 <tr> |
|
89 <td><a href="#ProjectBaseBrowser.__modelRowsInserted">__modelRowsInserted</a></td> |
|
90 <td>Private slot called after rows have been inserted into the model.</td> |
|
91 </tr> |
|
92 <tr> |
|
93 <td><a href="#ProjectBaseBrowser._collapseAllDirs">_collapseAllDirs</a></td> |
|
94 <td>Protected slot to handle the 'Collapse all directories' menu action.</td> |
|
95 </tr> |
|
96 <tr> |
|
97 <td><a href="#ProjectBaseBrowser._completeRepopulateItem">_completeRepopulateItem</a></td> |
|
98 <td>Protected slot to handle the completeRepopulateItem signal.</td> |
|
99 </tr> |
|
100 <tr> |
|
101 <td><a href="#ProjectBaseBrowser._configure">_configure</a></td> |
|
102 <td>Protected method to open the configuration dialog.</td> |
|
103 </tr> |
|
104 <tr> |
|
105 <td><a href="#ProjectBaseBrowser._connectExpandedCollapsed">_connectExpandedCollapsed</a></td> |
|
106 <td>Protected method to connect the expanded and collapsed signals.</td> |
|
107 </tr> |
|
108 <tr> |
|
109 <td><a href="#ProjectBaseBrowser._contextMenuRequested">_contextMenuRequested</a></td> |
|
110 <td>Protected slot to show the context menu.</td> |
|
111 </tr> |
|
112 <tr> |
|
113 <td><a href="#ProjectBaseBrowser._copyToClipboard">_copyToClipboard</a></td> |
|
114 <td>Protected method to copy the path of an entry to the clipboard.</td> |
|
115 </tr> |
|
116 <tr> |
|
117 <td><a href="#ProjectBaseBrowser._createPopupMenus">_createPopupMenus</a></td> |
|
118 <td>Protected overloaded method to generate the popup menus.</td> |
|
119 </tr> |
|
120 <tr> |
|
121 <td><a href="#ProjectBaseBrowser._deleteDirectory">_deleteDirectory</a></td> |
|
122 <td>Protected method to delete the selected directory from the project data area.</td> |
|
123 </tr> |
|
124 <tr> |
|
125 <td><a href="#ProjectBaseBrowser._disconnectExpandedCollapsed">_disconnectExpandedCollapsed</a></td> |
|
126 <td>Protected method to disconnect the expanded and collapsed signals.</td> |
|
127 </tr> |
|
128 <tr> |
|
129 <td><a href="#ProjectBaseBrowser._expandAllDirs">_expandAllDirs</a></td> |
|
130 <td>Protected slot to handle the 'Expand all directories' menu action.</td> |
|
131 </tr> |
|
132 <tr> |
|
133 <td><a href="#ProjectBaseBrowser._initHookMethods">_initHookMethods</a></td> |
|
134 <td>Protected method to initialize the hooks dictionary.</td> |
|
135 </tr> |
|
136 <tr> |
|
137 <td><a href="#ProjectBaseBrowser._initMenusAndVcs">_initMenusAndVcs</a></td> |
|
138 <td>Protected slot to initialize the menus and the Vcs interface.</td> |
|
139 </tr> |
|
140 <tr> |
|
141 <td><a href="#ProjectBaseBrowser._keyboardSearchType">_keyboardSearchType</a></td> |
|
142 <td>Protected method to check, if the item is of the correct type.</td> |
|
143 </tr> |
|
144 <tr> |
|
145 <td><a href="#ProjectBaseBrowser._newProject">_newProject</a></td> |
|
146 <td>Protected slot to handle the newProject signal.</td> |
|
147 </tr> |
|
148 <tr> |
|
149 <td><a href="#ProjectBaseBrowser._prepareRepopulateItem">_prepareRepopulateItem</a></td> |
|
150 <td>Protected slot to handle the prepareRepopulateItem signal.</td> |
|
151 </tr> |
|
152 <tr> |
|
153 <td><a href="#ProjectBaseBrowser._projectClosed">_projectClosed</a></td> |
|
154 <td>Protected slot to handle the projectClosed signal.</td> |
|
155 </tr> |
|
156 <tr> |
|
157 <td><a href="#ProjectBaseBrowser._projectOpened">_projectOpened</a></td> |
|
158 <td>Protected slot to handle the projectOpened signal.</td> |
|
159 </tr> |
|
160 <tr> |
|
161 <td><a href="#ProjectBaseBrowser._removeDir">_removeDir</a></td> |
|
162 <td>Protected method to remove a (single) directory from the project.</td> |
|
163 </tr> |
|
164 <tr> |
|
165 <td><a href="#ProjectBaseBrowser._removeFile">_removeFile</a></td> |
|
166 <td>Protected method to remove a file or files from the project.</td> |
|
167 </tr> |
|
168 <tr> |
|
169 <td><a href="#ProjectBaseBrowser._renameFile">_renameFile</a></td> |
|
170 <td>Protected method to rename a file of the project.</td> |
|
171 </tr> |
|
172 <tr> |
|
173 <td><a href="#ProjectBaseBrowser._selectEntries">_selectEntries</a></td> |
|
174 <td>Protected method to select entries based on their VCS status.</td> |
|
175 </tr> |
|
176 <tr> |
|
177 <td><a href="#ProjectBaseBrowser._selectSingleItem">_selectSingleItem</a></td> |
|
178 <td>Protected method to select a single item.</td> |
|
179 </tr> |
|
180 <tr> |
|
181 <td><a href="#ProjectBaseBrowser._setItemRangeSelected">_setItemRangeSelected</a></td> |
|
182 <td>Protected method to set the selection status of a range of items.</td> |
|
183 </tr> |
|
184 <tr> |
|
185 <td><a href="#ProjectBaseBrowser._setItemSelected">_setItemSelected</a></td> |
|
186 <td>Protected method to set the selection status of an item.</td> |
|
187 </tr> |
|
188 <tr> |
|
189 <td><a href="#ProjectBaseBrowser._showContextMenu">_showContextMenu</a></td> |
|
190 <td>Protected slot called before the context menu is shown.</td> |
|
191 </tr> |
|
192 <tr> |
|
193 <td><a href="#ProjectBaseBrowser._showContextMenuBack">_showContextMenuBack</a></td> |
|
194 <td>Protected slot called before the context menu is shown.</td> |
|
195 </tr> |
|
196 <tr> |
|
197 <td><a href="#ProjectBaseBrowser._showContextMenuDir">_showContextMenuDir</a></td> |
|
198 <td>Protected slot called before the context menu is shown.</td> |
|
199 </tr> |
|
200 <tr> |
|
201 <td><a href="#ProjectBaseBrowser._showContextMenuDirMulti">_showContextMenuDirMulti</a></td> |
|
202 <td>Protected slot called before the context menu is shown.</td> |
|
203 </tr> |
|
204 <tr> |
|
205 <td><a href="#ProjectBaseBrowser._showContextMenuMulti">_showContextMenuMulti</a></td> |
|
206 <td>Protected slot called before the context menu (multiple selections) is shown.</td> |
|
207 </tr> |
|
208 <tr> |
|
209 <td><a href="#ProjectBaseBrowser.addHookMethod">addHookMethod</a></td> |
|
210 <td>Public method to add a hook method to the dictionary.</td> |
|
211 </tr> |
|
212 <tr> |
|
213 <td><a href="#ProjectBaseBrowser.addHookMethodAndMenuEntry">addHookMethodAndMenuEntry</a></td> |
|
214 <td>Public method to add a hook method to the dictionary.</td> |
|
215 </tr> |
|
216 <tr> |
|
217 <td><a href="#ProjectBaseBrowser.currentItem">currentItem</a></td> |
|
218 <td>Public method to get a reference to the current item.</td> |
|
219 </tr> |
|
220 <tr> |
|
221 <td><a href="#ProjectBaseBrowser.expandItemsByName">expandItemsByName</a></td> |
|
222 <td>Public method to expand items given their names.</td> |
|
223 </tr> |
|
224 <tr> |
|
225 <td><a href="#ProjectBaseBrowser.getExpandedItemNames">getExpandedItemNames</a></td> |
|
226 <td>Public method to get the file/directory names of all expanded items.</td> |
|
227 </tr> |
|
228 <tr> |
|
229 <td><a href="#ProjectBaseBrowser.removeHookMethod">removeHookMethod</a></td> |
|
230 <td>Public method to remove a hook method from the dictionary.</td> |
|
231 </tr> |
|
232 <tr> |
|
233 <td><a href="#ProjectBaseBrowser.selectFile">selectFile</a></td> |
|
234 <td>Public method to highlight a node given its filename.</td> |
|
235 </tr> |
|
236 <tr> |
|
237 <td><a href="#ProjectBaseBrowser.selectFileLine">selectFileLine</a></td> |
|
238 <td>Public method to highlight a node given its filename.</td> |
|
239 </tr> |
|
240 <tr> |
|
241 <td><a href="#ProjectBaseBrowser.selectLocalDirEntries">selectLocalDirEntries</a></td> |
|
242 <td>Public slot to handle the select local directories context menu entries.</td> |
|
243 </tr> |
|
244 <tr> |
|
245 <td><a href="#ProjectBaseBrowser.selectLocalEntries">selectLocalEntries</a></td> |
|
246 <td>Public slot to handle the select local files context menu entries.</td> |
|
247 </tr> |
|
248 <tr> |
|
249 <td><a href="#ProjectBaseBrowser.selectVCSDirEntries">selectVCSDirEntries</a></td> |
|
250 <td>Public slot to handle the select VCS directories context menu entries.</td> |
|
251 </tr> |
|
252 <tr> |
|
253 <td><a href="#ProjectBaseBrowser.selectVCSEntries">selectVCSEntries</a></td> |
|
254 <td>Public slot to handle the select VCS files context menu entries.</td> |
|
255 </tr> |
|
256 </table> |
|
257 <h3>Static Methods</h3> |
|
258 |
|
259 <table> |
|
260 <tr><td>None</td></tr> |
|
261 </table> |
|
262 |
|
263 <a NAME="ProjectBaseBrowser.__init__" ID="ProjectBaseBrowser.__init__"></a> |
|
264 <h4>ProjectBaseBrowser (Constructor)</h4> |
|
265 <b>ProjectBaseBrowser</b>(<i>project, type_, parent=None</i>) |
|
266 |
|
267 <p> |
|
268 Constructor |
|
269 </p> |
|
270 <dl> |
|
271 |
|
272 <dt><i>project</i></dt> |
|
273 <dd> |
|
274 reference to the project object |
|
275 </dd> |
|
276 <dt><i>type_</i></dt> |
|
277 <dd> |
|
278 project browser type (string) |
|
279 </dd> |
|
280 <dt><i>parent</i></dt> |
|
281 <dd> |
|
282 parent widget of this browser |
|
283 </dd> |
|
284 </dl> |
|
285 <a NAME="ProjectBaseBrowser.__checkHookKey" ID="ProjectBaseBrowser.__checkHookKey"></a> |
|
286 <h4>ProjectBaseBrowser.__checkHookKey</h4> |
|
287 <b>__checkHookKey</b>(<i>key</i>) |
|
288 |
|
289 <p> |
|
290 Private method to check a hook key. |
|
291 </p> |
|
292 <dl> |
|
293 |
|
294 <dt><i>key</i></dt> |
|
295 <dd> |
|
296 key of the hook to check (string) |
|
297 </dd> |
|
298 </dl> |
|
299 <dl> |
|
300 |
|
301 <dt>Raises <b>KeyError</b>:</dt> |
|
302 <dd> |
|
303 raised to indicate an invalid hook |
|
304 </dd> |
|
305 </dl> |
|
306 <a NAME="ProjectBaseBrowser.__modelRowsInserted" ID="ProjectBaseBrowser.__modelRowsInserted"></a> |
|
307 <h4>ProjectBaseBrowser.__modelRowsInserted</h4> |
|
308 <b>__modelRowsInserted</b>(<i>parent, start, end</i>) |
|
309 |
|
310 <p> |
|
311 Private slot called after rows have been inserted into the model. |
|
312 </p> |
|
313 <dl> |
|
314 |
|
315 <dt><i>parent</i></dt> |
|
316 <dd> |
|
317 parent index of inserted rows (QModelIndex) |
|
318 </dd> |
|
319 <dt><i>start</i></dt> |
|
320 <dd> |
|
321 start row number (integer) |
|
322 </dd> |
|
323 <dt><i>end</i></dt> |
|
324 <dd> |
|
325 end row number (integer) |
|
326 </dd> |
|
327 </dl> |
|
328 <a NAME="ProjectBaseBrowser._collapseAllDirs" ID="ProjectBaseBrowser._collapseAllDirs"></a> |
|
329 <h4>ProjectBaseBrowser._collapseAllDirs</h4> |
|
330 <b>_collapseAllDirs</b>(<i></i>) |
|
331 |
|
332 <p> |
|
333 Protected slot to handle the 'Collapse all directories' menu action. |
|
334 </p> |
|
335 <a NAME="ProjectBaseBrowser._completeRepopulateItem" ID="ProjectBaseBrowser._completeRepopulateItem"></a> |
|
336 <h4>ProjectBaseBrowser._completeRepopulateItem</h4> |
|
337 <b>_completeRepopulateItem</b>(<i>name</i>) |
|
338 |
|
339 <p> |
|
340 Protected slot to handle the completeRepopulateItem signal. |
|
341 </p> |
|
342 <dl> |
|
343 |
|
344 <dt><i>name</i></dt> |
|
345 <dd> |
|
346 relative name of file item to be repopulated (string) |
|
347 </dd> |
|
348 </dl> |
|
349 <a NAME="ProjectBaseBrowser._configure" ID="ProjectBaseBrowser._configure"></a> |
|
350 <h4>ProjectBaseBrowser._configure</h4> |
|
351 <b>_configure</b>(<i></i>) |
|
352 |
|
353 <p> |
|
354 Protected method to open the configuration dialog. |
|
355 </p> |
|
356 <a NAME="ProjectBaseBrowser._connectExpandedCollapsed" ID="ProjectBaseBrowser._connectExpandedCollapsed"></a> |
|
357 <h4>ProjectBaseBrowser._connectExpandedCollapsed</h4> |
|
358 <b>_connectExpandedCollapsed</b>(<i></i>) |
|
359 |
|
360 <p> |
|
361 Protected method to connect the expanded and collapsed signals. |
|
362 </p> |
|
363 <a NAME="ProjectBaseBrowser._contextMenuRequested" ID="ProjectBaseBrowser._contextMenuRequested"></a> |
|
364 <h4>ProjectBaseBrowser._contextMenuRequested</h4> |
|
365 <b>_contextMenuRequested</b>(<i>coord</i>) |
|
366 |
|
367 <p> |
|
368 Protected slot to show the context menu. |
|
369 </p> |
|
370 <dl> |
|
371 |
|
372 <dt><i>coord</i></dt> |
|
373 <dd> |
|
374 the position of the mouse pointer (QPoint) |
|
375 </dd> |
|
376 </dl> |
|
377 <a NAME="ProjectBaseBrowser._copyToClipboard" ID="ProjectBaseBrowser._copyToClipboard"></a> |
|
378 <h4>ProjectBaseBrowser._copyToClipboard</h4> |
|
379 <b>_copyToClipboard</b>(<i></i>) |
|
380 |
|
381 <p> |
|
382 Protected method to copy the path of an entry to the clipboard. |
|
383 </p> |
|
384 <a NAME="ProjectBaseBrowser._createPopupMenus" ID="ProjectBaseBrowser._createPopupMenus"></a> |
|
385 <h4>ProjectBaseBrowser._createPopupMenus</h4> |
|
386 <b>_createPopupMenus</b>(<i></i>) |
|
387 |
|
388 <p> |
|
389 Protected overloaded method to generate the popup menus. |
|
390 </p> |
|
391 <a NAME="ProjectBaseBrowser._deleteDirectory" ID="ProjectBaseBrowser._deleteDirectory"></a> |
|
392 <h4>ProjectBaseBrowser._deleteDirectory</h4> |
|
393 <b>_deleteDirectory</b>(<i></i>) |
|
394 |
|
395 <p> |
|
396 Protected method to delete the selected directory from the project |
|
397 data area. |
|
398 </p> |
|
399 <a NAME="ProjectBaseBrowser._disconnectExpandedCollapsed" ID="ProjectBaseBrowser._disconnectExpandedCollapsed"></a> |
|
400 <h4>ProjectBaseBrowser._disconnectExpandedCollapsed</h4> |
|
401 <b>_disconnectExpandedCollapsed</b>(<i></i>) |
|
402 |
|
403 <p> |
|
404 Protected method to disconnect the expanded and collapsed signals. |
|
405 </p> |
|
406 <a NAME="ProjectBaseBrowser._expandAllDirs" ID="ProjectBaseBrowser._expandAllDirs"></a> |
|
407 <h4>ProjectBaseBrowser._expandAllDirs</h4> |
|
408 <b>_expandAllDirs</b>(<i></i>) |
|
409 |
|
410 <p> |
|
411 Protected slot to handle the 'Expand all directories' menu action. |
|
412 </p> |
|
413 <a NAME="ProjectBaseBrowser._initHookMethods" ID="ProjectBaseBrowser._initHookMethods"></a> |
|
414 <h4>ProjectBaseBrowser._initHookMethods</h4> |
|
415 <b>_initHookMethods</b>(<i></i>) |
|
416 |
|
417 <p> |
|
418 Protected method to initialize the hooks dictionary. |
|
419 </p> |
|
420 <p> |
|
421 This method should be overridden by subclasses. All supported |
|
422 hook methods should be initialized with a None value. The keys |
|
423 must be strings. |
|
424 </p> |
|
425 <a NAME="ProjectBaseBrowser._initMenusAndVcs" ID="ProjectBaseBrowser._initMenusAndVcs"></a> |
|
426 <h4>ProjectBaseBrowser._initMenusAndVcs</h4> |
|
427 <b>_initMenusAndVcs</b>(<i></i>) |
|
428 |
|
429 <p> |
|
430 Protected slot to initialize the menus and the Vcs interface. |
|
431 </p> |
|
432 <a NAME="ProjectBaseBrowser._keyboardSearchType" ID="ProjectBaseBrowser._keyboardSearchType"></a> |
|
433 <h4>ProjectBaseBrowser._keyboardSearchType</h4> |
|
434 <b>_keyboardSearchType</b>(<i>item</i>) |
|
435 |
|
436 <p> |
|
437 Protected method to check, if the item is of the correct type. |
|
438 </p> |
|
439 <dl> |
|
440 |
|
441 <dt><i>item</i> (BrowserItem)</dt> |
|
442 <dd> |
|
443 reference to the item |
|
444 </dd> |
|
445 </dl> |
|
446 <dl> |
|
447 <dt>Return:</dt> |
|
448 <dd> |
|
449 flag indicating a correct type |
|
450 </dd> |
|
451 </dl> |
|
452 <dl> |
|
453 <dt>Return Type:</dt> |
|
454 <dd> |
|
455 bool |
|
456 </dd> |
|
457 </dl> |
|
458 <a NAME="ProjectBaseBrowser._newProject" ID="ProjectBaseBrowser._newProject"></a> |
|
459 <h4>ProjectBaseBrowser._newProject</h4> |
|
460 <b>_newProject</b>(<i></i>) |
|
461 |
|
462 <p> |
|
463 Protected slot to handle the newProject signal. |
|
464 </p> |
|
465 <a NAME="ProjectBaseBrowser._prepareRepopulateItem" ID="ProjectBaseBrowser._prepareRepopulateItem"></a> |
|
466 <h4>ProjectBaseBrowser._prepareRepopulateItem</h4> |
|
467 <b>_prepareRepopulateItem</b>(<i>name</i>) |
|
468 |
|
469 <p> |
|
470 Protected slot to handle the prepareRepopulateItem signal. |
|
471 </p> |
|
472 <dl> |
|
473 |
|
474 <dt><i>name</i></dt> |
|
475 <dd> |
|
476 relative name of file item to be repopulated (string) |
|
477 </dd> |
|
478 </dl> |
|
479 <a NAME="ProjectBaseBrowser._projectClosed" ID="ProjectBaseBrowser._projectClosed"></a> |
|
480 <h4>ProjectBaseBrowser._projectClosed</h4> |
|
481 <b>_projectClosed</b>(<i></i>) |
|
482 |
|
483 <p> |
|
484 Protected slot to handle the projectClosed signal. |
|
485 </p> |
|
486 <a NAME="ProjectBaseBrowser._projectOpened" ID="ProjectBaseBrowser._projectOpened"></a> |
|
487 <h4>ProjectBaseBrowser._projectOpened</h4> |
|
488 <b>_projectOpened</b>(<i></i>) |
|
489 |
|
490 <p> |
|
491 Protected slot to handle the projectOpened signal. |
|
492 </p> |
|
493 <a NAME="ProjectBaseBrowser._removeDir" ID="ProjectBaseBrowser._removeDir"></a> |
|
494 <h4>ProjectBaseBrowser._removeDir</h4> |
|
495 <b>_removeDir</b>(<i></i>) |
|
496 |
|
497 <p> |
|
498 Protected method to remove a (single) directory from the project. |
|
499 </p> |
|
500 <a NAME="ProjectBaseBrowser._removeFile" ID="ProjectBaseBrowser._removeFile"></a> |
|
501 <h4>ProjectBaseBrowser._removeFile</h4> |
|
502 <b>_removeFile</b>(<i></i>) |
|
503 |
|
504 <p> |
|
505 Protected method to remove a file or files from the project. |
|
506 </p> |
|
507 <a NAME="ProjectBaseBrowser._renameFile" ID="ProjectBaseBrowser._renameFile"></a> |
|
508 <h4>ProjectBaseBrowser._renameFile</h4> |
|
509 <b>_renameFile</b>(<i></i>) |
|
510 |
|
511 <p> |
|
512 Protected method to rename a file of the project. |
|
513 </p> |
|
514 <a NAME="ProjectBaseBrowser._selectEntries" ID="ProjectBaseBrowser._selectEntries"></a> |
|
515 <h4>ProjectBaseBrowser._selectEntries</h4> |
|
516 <b>_selectEntries</b>(<i>local=True, filterList=None</i>) |
|
517 |
|
518 <p> |
|
519 Protected method to select entries based on their VCS status. |
|
520 </p> |
|
521 <dl> |
|
522 |
|
523 <dt><i>local</i></dt> |
|
524 <dd> |
|
525 flag indicating local (i.e. non VCS controlled) |
|
526 file/directory entries should be selected (boolean) |
|
527 </dd> |
|
528 <dt><i>filterList</i></dt> |
|
529 <dd> |
|
530 list of classes to check against |
|
531 </dd> |
|
532 </dl> |
|
533 <a NAME="ProjectBaseBrowser._selectSingleItem" ID="ProjectBaseBrowser._selectSingleItem"></a> |
|
534 <h4>ProjectBaseBrowser._selectSingleItem</h4> |
|
535 <b>_selectSingleItem</b>(<i>index</i>) |
|
536 |
|
537 <p> |
|
538 Protected method to select a single item. |
|
539 </p> |
|
540 <dl> |
|
541 |
|
542 <dt><i>index</i></dt> |
|
543 <dd> |
|
544 index of item to be selected (QModelIndex) |
|
545 </dd> |
|
546 </dl> |
|
547 <a NAME="ProjectBaseBrowser._setItemRangeSelected" ID="ProjectBaseBrowser._setItemRangeSelected"></a> |
|
548 <h4>ProjectBaseBrowser._setItemRangeSelected</h4> |
|
549 <b>_setItemRangeSelected</b>(<i>startIndex, endIndex, selected</i>) |
|
550 |
|
551 <p> |
|
552 Protected method to set the selection status of a range of items. |
|
553 </p> |
|
554 <dl> |
|
555 |
|
556 <dt><i>startIndex</i></dt> |
|
557 <dd> |
|
558 start index of range of items to set (QModelIndex) |
|
559 </dd> |
|
560 <dt><i>endIndex</i></dt> |
|
561 <dd> |
|
562 end index of range of items to set (QModelIndex) |
|
563 </dd> |
|
564 <dt><i>selected</i></dt> |
|
565 <dd> |
|
566 flag giving the new selection status (boolean) |
|
567 </dd> |
|
568 </dl> |
|
569 <a NAME="ProjectBaseBrowser._setItemSelected" ID="ProjectBaseBrowser._setItemSelected"></a> |
|
570 <h4>ProjectBaseBrowser._setItemSelected</h4> |
|
571 <b>_setItemSelected</b>(<i>index, selected</i>) |
|
572 |
|
573 <p> |
|
574 Protected method to set the selection status of an item. |
|
575 </p> |
|
576 <dl> |
|
577 |
|
578 <dt><i>index</i></dt> |
|
579 <dd> |
|
580 index of item to set (QModelIndex) |
|
581 </dd> |
|
582 <dt><i>selected</i></dt> |
|
583 <dd> |
|
584 flag giving the new selection status (boolean) |
|
585 </dd> |
|
586 </dl> |
|
587 <a NAME="ProjectBaseBrowser._showContextMenu" ID="ProjectBaseBrowser._showContextMenu"></a> |
|
588 <h4>ProjectBaseBrowser._showContextMenu</h4> |
|
589 <b>_showContextMenu</b>(<i>menu</i>) |
|
590 |
|
591 <p> |
|
592 Protected slot called before the context menu is shown. |
|
593 </p> |
|
594 <p> |
|
595 It enables/disables the VCS menu entries depending on the overall |
|
596 VCS status and the file status. |
|
597 </p> |
|
598 <dl> |
|
599 |
|
600 <dt><i>menu</i></dt> |
|
601 <dd> |
|
602 reference to the menu to be shown (QMenu) |
|
603 </dd> |
|
604 </dl> |
|
605 <a NAME="ProjectBaseBrowser._showContextMenuBack" ID="ProjectBaseBrowser._showContextMenuBack"></a> |
|
606 <h4>ProjectBaseBrowser._showContextMenuBack</h4> |
|
607 <b>_showContextMenuBack</b>(<i>menu</i>) |
|
608 |
|
609 <p> |
|
610 Protected slot called before the context menu is shown. |
|
611 </p> |
|
612 <dl> |
|
613 |
|
614 <dt><i>menu</i></dt> |
|
615 <dd> |
|
616 reference to the menu to be shown (QMenu) |
|
617 </dd> |
|
618 </dl> |
|
619 <a NAME="ProjectBaseBrowser._showContextMenuDir" ID="ProjectBaseBrowser._showContextMenuDir"></a> |
|
620 <h4>ProjectBaseBrowser._showContextMenuDir</h4> |
|
621 <b>_showContextMenuDir</b>(<i>menu</i>) |
|
622 |
|
623 <p> |
|
624 Protected slot called before the context menu is shown. |
|
625 </p> |
|
626 <p> |
|
627 It enables/disables the VCS menu entries depending on the overall |
|
628 VCS status and the directory status. |
|
629 </p> |
|
630 <dl> |
|
631 |
|
632 <dt><i>menu</i></dt> |
|
633 <dd> |
|
634 reference to the menu to be shown (QMenu) |
|
635 </dd> |
|
636 </dl> |
|
637 <a NAME="ProjectBaseBrowser._showContextMenuDirMulti" ID="ProjectBaseBrowser._showContextMenuDirMulti"></a> |
|
638 <h4>ProjectBaseBrowser._showContextMenuDirMulti</h4> |
|
639 <b>_showContextMenuDirMulti</b>(<i>menu</i>) |
|
640 |
|
641 <p> |
|
642 Protected slot called before the context menu is shown. |
|
643 </p> |
|
644 <p> |
|
645 It enables/disables the VCS menu entries depending on the overall |
|
646 VCS status and the directory status. |
|
647 </p> |
|
648 <dl> |
|
649 |
|
650 <dt><i>menu</i></dt> |
|
651 <dd> |
|
652 reference to the menu to be shown (QMenu) |
|
653 </dd> |
|
654 </dl> |
|
655 <a NAME="ProjectBaseBrowser._showContextMenuMulti" ID="ProjectBaseBrowser._showContextMenuMulti"></a> |
|
656 <h4>ProjectBaseBrowser._showContextMenuMulti</h4> |
|
657 <b>_showContextMenuMulti</b>(<i>menu</i>) |
|
658 |
|
659 <p> |
|
660 Protected slot called before the context menu (multiple selections) is |
|
661 shown. |
|
662 </p> |
|
663 <p> |
|
664 It enables/disables the VCS menu entries depending on the overall |
|
665 VCS status and the files status. |
|
666 </p> |
|
667 <dl> |
|
668 |
|
669 <dt><i>menu</i></dt> |
|
670 <dd> |
|
671 reference to the menu to be shown (QMenu) |
|
672 </dd> |
|
673 </dl> |
|
674 <a NAME="ProjectBaseBrowser.addHookMethod" ID="ProjectBaseBrowser.addHookMethod"></a> |
|
675 <h4>ProjectBaseBrowser.addHookMethod</h4> |
|
676 <b>addHookMethod</b>(<i>key, method</i>) |
|
677 |
|
678 <p> |
|
679 Public method to add a hook method to the dictionary. |
|
680 </p> |
|
681 <dl> |
|
682 |
|
683 <dt><i>key</i></dt> |
|
684 <dd> |
|
685 for the hook method (string) |
|
686 </dd> |
|
687 <dt><i>method</i></dt> |
|
688 <dd> |
|
689 reference to the hook method (method object) |
|
690 </dd> |
|
691 </dl> |
|
692 <a NAME="ProjectBaseBrowser.addHookMethodAndMenuEntry" ID="ProjectBaseBrowser.addHookMethodAndMenuEntry"></a> |
|
693 <h4>ProjectBaseBrowser.addHookMethodAndMenuEntry</h4> |
|
694 <b>addHookMethodAndMenuEntry</b>(<i>key, method, menuEntry</i>) |
|
695 |
|
696 <p> |
|
697 Public method to add a hook method to the dictionary. |
|
698 </p> |
|
699 <dl> |
|
700 |
|
701 <dt><i>key</i></dt> |
|
702 <dd> |
|
703 for the hook method (string) |
|
704 </dd> |
|
705 <dt><i>method</i></dt> |
|
706 <dd> |
|
707 reference to the hook method (method object) |
|
708 </dd> |
|
709 <dt><i>menuEntry</i></dt> |
|
710 <dd> |
|
711 entry to be shown in the context menu (string) |
|
712 </dd> |
|
713 </dl> |
|
714 <a NAME="ProjectBaseBrowser.currentItem" ID="ProjectBaseBrowser.currentItem"></a> |
|
715 <h4>ProjectBaseBrowser.currentItem</h4> |
|
716 <b>currentItem</b>(<i></i>) |
|
717 |
|
718 <p> |
|
719 Public method to get a reference to the current item. |
|
720 </p> |
|
721 <dl> |
|
722 <dt>Return:</dt> |
|
723 <dd> |
|
724 reference to the current item |
|
725 </dd> |
|
726 </dl> |
|
727 <a NAME="ProjectBaseBrowser.expandItemsByName" ID="ProjectBaseBrowser.expandItemsByName"></a> |
|
728 <h4>ProjectBaseBrowser.expandItemsByName</h4> |
|
729 <b>expandItemsByName</b>(<i>names</i>) |
|
730 |
|
731 <p> |
|
732 Public method to expand items given their names. |
|
733 </p> |
|
734 <dl> |
|
735 |
|
736 <dt><i>names</i></dt> |
|
737 <dd> |
|
738 list of item names to be expanded (list of string) |
|
739 </dd> |
|
740 </dl> |
|
741 <a NAME="ProjectBaseBrowser.getExpandedItemNames" ID="ProjectBaseBrowser.getExpandedItemNames"></a> |
|
742 <h4>ProjectBaseBrowser.getExpandedItemNames</h4> |
|
743 <b>getExpandedItemNames</b>(<i></i>) |
|
744 |
|
745 <p> |
|
746 Public method to get the file/directory names of all expanded items. |
|
747 </p> |
|
748 <dl> |
|
749 <dt>Return:</dt> |
|
750 <dd> |
|
751 list of expanded items names (list of string) |
|
752 </dd> |
|
753 </dl> |
|
754 <a NAME="ProjectBaseBrowser.removeHookMethod" ID="ProjectBaseBrowser.removeHookMethod"></a> |
|
755 <h4>ProjectBaseBrowser.removeHookMethod</h4> |
|
756 <b>removeHookMethod</b>(<i>key</i>) |
|
757 |
|
758 <p> |
|
759 Public method to remove a hook method from the dictionary. |
|
760 </p> |
|
761 <dl> |
|
762 |
|
763 <dt><i>key</i></dt> |
|
764 <dd> |
|
765 for the hook method (string) |
|
766 </dd> |
|
767 </dl> |
|
768 <a NAME="ProjectBaseBrowser.selectFile" ID="ProjectBaseBrowser.selectFile"></a> |
|
769 <h4>ProjectBaseBrowser.selectFile</h4> |
|
770 <b>selectFile</b>(<i>fn</i>) |
|
771 |
|
772 <p> |
|
773 Public method to highlight a node given its filename. |
|
774 </p> |
|
775 <dl> |
|
776 |
|
777 <dt><i>fn</i></dt> |
|
778 <dd> |
|
779 filename of file to be highlighted (string) |
|
780 </dd> |
|
781 </dl> |
|
782 <a NAME="ProjectBaseBrowser.selectFileLine" ID="ProjectBaseBrowser.selectFileLine"></a> |
|
783 <h4>ProjectBaseBrowser.selectFileLine</h4> |
|
784 <b>selectFileLine</b>(<i>fn, lineno</i>) |
|
785 |
|
786 <p> |
|
787 Public method to highlight a node given its filename. |
|
788 </p> |
|
789 <dl> |
|
790 |
|
791 <dt><i>fn</i></dt> |
|
792 <dd> |
|
793 filename of file to be highlighted (string) |
|
794 </dd> |
|
795 <dt><i>lineno</i></dt> |
|
796 <dd> |
|
797 one based line number of the item (integer) |
|
798 </dd> |
|
799 </dl> |
|
800 <a NAME="ProjectBaseBrowser.selectLocalDirEntries" ID="ProjectBaseBrowser.selectLocalDirEntries"></a> |
|
801 <h4>ProjectBaseBrowser.selectLocalDirEntries</h4> |
|
802 <b>selectLocalDirEntries</b>(<i></i>) |
|
803 |
|
804 <p> |
|
805 Public slot to handle the select local directories context menu |
|
806 entries. |
|
807 </p> |
|
808 <a NAME="ProjectBaseBrowser.selectLocalEntries" ID="ProjectBaseBrowser.selectLocalEntries"></a> |
|
809 <h4>ProjectBaseBrowser.selectLocalEntries</h4> |
|
810 <b>selectLocalEntries</b>(<i></i>) |
|
811 |
|
812 <p> |
|
813 Public slot to handle the select local files context menu entries. |
|
814 </p> |
|
815 <a NAME="ProjectBaseBrowser.selectVCSDirEntries" ID="ProjectBaseBrowser.selectVCSDirEntries"></a> |
|
816 <h4>ProjectBaseBrowser.selectVCSDirEntries</h4> |
|
817 <b>selectVCSDirEntries</b>(<i></i>) |
|
818 |
|
819 <p> |
|
820 Public slot to handle the select VCS directories context menu entries. |
|
821 </p> |
|
822 <a NAME="ProjectBaseBrowser.selectVCSEntries" ID="ProjectBaseBrowser.selectVCSEntries"></a> |
|
823 <h4>ProjectBaseBrowser.selectVCSEntries</h4> |
|
824 <b>selectVCSEntries</b>(<i></i>) |
|
825 |
|
826 <p> |
|
827 Public slot to handle the select VCS files context menu entries. |
|
828 </p> |
|
829 <div align="right"><a href="#top">Up</a></div> |
|
830 <hr /> |
|
831 </body></html> |