@@ -23,41 +23,59 | |||
|
23 | 23 | QMainWindow.__init__(self, parent) |
|
24 | 24 | self.setupUi(self) |
|
25 | 25 | self.setupUi2() |
|
26 | ||
|
27 | #redirige salida estandar | |
|
26 | 28 | sys.stdout = self |
|
27 | 29 | |
|
28 | 30 | |
|
29 | 31 | def setupUi2(self): |
|
32 | """ | |
|
33 | Se usa para inicializar ciertos parametros para pruebas | |
|
34 | """ | |
|
30 | 35 | self.txtDpath.setText('/home/ricardoar/optional/STORAGE/EW_DRIFTS') |
|
31 | 36 | self.txtRpath.setText('/home/ricardoar/optional/STORAGE/prueba1_jro_backup_manager') |
|
32 | 37 | self.txtElabel.setText('EW_DRIFTS') |
|
38 | self.statusDpath = False | |
|
39 | self.statusRpath = False | |
|
33 | 40 | |
|
34 | 41 | def write(self, txt): |
|
42 | """ | |
|
43 | Escribe la salida estandar eb txtInfo | |
|
44 | """ | |
|
35 | 45 | self.txtInfo.append(str(txt)) |
|
36 | 46 | |
|
37 | 47 | |
|
38 | 48 | @pyqtSignature("") |
|
39 | 49 | def on_btnDpath_clicked(self): |
|
40 | 50 | """ |
|
41 | Slot documentation goes here. | |
|
51 | Permite seleccionar graficamente el direcorio de los datos a grabar | |
|
42 | 52 | """ |
|
43 | 53 | var_Dpath= QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly) |
|
44 | 54 | self.txtDpath.setText(var_Dpath) |
|
55 | ||
|
56 | #llamada a funcion | |
|
45 | 57 | self.on_txtDpath_editingFinished() |
|
46 | 58 | |
|
47 | 59 | |
|
48 | 60 | @pyqtSignature("") |
|
49 | 61 | def on_btnRpath_clicked(self): |
|
50 | 62 | """ |
|
51 | Slot documentation goes here. | |
|
63 | Permite seleccionar graficamente el direcorio del proyecto | |
|
52 | 64 | """ |
|
53 | 65 | var_Rpath = QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly) |
|
54 | 66 | self.txtRpath.setText(var_Rpath) |
|
67 | ||
|
68 | #llamada a funcion | |
|
55 | 69 | self.on_txtRpath_editingFinished() |
|
56 | 70 | |
|
57 | 71 | |
|
58 | 72 | @pyqtSignature("") |
|
59 | 73 | def on_txtDpath_editingFinished(self): |
|
60 | ||
|
74 | """ | |
|
75 | Permite buscar los archivos de extension seleccionada en la ruta de de datos | |
|
76 | y cargar los valores para el rango de tiempo a ser grabado | |
|
77 | """ | |
|
78 | ||
|
61 | 79 | #Usando el modulo "subprocess", eric4 pide seleccion del tipo de subproceso (padre o hijo) |
|
62 | 80 | #por ello se prefiere usar el modulo "commands" |
|
63 | 81 | #p1= Popen(['find', var_Dpath, '-name', '*.r'], stdout=PIPE) |
@@ -65,56 +83,58 | |||
|
65 | 83 | #output_p2= p2.communicate()[0] |
|
66 | 84 | #self.txtInfo.setText(output_p2) |
|
67 | 85 | |
|
86 | #Se carga la variable con la ruta de datos | |
|
68 | 87 | var_Dpath=self.txtDpath.text() |
|
69 | 88 | |
|
70 | 89 | #Se verifica que la ruta exista y sea un directorio |
|
71 | 90 | var_cmd="test -d "+str(var_Dpath) |
|
72 | 91 | var_output=commands.getstatusoutput(var_cmd)[0] |
|
73 | 92 | if var_output != 0: |
|
93 | self.statusDpath = False | |
|
74 | 94 | self.txtInfo.setText("Ruta no valida, output_error:" + str(var_output)) |
|
75 | 95 | return |
|
96 | else: | |
|
97 | self.statusDpath = True | |
|
98 | self.txtInfo.append("Ruta valida, sin error:" + str(var_Dpath)) | |
|
76 | 99 | |
|
77 | 100 | #Se buscan los archivos del tipo especificado |
|
78 | 101 | var_Dtype=self.txtDtype.text() |
|
79 | 102 | var_cmd="find " + str(var_Dpath) + " -name *."+ str(var_Dtype) +" | awk -F/ '{print substr($NF,2,7)}' | sort| uniq" |
|
80 | 103 | output_p2=commands.getstatusoutput(var_cmd)[1] |
|
81 | 104 | |
|
82 | #INFO: Muestra los dias que se encontraron | |
|
83 | #self.txtInfo.append(output_p2) | |
|
84 | ||
|
85 | #Se cargan las listas para seleccionar StartDay y StopDay | |
|
105 | #Se cargan las listas para seleccionar StartDay y StopDay (QComboBox) | |
|
86 | 106 | self.var_list=[] |
|
87 | 107 | for i in range(0, (len(output_p2)+1)/8): |
|
88 | 108 | self.var_list.append(output_p2[8*i:8*(i+1)-1]) |
|
89 | 109 | |
|
90 | 110 | self.lstStartDay.clear() |
|
91 | 111 | self.lstStopDay.clear() |
|
92 |
|
|
|
112 | ||
|
93 | 113 | for i in self.var_list: |
|
94 | 114 | self.lstStartDay.addItem(i) |
|
95 | 115 | self.lstStopDay.addItem(i) |
|
96 | 116 | |
|
97 | 117 | self.lstStopDay.setCurrentIndex(self.lstStartDay.count()-1) |
|
98 | ||
|
99 | #INFO: Muestra cuantos dias se encontraron | |
|
100 | #self.txtInfo.setText(str(self.lstStartDay.count())) | |
|
101 | ||
|
102 | ||
|
118 | ||
|
119 | ||
|
103 | 120 | @pyqtSignature("") |
|
104 | 121 | def on_txtRpath_editingFinished(self): |
|
105 | 122 | """ |
|
106 | Slot documentation goes here. | |
|
107 | """ | |
|
123 | Valida la ruta del proyecto | |
|
124 | """ | |
|
125 | #Se carga la variable con la ruta del proyecto | |
|
108 | 126 | var_Rpath=self.txtRpath.text() |
|
109 | 127 | |
|
110 | 128 | #Se verifica que la ruta exista y sea un directorio |
|
111 | 129 | var_cmd="test -d "+str(var_Rpath) |
|
112 | 130 | var_output=commands.getstatusoutput(var_cmd)[0] |
|
113 | 131 | if var_output != 0: |
|
132 | self.statusRpath = False | |
|
114 | 133 | self.txtInfo.append("Ruta no valida, output_error:" + str(var_output)) |
|
115 | 134 | return |
|
116 | 135 | else: |
|
117 | self.txtInfo.append("Ruta valida, sin error") | |
|
136 | self.statusRpath = True | |
|
137 | self.txtInfo.append("Ruta valida, sin error:" + str(var_Rpath)) | |
|
118 | 138 | |
|
119 | 139 | |
|
120 | 140 | @pyqtSignature("int") |
@@ -143,6 +163,7 | |||
|
143 | 163 | """ |
|
144 | 164 | Se activa cuando el tipo de archivo es ingresado manualmente |
|
145 | 165 | """ |
|
166 | #llamada a funcion | |
|
146 | 167 | self.on_txtDpath_editingFinished() |
|
147 | 168 | |
|
148 | 169 | |
@@ -203,25 +224,36 | |||
|
203 | 224 | Cuando se presiona el boton Generate Bkp |
|
204 | 225 | """ |
|
205 | 226 | |
|
206 | #CREA LAS CARPETAS "COMENTADO TEMPORALMENTE" | |
|
227 | #Verifica que las rutas sean validas | |
|
228 | if self.statusDpath == False or self.statusRpath == False: | |
|
229 | if self.statusDpath == False: | |
|
230 | self.txtInfo.append("Ruta de datos no valida") | |
|
231 | if self.statusRpath == False: | |
|
232 | self.txtInfo.append("Ruta de proyecto no valida") | |
|
233 | return | |
|
234 | ||
|
235 | #Crea las carpetas en la ruta del proyecto y verifica que se crearon correctamente | |
|
236 | ||
|
237 | var_Rpath=self.txtRpath.text() | |
|
207 | 238 | var_dirs='/{gpath,iso,ppath}' |
|
208 | var_Rpath=self.txtRpath.text() | |
|
209 | var_cmd="mkdir "+str(var_Rpath)+str(var_dirs) | |
|
239 | var_cmd="mkdir -p "+str(var_Rpath)+str(var_dirs) | |
|
240 | ||
|
210 | 241 | self.txtInfo.append(var_cmd) |
|
211 | #var_output=commands.getstatusoutput(var_cmd)[0] | |
|
212 | #if var_output != 0: | |
|
213 | # self.txtInfo.setText("No se pudieron crear los directorios, output_error:" + str(var_output)) | |
|
214 | # return | |
|
215 | #else: | |
|
216 | # self.txtInfo.append('Carpetas creadas correctamente') | |
|
217 | ||
|
242 | ||
|
243 | var_output=commands.getstatusoutput(var_cmd)[0] | |
|
244 | if var_output != 0: | |
|
245 | self.txtInfo.append("No se pudieron crear los directorios, output_error:" + str(var_output)) | |
|
246 | return | |
|
247 | else: | |
|
248 | self.txtInfo.append('Carpetas creadas correctamente') | |
|
249 | ||
|
218 | 250 | |
|
219 | 251 | var_sublist=[] |
|
220 | 252 | for i in self.var_list[self.lstStartDay.currentIndex():self.lstStartDay.currentIndex() + self.lstStopDay.currentIndex()+1]: |
|
221 | 253 | self.txtInfo.append(i) |
|
222 | 254 | var_sublist.append(i) |
|
223 | 255 | |
|
224 | #Cargando los parametros de busqueda | |
|
256 | #Cargando variables con los parametros de busqueda | |
|
225 | 257 | var_Dpath=self.txtDpath.text() |
|
226 | 258 | var_Dtype=self.txtDtype.text() |
|
227 | 259 | |
@@ -337,3 +369,4 | |||
|
337 | 369 | """ |
|
338 | 370 | self.tabParameters.setEnabled(True) |
|
339 | 371 | self.btnGbkp.setEnabled(True) |
|
372 |
@@ -7,7 +7,7 | |||
|
7 | 7 | <x>0</x> |
|
8 | 8 | <y>0</y> |
|
9 | 9 | <width>745</width> |
|
10 |
<height>7 |
|
|
10 | <height>766</height> | |
|
11 | 11 | </rect> |
|
12 | 12 | </property> |
|
13 | 13 | <property name="windowTitle"> |
@@ -221,27 +221,32 | |||
|
221 | 221 | <property name="text"> |
|
222 | 222 | <string>Dev A</string> |
|
223 | 223 | </property> |
|
224 | </widget> | |
|
225 | </item> | |
|
226 |
|
|
|
227 | <layout class="QVBoxLayout" name="verticalLayout_11"> | |
|
228 |
|
|
|
229 | <widget class="QLineEdit" name="txtDeviceA"/> | |
|
230 | </item> | |
|
231 | <item> | |
|
232 | <widget class="QLineEdit" name="txtBspeedA"/> | |
|
233 | </item> | |
|
234 | <item> | |
|
235 | <widget class="QLineEdit" name="txtBmodeA"/> | |
|
236 | </item> | |
|
237 | <item> | |
|
238 | <widget class="QPushButton" name="btnTdevA"> | |
|
239 |
< |
|
|
240 | <string>Test DevA</string> | |
|
241 |
|
|
|
242 | </widget> | |
|
243 |
|
|
|
244 | </layout> | |
|
224 | <property name="checked"> | |
|
225 | <bool>true</bool> | |
|
226 | </property> | |
|
227 | </widget> | |
|
228 | </item> | |
|
229 | <item> | |
|
230 | <widget class="QWidget" name="grpDevA" native="true"> | |
|
231 | <layout class="QVBoxLayout" name="verticalLayout_11"> | |
|
232 | <item> | |
|
233 | <widget class="QLineEdit" name="txtDeviceA"/> | |
|
234 | </item> | |
|
235 | <item> | |
|
236 | <widget class="QLineEdit" name="txtBspeedA"/> | |
|
237 | </item> | |
|
238 | <item> | |
|
239 | <widget class="QLineEdit" name="txtBmodeA"/> | |
|
240 | </item> | |
|
241 | <item> | |
|
242 | <widget class="QPushButton" name="btnTdevA"> | |
|
243 | <property name="text"> | |
|
244 | <string>Test DevA</string> | |
|
245 | </property> | |
|
246 | </widget> | |
|
247 | </item> | |
|
248 | </layout> | |
|
249 | </widget> | |
|
245 | 250 | </item> |
|
246 | 251 | </layout> |
|
247 | 252 | </item> |
@@ -252,27 +257,32 | |||
|
252 | 257 | <property name="text"> |
|
253 | 258 | <string>Dev B</string> |
|
254 | 259 | </property> |
|
255 | </widget> | |
|
256 | </item> | |
|
257 |
|
|
|
258 | <layout class="QVBoxLayout" name="verticalLayout_12"> | |
|
259 |
|
|
|
260 | <widget class="QLineEdit" name="txtDeviceB"/> | |
|
261 | </item> | |
|
262 | <item> | |
|
263 | <widget class="QLineEdit" name="txtBspeedB"/> | |
|
264 | </item> | |
|
265 | <item> | |
|
266 | <widget class="QLineEdit" name="txtBmodeB"/> | |
|
267 | </item> | |
|
268 | <item> | |
|
269 | <widget class="QPushButton" name="btnTdevB"> | |
|
270 |
< |
|
|
271 | <string>Test DevB</string> | |
|
272 |
|
|
|
273 | </widget> | |
|
274 |
|
|
|
275 | </layout> | |
|
260 | <property name="checked"> | |
|
261 | <bool>true</bool> | |
|
262 | </property> | |
|
263 | </widget> | |
|
264 | </item> | |
|
265 | <item> | |
|
266 | <widget class="QWidget" name="grpDevB" native="true"> | |
|
267 | <layout class="QVBoxLayout" name="verticalLayout_12"> | |
|
268 | <item> | |
|
269 | <widget class="QLineEdit" name="txtDeviceB"/> | |
|
270 | </item> | |
|
271 | <item> | |
|
272 | <widget class="QLineEdit" name="txtBspeedB"/> | |
|
273 | </item> | |
|
274 | <item> | |
|
275 | <widget class="QLineEdit" name="txtBmodeB"/> | |
|
276 | </item> | |
|
277 | <item> | |
|
278 | <widget class="QPushButton" name="btnTdevB"> | |
|
279 | <property name="text"> | |
|
280 | <string>Test DevB</string> | |
|
281 | </property> | |
|
282 | </widget> | |
|
283 | </item> | |
|
284 | </layout> | |
|
285 | </widget> | |
|
276 | 286 | </item> |
|
277 | 287 | </layout> |
|
278 | 288 | </item> |
@@ -283,27 +293,32 | |||
|
283 | 293 | <property name="text"> |
|
284 | 294 | <string>Dev C</string> |
|
285 | 295 | </property> |
|
286 | </widget> | |
|
287 | </item> | |
|
288 |
|
|
|
289 | <layout class="QVBoxLayout" name="verticalLayout_13"> | |
|
290 |
|
|
|
291 | <widget class="QLineEdit" name="txtDeviceC"/> | |
|
292 | </item> | |
|
293 | <item> | |
|
294 | <widget class="QLineEdit" name="txtBspeedC"/> | |
|
295 | </item> | |
|
296 | <item> | |
|
297 | <widget class="QLineEdit" name="txtBmodeC"/> | |
|
298 | </item> | |
|
299 | <item> | |
|
300 | <widget class="QPushButton" name="btnTdevC"> | |
|
301 |
< |
|
|
302 | <string>Test DevC</string> | |
|
303 |
|
|
|
304 | </widget> | |
|
305 |
|
|
|
306 | </layout> | |
|
296 | <property name="checked"> | |
|
297 | <bool>true</bool> | |
|
298 | </property> | |
|
299 | </widget> | |
|
300 | </item> | |
|
301 | <item> | |
|
302 | <widget class="QWidget" name="grpDevC" native="true"> | |
|
303 | <layout class="QVBoxLayout" name="verticalLayout_13"> | |
|
304 | <item> | |
|
305 | <widget class="QLineEdit" name="txtDeviceC"/> | |
|
306 | </item> | |
|
307 | <item> | |
|
308 | <widget class="QLineEdit" name="txtBspeedC"/> | |
|
309 | </item> | |
|
310 | <item> | |
|
311 | <widget class="QLineEdit" name="txtBmodeC"/> | |
|
312 | </item> | |
|
313 | <item> | |
|
314 | <widget class="QPushButton" name="btnTdevC"> | |
|
315 | <property name="text"> | |
|
316 | <string>Test DevC</string> | |
|
317 | </property> | |
|
318 | </widget> | |
|
319 | </item> | |
|
320 | </layout> | |
|
321 | </widget> | |
|
307 | 322 | </item> |
|
308 | 323 | </layout> |
|
309 | 324 | </item> |
@@ -314,27 +329,32 | |||
|
314 | 329 | <property name="text"> |
|
315 | 330 | <string>Dev D</string> |
|
316 | 331 | </property> |
|
317 | </widget> | |
|
318 | </item> | |
|
319 |
|
|
|
320 | <layout class="QVBoxLayout" name="verticalLayout_14"> | |
|
321 |
|
|
|
322 | <widget class="QLineEdit" name="txtDeviceD"/> | |
|
323 | </item> | |
|
324 | <item> | |
|
325 | <widget class="QLineEdit" name="txtBspeedD"/> | |
|
326 | </item> | |
|
327 | <item> | |
|
328 | <widget class="QLineEdit" name="txtBmodeD"/> | |
|
329 | </item> | |
|
330 | <item> | |
|
331 | <widget class="QPushButton" name="btnTdevD"> | |
|
332 |
< |
|
|
333 | <string>Test DevD</string> | |
|
334 |
|
|
|
335 | </widget> | |
|
336 |
|
|
|
337 | </layout> | |
|
332 | <property name="checked"> | |
|
333 | <bool>true</bool> | |
|
334 | </property> | |
|
335 | </widget> | |
|
336 | </item> | |
|
337 | <item> | |
|
338 | <widget class="QWidget" name="grpDevD" native="true"> | |
|
339 | <layout class="QVBoxLayout" name="verticalLayout_14"> | |
|
340 | <item> | |
|
341 | <widget class="QLineEdit" name="txtDeviceD"/> | |
|
342 | </item> | |
|
343 | <item> | |
|
344 | <widget class="QLineEdit" name="txtBspeedD"/> | |
|
345 | </item> | |
|
346 | <item> | |
|
347 | <widget class="QLineEdit" name="txtBmodeD"/> | |
|
348 | </item> | |
|
349 | <item> | |
|
350 | <widget class="QPushButton" name="btnTdevD"> | |
|
351 | <property name="text"> | |
|
352 | <string>Test DevD</string> | |
|
353 | </property> | |
|
354 | </widget> | |
|
355 | </item> | |
|
356 | </layout> | |
|
357 | </widget> | |
|
338 | 358 | </item> |
|
339 | 359 | </layout> |
|
340 | 360 | </item> |
@@ -797,8 +817,8 | |||
|
797 | 817 | <slot>toggle()</slot> |
|
798 | 818 | <hints> |
|
799 | 819 | <hint type="sourcelabel"> |
|
800 |
<x> |
|
|
801 |
<y>27 |
|
|
820 | <x>635</x> | |
|
821 | <y>276</y> | |
|
802 | 822 | </hint> |
|
803 | 823 | <hint type="destinationlabel"> |
|
804 | 824 | <x>350</x> |
@@ -813,12 +833,76 | |||
|
813 | 833 | <slot>toggle()</slot> |
|
814 | 834 | <hints> |
|
815 | 835 | <hint type="sourcelabel"> |
|
816 |
<x> |
|
|
817 |
<y>2 |
|
|
836 | <x>433</x> | |
|
837 | <y>276</y> | |
|
818 | 838 | </hint> |
|
819 | 839 | <hint type="destinationlabel"> |
|
820 |
<x> |
|
|
821 |
<y>27 |
|
|
840 | <x>635</x> | |
|
841 | <y>276</y> | |
|
842 | </hint> | |
|
843 | </hints> | |
|
844 | </connection> | |
|
845 | <connection> | |
|
846 | <sender>chkDevA</sender> | |
|
847 | <signal>toggled(bool)</signal> | |
|
848 | <receiver>grpDevA</receiver> | |
|
849 | <slot>setEnabled(bool)</slot> | |
|
850 | <hints> | |
|
851 | <hint type="sourcelabel"> | |
|
852 | <x>95</x> | |
|
853 | <y>86</y> | |
|
854 | </hint> | |
|
855 | <hint type="destinationlabel"> | |
|
856 | <x>95</x> | |
|
857 | <y>167</y> | |
|
858 | </hint> | |
|
859 | </hints> | |
|
860 | </connection> | |
|
861 | <connection> | |
|
862 | <sender>chkDevB</sender> | |
|
863 | <signal>toggled(bool)</signal> | |
|
864 | <receiver>grpDevB</receiver> | |
|
865 | <slot>setEnabled(bool)</slot> | |
|
866 | <hints> | |
|
867 | <hint type="sourcelabel"> | |
|
868 | <x>251</x> | |
|
869 | <y>86</y> | |
|
870 | </hint> | |
|
871 | <hint type="destinationlabel"> | |
|
872 | <x>251</x> | |
|
873 | <y>167</y> | |
|
874 | </hint> | |
|
875 | </hints> | |
|
876 | </connection> | |
|
877 | <connection> | |
|
878 | <sender>chkDevC</sender> | |
|
879 | <signal>toggled(bool)</signal> | |
|
880 | <receiver>grpDevC</receiver> | |
|
881 | <slot>setEnabled(bool)</slot> | |
|
882 | <hints> | |
|
883 | <hint type="sourcelabel"> | |
|
884 | <x>407</x> | |
|
885 | <y>86</y> | |
|
886 | </hint> | |
|
887 | <hint type="destinationlabel"> | |
|
888 | <x>407</x> | |
|
889 | <y>167</y> | |
|
890 | </hint> | |
|
891 | </hints> | |
|
892 | </connection> | |
|
893 | <connection> | |
|
894 | <sender>chkDevD</sender> | |
|
895 | <signal>toggled(bool)</signal> | |
|
896 | <receiver>grpDevD</receiver> | |
|
897 | <slot>setEnabled(bool)</slot> | |
|
898 | <hints> | |
|
899 | <hint type="sourcelabel"> | |
|
900 | <x>563</x> | |
|
901 | <y>86</y> | |
|
902 | </hint> | |
|
903 | <hint type="destinationlabel"> | |
|
904 | <x>563</x> | |
|
905 | <y>167</y> | |
|
822 | 906 | </hint> |
|
823 | 907 | </hints> |
|
824 | 908 | </connection> |
@@ -2,7 +2,7 | |||
|
2 | 2 | |
|
3 | 3 | # Form implementation generated from reading ui file '/home/ricardoar/principal/JRO_SVN/eric4/jro_backup_manager/ui/MainWindow.ui' |
|
4 | 4 | # |
|
5 |
# Created: T |
|
|
5 | # Created: Tue May 4 12:02:35 2010 | |
|
6 | 6 | # by: PyQt4 UI code generator 4.7.3 |
|
7 | 7 | # |
|
8 | 8 | # WARNING! All changes made in this file will be lost! |
@@ -12,7 +12,7 | |||
|
12 | 12 | class Ui_MainWindow(object): |
|
13 | 13 | def setupUi(self, MainWindow): |
|
14 | 14 | MainWindow.setObjectName("MainWindow") |
|
15 |
MainWindow.resize(745, 7 |
|
|
15 | MainWindow.resize(745, 766) | |
|
16 | 16 | self.centralwidget = QtGui.QWidget(MainWindow) |
|
17 | 17 | self.centralwidget.setObjectName("centralwidget") |
|
18 | 18 | self.verticalLayout = QtGui.QVBoxLayout(self.centralwidget) |
@@ -132,86 +132,98 | |||
|
132 | 132 | self.verticalLayout_15 = QtGui.QVBoxLayout() |
|
133 | 133 | self.verticalLayout_15.setObjectName("verticalLayout_15") |
|
134 | 134 | self.chkDevA = QtGui.QCheckBox(self.tabDconfig) |
|
135 | self.chkDevA.setChecked(True) | |
|
135 | 136 | self.chkDevA.setObjectName("chkDevA") |
|
136 | 137 | self.verticalLayout_15.addWidget(self.chkDevA) |
|
137 | self.verticalLayout_11 = QtGui.QVBoxLayout() | |
|
138 | self.grpDevA = QtGui.QWidget(self.tabDconfig) | |
|
139 | self.grpDevA.setObjectName("grpDevA") | |
|
140 | self.verticalLayout_11 = QtGui.QVBoxLayout(self.grpDevA) | |
|
138 | 141 | self.verticalLayout_11.setObjectName("verticalLayout_11") |
|
139 |
self.txtDeviceA = QtGui.QLineEdit(self. |
|
|
142 | self.txtDeviceA = QtGui.QLineEdit(self.grpDevA) | |
|
140 | 143 | self.txtDeviceA.setObjectName("txtDeviceA") |
|
141 | 144 | self.verticalLayout_11.addWidget(self.txtDeviceA) |
|
142 |
self.txtBspeedA = QtGui.QLineEdit(self. |
|
|
145 | self.txtBspeedA = QtGui.QLineEdit(self.grpDevA) | |
|
143 | 146 | self.txtBspeedA.setObjectName("txtBspeedA") |
|
144 | 147 | self.verticalLayout_11.addWidget(self.txtBspeedA) |
|
145 |
self.txtBmodeA = QtGui.QLineEdit(self. |
|
|
148 | self.txtBmodeA = QtGui.QLineEdit(self.grpDevA) | |
|
146 | 149 | self.txtBmodeA.setObjectName("txtBmodeA") |
|
147 | 150 | self.verticalLayout_11.addWidget(self.txtBmodeA) |
|
148 |
self.btnTdevA = QtGui.QPushButton(self. |
|
|
151 | self.btnTdevA = QtGui.QPushButton(self.grpDevA) | |
|
149 | 152 | self.btnTdevA.setObjectName("btnTdevA") |
|
150 | 153 | self.verticalLayout_11.addWidget(self.btnTdevA) |
|
151 |
self.verticalLayout_15.add |
|
|
154 | self.verticalLayout_15.addWidget(self.grpDevA) | |
|
152 | 155 | self.gridLayout.addLayout(self.verticalLayout_15, 0, 0, 1, 1) |
|
153 | 156 | self.verticalLayout_16 = QtGui.QVBoxLayout() |
|
154 | 157 | self.verticalLayout_16.setObjectName("verticalLayout_16") |
|
155 | 158 | self.chkDevB = QtGui.QCheckBox(self.tabDconfig) |
|
159 | self.chkDevB.setChecked(True) | |
|
156 | 160 | self.chkDevB.setObjectName("chkDevB") |
|
157 | 161 | self.verticalLayout_16.addWidget(self.chkDevB) |
|
158 | self.verticalLayout_12 = QtGui.QVBoxLayout() | |
|
162 | self.grpDevB = QtGui.QWidget(self.tabDconfig) | |
|
163 | self.grpDevB.setObjectName("grpDevB") | |
|
164 | self.verticalLayout_12 = QtGui.QVBoxLayout(self.grpDevB) | |
|
159 | 165 | self.verticalLayout_12.setObjectName("verticalLayout_12") |
|
160 |
self.txtDeviceB = QtGui.QLineEdit(self. |
|
|
166 | self.txtDeviceB = QtGui.QLineEdit(self.grpDevB) | |
|
161 | 167 | self.txtDeviceB.setObjectName("txtDeviceB") |
|
162 | 168 | self.verticalLayout_12.addWidget(self.txtDeviceB) |
|
163 |
self.txtBspeedB = QtGui.QLineEdit(self. |
|
|
169 | self.txtBspeedB = QtGui.QLineEdit(self.grpDevB) | |
|
164 | 170 | self.txtBspeedB.setObjectName("txtBspeedB") |
|
165 | 171 | self.verticalLayout_12.addWidget(self.txtBspeedB) |
|
166 |
self.txtBmodeB = QtGui.QLineEdit(self. |
|
|
172 | self.txtBmodeB = QtGui.QLineEdit(self.grpDevB) | |
|
167 | 173 | self.txtBmodeB.setObjectName("txtBmodeB") |
|
168 | 174 | self.verticalLayout_12.addWidget(self.txtBmodeB) |
|
169 |
self.btnTdevB = QtGui.QPushButton(self. |
|
|
175 | self.btnTdevB = QtGui.QPushButton(self.grpDevB) | |
|
170 | 176 | self.btnTdevB.setObjectName("btnTdevB") |
|
171 | 177 | self.verticalLayout_12.addWidget(self.btnTdevB) |
|
172 |
self.verticalLayout_16.add |
|
|
178 | self.verticalLayout_16.addWidget(self.grpDevB) | |
|
173 | 179 | self.gridLayout.addLayout(self.verticalLayout_16, 0, 1, 1, 1) |
|
174 | 180 | self.verticalLayout_17 = QtGui.QVBoxLayout() |
|
175 | 181 | self.verticalLayout_17.setObjectName("verticalLayout_17") |
|
176 | 182 | self.chkDevC = QtGui.QCheckBox(self.tabDconfig) |
|
183 | self.chkDevC.setChecked(True) | |
|
177 | 184 | self.chkDevC.setObjectName("chkDevC") |
|
178 | 185 | self.verticalLayout_17.addWidget(self.chkDevC) |
|
179 | self.verticalLayout_13 = QtGui.QVBoxLayout() | |
|
186 | self.grpDevC = QtGui.QWidget(self.tabDconfig) | |
|
187 | self.grpDevC.setObjectName("grpDevC") | |
|
188 | self.verticalLayout_13 = QtGui.QVBoxLayout(self.grpDevC) | |
|
180 | 189 | self.verticalLayout_13.setObjectName("verticalLayout_13") |
|
181 |
self.txtDeviceC = QtGui.QLineEdit(self. |
|
|
190 | self.txtDeviceC = QtGui.QLineEdit(self.grpDevC) | |
|
182 | 191 | self.txtDeviceC.setObjectName("txtDeviceC") |
|
183 | 192 | self.verticalLayout_13.addWidget(self.txtDeviceC) |
|
184 |
self.txtBspeedC = QtGui.QLineEdit(self. |
|
|
193 | self.txtBspeedC = QtGui.QLineEdit(self.grpDevC) | |
|
185 | 194 | self.txtBspeedC.setObjectName("txtBspeedC") |
|
186 | 195 | self.verticalLayout_13.addWidget(self.txtBspeedC) |
|
187 |
self.txtBmodeC = QtGui.QLineEdit(self. |
|
|
196 | self.txtBmodeC = QtGui.QLineEdit(self.grpDevC) | |
|
188 | 197 | self.txtBmodeC.setObjectName("txtBmodeC") |
|
189 | 198 | self.verticalLayout_13.addWidget(self.txtBmodeC) |
|
190 |
self.btnTdevC = QtGui.QPushButton(self. |
|
|
199 | self.btnTdevC = QtGui.QPushButton(self.grpDevC) | |
|
191 | 200 | self.btnTdevC.setObjectName("btnTdevC") |
|
192 | 201 | self.verticalLayout_13.addWidget(self.btnTdevC) |
|
193 |
self.verticalLayout_17.add |
|
|
202 | self.verticalLayout_17.addWidget(self.grpDevC) | |
|
194 | 203 | self.gridLayout.addLayout(self.verticalLayout_17, 0, 2, 1, 1) |
|
195 | 204 | self.verticalLayout_18 = QtGui.QVBoxLayout() |
|
196 | 205 | self.verticalLayout_18.setObjectName("verticalLayout_18") |
|
197 | 206 | self.chkDevD = QtGui.QCheckBox(self.tabDconfig) |
|
207 | self.chkDevD.setChecked(True) | |
|
198 | 208 | self.chkDevD.setObjectName("chkDevD") |
|
199 | 209 | self.verticalLayout_18.addWidget(self.chkDevD) |
|
200 | self.verticalLayout_14 = QtGui.QVBoxLayout() | |
|
210 | self.grpDevD = QtGui.QWidget(self.tabDconfig) | |
|
211 | self.grpDevD.setObjectName("grpDevD") | |
|
212 | self.verticalLayout_14 = QtGui.QVBoxLayout(self.grpDevD) | |
|
201 | 213 | self.verticalLayout_14.setObjectName("verticalLayout_14") |
|
202 |
self.txtDeviceD = QtGui.QLineEdit(self. |
|
|
214 | self.txtDeviceD = QtGui.QLineEdit(self.grpDevD) | |
|
203 | 215 | self.txtDeviceD.setObjectName("txtDeviceD") |
|
204 | 216 | self.verticalLayout_14.addWidget(self.txtDeviceD) |
|
205 |
self.txtBspeedD = QtGui.QLineEdit(self. |
|
|
217 | self.txtBspeedD = QtGui.QLineEdit(self.grpDevD) | |
|
206 | 218 | self.txtBspeedD.setObjectName("txtBspeedD") |
|
207 | 219 | self.verticalLayout_14.addWidget(self.txtBspeedD) |
|
208 |
self.txtBmodeD = QtGui.QLineEdit(self. |
|
|
220 | self.txtBmodeD = QtGui.QLineEdit(self.grpDevD) | |
|
209 | 221 | self.txtBmodeD.setObjectName("txtBmodeD") |
|
210 | 222 | self.verticalLayout_14.addWidget(self.txtBmodeD) |
|
211 |
self.btnTdevD = QtGui.QPushButton(self. |
|
|
223 | self.btnTdevD = QtGui.QPushButton(self.grpDevD) | |
|
212 | 224 | self.btnTdevD.setObjectName("btnTdevD") |
|
213 | 225 | self.verticalLayout_14.addWidget(self.btnTdevD) |
|
214 |
self.verticalLayout_18.add |
|
|
226 | self.verticalLayout_18.addWidget(self.grpDevD) | |
|
215 | 227 | self.gridLayout.addLayout(self.verticalLayout_18, 0, 3, 1, 1) |
|
216 | 228 | self.verticalLayout_19 = QtGui.QVBoxLayout() |
|
217 | 229 | self.verticalLayout_19.setObjectName("verticalLayout_19") |
@@ -443,6 +455,10 | |||
|
443 | 455 | self.lstDcapacity.setCurrentIndex(2) |
|
444 | 456 | QtCore.QObject.connect(self.chkSequentially, QtCore.SIGNAL("clicked()"), self.chkSimultaneously.toggle) |
|
445 | 457 | QtCore.QObject.connect(self.chkSimultaneously, QtCore.SIGNAL("clicked()"), self.chkSequentially.toggle) |
|
458 | QtCore.QObject.connect(self.chkDevA, QtCore.SIGNAL("toggled(bool)"), self.grpDevA.setEnabled) | |
|
459 | QtCore.QObject.connect(self.chkDevB, QtCore.SIGNAL("toggled(bool)"), self.grpDevB.setEnabled) | |
|
460 | QtCore.QObject.connect(self.chkDevC, QtCore.SIGNAL("toggled(bool)"), self.grpDevC.setEnabled) | |
|
461 | QtCore.QObject.connect(self.chkDevD, QtCore.SIGNAL("toggled(bool)"), self.grpDevD.setEnabled) | |
|
446 | 462 | QtCore.QMetaObject.connectSlotsByName(MainWindow) |
|
447 | 463 | MainWindow.setTabOrder(self.txtDpath, self.btnDpath) |
|
448 | 464 | MainWindow.setTabOrder(self.btnDpath, self.txtRpath) |
@@ -550,4 +566,4 | |||
|
550 | 566 | ui.setupUi(MainWindow) |
|
551 | 567 | MainWindow.show() |
|
552 | 568 | sys.exit(app.exec_()) |
|
553 | ||
|
569 |
General Comments 0
You need to be logged in to leave comments.
Login now