|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric7.Plugins.VcsPlugins.vcsMercurial.ShelveExtension.HgShelveBrowserDialog</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.Plugins.VcsPlugins.vcsMercurial.ShelveExtension.HgShelveBrowserDialog</h1> |
|
10 |
|
11 <p> |
|
12 Module implementing Mercurial shelve browser dialog. |
|
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="#HgShelveBrowserDialog">HgShelveBrowserDialog</a></td> |
|
25 <td>Class implementing Mercurial shelve browser dialog.</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="HgShelveBrowserDialog" ID="HgShelveBrowserDialog"></a> |
|
36 <h2>HgShelveBrowserDialog</h2> |
|
37 |
|
38 <p> |
|
39 Class implementing Mercurial shelve browser dialog. |
|
40 </p> |
|
41 <h3>Derived from</h3> |
|
42 QWidget, Ui_HgShelveBrowserDialog |
|
43 <h3>Class Attributes</h3> |
|
44 |
|
45 <table> |
|
46 <tr><td>AgeColumn</td></tr><tr><td>MessageColumn</td></tr><tr><td>NameColumn</td></tr> |
|
47 </table> |
|
48 <h3>Class Methods</h3> |
|
49 |
|
50 <table> |
|
51 <tr><td>None</td></tr> |
|
52 </table> |
|
53 <h3>Methods</h3> |
|
54 |
|
55 <table> |
|
56 |
|
57 <tr> |
|
58 <td><a href="#HgShelveBrowserDialog.__init__">HgShelveBrowserDialog</a></td> |
|
59 <td>Constructor</td> |
|
60 </tr> |
|
61 <tr> |
|
62 <td><a href="#HgShelveBrowserDialog.__cleanupShelves">__cleanupShelves</a></td> |
|
63 <td>Private slot to delete all shelves.</td> |
|
64 </tr> |
|
65 <tr> |
|
66 <td><a href="#HgShelveBrowserDialog.__deleteShelves">__deleteShelves</a></td> |
|
67 <td>Private slot to delete the selected shelves.</td> |
|
68 </tr> |
|
69 <tr> |
|
70 <td><a href="#HgShelveBrowserDialog.__finish">__finish</a></td> |
|
71 <td>Private slot called when the process finished or the user pressed the button.</td> |
|
72 </tr> |
|
73 <tr> |
|
74 <td><a href="#HgShelveBrowserDialog.__generateShelveEntry">__generateShelveEntry</a></td> |
|
75 <td>Private method to generate the shelve items.</td> |
|
76 </tr> |
|
77 <tr> |
|
78 <td><a href="#HgShelveBrowserDialog.__getShelveEntries">__getShelveEntries</a></td> |
|
79 <td>Private method to retrieve the list of shelves.</td> |
|
80 </tr> |
|
81 <tr> |
|
82 <td><a href="#HgShelveBrowserDialog.__processBuffer">__processBuffer</a></td> |
|
83 <td>Private method to process the buffered output of the hg shelve command.</td> |
|
84 </tr> |
|
85 <tr> |
|
86 <td><a href="#HgShelveBrowserDialog.__resetUI">__resetUI</a></td> |
|
87 <td>Private method to reset the user interface.</td> |
|
88 </tr> |
|
89 <tr> |
|
90 <td><a href="#HgShelveBrowserDialog.__resizeColumnsShelves">__resizeColumnsShelves</a></td> |
|
91 <td>Private method to resize the shelve list columns.</td> |
|
92 </tr> |
|
93 <tr> |
|
94 <td><a href="#HgShelveBrowserDialog.__showError">__showError</a></td> |
|
95 <td>Private slot to show some error.</td> |
|
96 </tr> |
|
97 <tr> |
|
98 <td><a href="#HgShelveBrowserDialog.__unshelve">__unshelve</a></td> |
|
99 <td>Private slot to restore the selected shelve of changes.</td> |
|
100 </tr> |
|
101 <tr> |
|
102 <td><a href="#HgShelveBrowserDialog.closeEvent">closeEvent</a></td> |
|
103 <td>Protected slot implementing a close event handler.</td> |
|
104 </tr> |
|
105 <tr> |
|
106 <td><a href="#HgShelveBrowserDialog.on_buttonBox_clicked">on_buttonBox_clicked</a></td> |
|
107 <td>Private slot called by a button of the button box clicked.</td> |
|
108 </tr> |
|
109 <tr> |
|
110 <td><a href="#HgShelveBrowserDialog.on_refreshButton_clicked">on_refreshButton_clicked</a></td> |
|
111 <td>Private slot to refresh the list of shelves.</td> |
|
112 </tr> |
|
113 <tr> |
|
114 <td><a href="#HgShelveBrowserDialog.on_shelveList_currentItemChanged">on_shelveList_currentItemChanged</a></td> |
|
115 <td>Private slot called, when the current item of the shelve list changes.</td> |
|
116 </tr> |
|
117 <tr> |
|
118 <td><a href="#HgShelveBrowserDialog.on_shelveList_customContextMenuRequested">on_shelveList_customContextMenuRequested</a></td> |
|
119 <td>Private slot to show the context menu of the shelve list.</td> |
|
120 </tr> |
|
121 <tr> |
|
122 <td><a href="#HgShelveBrowserDialog.show">show</a></td> |
|
123 <td>Public slot to show the dialog.</td> |
|
124 </tr> |
|
125 <tr> |
|
126 <td><a href="#HgShelveBrowserDialog.start">start</a></td> |
|
127 <td>Public slot to start the hg shelve command.</td> |
|
128 </tr> |
|
129 </table> |
|
130 <h3>Static Methods</h3> |
|
131 |
|
132 <table> |
|
133 <tr><td>None</td></tr> |
|
134 </table> |
|
135 |
|
136 <a NAME="HgShelveBrowserDialog.__init__" ID="HgShelveBrowserDialog.__init__"></a> |
|
137 <h4>HgShelveBrowserDialog (Constructor)</h4> |
|
138 <b>HgShelveBrowserDialog</b>(<i>vcs, parent=None</i>) |
|
139 |
|
140 <p> |
|
141 Constructor |
|
142 </p> |
|
143 <dl> |
|
144 |
|
145 <dt><i>vcs</i></dt> |
|
146 <dd> |
|
147 reference to the vcs object |
|
148 </dd> |
|
149 <dt><i>parent</i></dt> |
|
150 <dd> |
|
151 parent widget (QWidget) |
|
152 </dd> |
|
153 </dl> |
|
154 <a NAME="HgShelveBrowserDialog.__cleanupShelves" ID="HgShelveBrowserDialog.__cleanupShelves"></a> |
|
155 <h4>HgShelveBrowserDialog.__cleanupShelves</h4> |
|
156 <b>__cleanupShelves</b>(<i></i>) |
|
157 |
|
158 <p> |
|
159 Private slot to delete all shelves. |
|
160 </p> |
|
161 <a NAME="HgShelveBrowserDialog.__deleteShelves" ID="HgShelveBrowserDialog.__deleteShelves"></a> |
|
162 <h4>HgShelveBrowserDialog.__deleteShelves</h4> |
|
163 <b>__deleteShelves</b>(<i></i>) |
|
164 |
|
165 <p> |
|
166 Private slot to delete the selected shelves. |
|
167 </p> |
|
168 <a NAME="HgShelveBrowserDialog.__finish" ID="HgShelveBrowserDialog.__finish"></a> |
|
169 <h4>HgShelveBrowserDialog.__finish</h4> |
|
170 <b>__finish</b>(<i></i>) |
|
171 |
|
172 <p> |
|
173 Private slot called when the process finished or the user pressed |
|
174 the button. |
|
175 </p> |
|
176 <a NAME="HgShelveBrowserDialog.__generateShelveEntry" ID="HgShelveBrowserDialog.__generateShelveEntry"></a> |
|
177 <h4>HgShelveBrowserDialog.__generateShelveEntry</h4> |
|
178 <b>__generateShelveEntry</b>(<i>name, age, message, fileStatistics, totals</i>) |
|
179 |
|
180 <p> |
|
181 Private method to generate the shelve items. |
|
182 </p> |
|
183 <dl> |
|
184 |
|
185 <dt><i>name</i></dt> |
|
186 <dd> |
|
187 name of the shelve (string) |
|
188 </dd> |
|
189 <dt><i>age</i></dt> |
|
190 <dd> |
|
191 age of the shelve (string) |
|
192 </dd> |
|
193 <dt><i>message</i></dt> |
|
194 <dd> |
|
195 shelve message (string) |
|
196 </dd> |
|
197 <dt><i>fileStatistics</i></dt> |
|
198 <dd> |
|
199 per file change statistics (tuple of |
|
200 four strings with file name, number of changes, number of |
|
201 added lines and number of deleted lines) |
|
202 </dd> |
|
203 <dt><i>totals</i></dt> |
|
204 <dd> |
|
205 overall statistics (tuple of three strings with |
|
206 number of changed files, number of added lines and number |
|
207 of deleted lines) |
|
208 </dd> |
|
209 </dl> |
|
210 <a NAME="HgShelveBrowserDialog.__getShelveEntries" ID="HgShelveBrowserDialog.__getShelveEntries"></a> |
|
211 <h4>HgShelveBrowserDialog.__getShelveEntries</h4> |
|
212 <b>__getShelveEntries</b>(<i></i>) |
|
213 |
|
214 <p> |
|
215 Private method to retrieve the list of shelves. |
|
216 </p> |
|
217 <a NAME="HgShelveBrowserDialog.__processBuffer" ID="HgShelveBrowserDialog.__processBuffer"></a> |
|
218 <h4>HgShelveBrowserDialog.__processBuffer</h4> |
|
219 <b>__processBuffer</b>(<i></i>) |
|
220 |
|
221 <p> |
|
222 Private method to process the buffered output of the hg shelve command. |
|
223 </p> |
|
224 <a NAME="HgShelveBrowserDialog.__resetUI" ID="HgShelveBrowserDialog.__resetUI"></a> |
|
225 <h4>HgShelveBrowserDialog.__resetUI</h4> |
|
226 <b>__resetUI</b>(<i></i>) |
|
227 |
|
228 <p> |
|
229 Private method to reset the user interface. |
|
230 </p> |
|
231 <a NAME="HgShelveBrowserDialog.__resizeColumnsShelves" ID="HgShelveBrowserDialog.__resizeColumnsShelves"></a> |
|
232 <h4>HgShelveBrowserDialog.__resizeColumnsShelves</h4> |
|
233 <b>__resizeColumnsShelves</b>(<i></i>) |
|
234 |
|
235 <p> |
|
236 Private method to resize the shelve list columns. |
|
237 </p> |
|
238 <a NAME="HgShelveBrowserDialog.__showError" ID="HgShelveBrowserDialog.__showError"></a> |
|
239 <h4>HgShelveBrowserDialog.__showError</h4> |
|
240 <b>__showError</b>(<i>out</i>) |
|
241 |
|
242 <p> |
|
243 Private slot to show some error. |
|
244 </p> |
|
245 <dl> |
|
246 |
|
247 <dt><i>out</i></dt> |
|
248 <dd> |
|
249 error to be shown (string) |
|
250 </dd> |
|
251 </dl> |
|
252 <a NAME="HgShelveBrowserDialog.__unshelve" ID="HgShelveBrowserDialog.__unshelve"></a> |
|
253 <h4>HgShelveBrowserDialog.__unshelve</h4> |
|
254 <b>__unshelve</b>(<i></i>) |
|
255 |
|
256 <p> |
|
257 Private slot to restore the selected shelve of changes. |
|
258 </p> |
|
259 <a NAME="HgShelveBrowserDialog.closeEvent" ID="HgShelveBrowserDialog.closeEvent"></a> |
|
260 <h4>HgShelveBrowserDialog.closeEvent</h4> |
|
261 <b>closeEvent</b>(<i>e</i>) |
|
262 |
|
263 <p> |
|
264 Protected slot implementing a close event handler. |
|
265 </p> |
|
266 <dl> |
|
267 |
|
268 <dt><i>e</i></dt> |
|
269 <dd> |
|
270 close event (QCloseEvent) |
|
271 </dd> |
|
272 </dl> |
|
273 <a NAME="HgShelveBrowserDialog.on_buttonBox_clicked" ID="HgShelveBrowserDialog.on_buttonBox_clicked"></a> |
|
274 <h4>HgShelveBrowserDialog.on_buttonBox_clicked</h4> |
|
275 <b>on_buttonBox_clicked</b>(<i>button</i>) |
|
276 |
|
277 <p> |
|
278 Private slot called by a button of the button box clicked. |
|
279 </p> |
|
280 <dl> |
|
281 |
|
282 <dt><i>button</i></dt> |
|
283 <dd> |
|
284 button that was clicked (QAbstractButton) |
|
285 </dd> |
|
286 </dl> |
|
287 <a NAME="HgShelveBrowserDialog.on_refreshButton_clicked" ID="HgShelveBrowserDialog.on_refreshButton_clicked"></a> |
|
288 <h4>HgShelveBrowserDialog.on_refreshButton_clicked</h4> |
|
289 <b>on_refreshButton_clicked</b>(<i></i>) |
|
290 |
|
291 <p> |
|
292 Private slot to refresh the list of shelves. |
|
293 </p> |
|
294 <a NAME="HgShelveBrowserDialog.on_shelveList_currentItemChanged" ID="HgShelveBrowserDialog.on_shelveList_currentItemChanged"></a> |
|
295 <h4>HgShelveBrowserDialog.on_shelveList_currentItemChanged</h4> |
|
296 <b>on_shelveList_currentItemChanged</b>(<i>current, previous</i>) |
|
297 |
|
298 <p> |
|
299 Private slot called, when the current item of the shelve list changes. |
|
300 </p> |
|
301 <dl> |
|
302 |
|
303 <dt><i>current</i></dt> |
|
304 <dd> |
|
305 reference to the new current item (QTreeWidgetItem) |
|
306 </dd> |
|
307 <dt><i>previous</i></dt> |
|
308 <dd> |
|
309 reference to the old current item (QTreeWidgetItem) |
|
310 </dd> |
|
311 </dl> |
|
312 <a NAME="HgShelveBrowserDialog.on_shelveList_customContextMenuRequested" ID="HgShelveBrowserDialog.on_shelveList_customContextMenuRequested"></a> |
|
313 <h4>HgShelveBrowserDialog.on_shelveList_customContextMenuRequested</h4> |
|
314 <b>on_shelveList_customContextMenuRequested</b>(<i>pos</i>) |
|
315 |
|
316 <p> |
|
317 Private slot to show the context menu of the shelve list. |
|
318 </p> |
|
319 <dl> |
|
320 |
|
321 <dt><i>pos</i></dt> |
|
322 <dd> |
|
323 position of the mouse pointer (QPoint) |
|
324 </dd> |
|
325 </dl> |
|
326 <a NAME="HgShelveBrowserDialog.show" ID="HgShelveBrowserDialog.show"></a> |
|
327 <h4>HgShelveBrowserDialog.show</h4> |
|
328 <b>show</b>(<i></i>) |
|
329 |
|
330 <p> |
|
331 Public slot to show the dialog. |
|
332 </p> |
|
333 <a NAME="HgShelveBrowserDialog.start" ID="HgShelveBrowserDialog.start"></a> |
|
334 <h4>HgShelveBrowserDialog.start</h4> |
|
335 <b>start</b>(<i></i>) |
|
336 |
|
337 <p> |
|
338 Public slot to start the hg shelve command. |
|
339 </p> |
|
340 <div align="right"><a href="#top">Up</a></div> |
|
341 <hr /> |
|
342 </body></html> |