##// END OF EJS Templates
verificacion paso 1
ralonso -
r65:66
parent child
Show More
@@ -23,10 +23,9
23 23
24 24 def dir_exists(var_dir, self):
25 25 if os.path.isdir(var_dir):
26 self.txtInfo.append("Ruta valida, sin error:" + str(var_dir))
27 26 return True
28 27 else:
29 self.txtInfo.append("Ruta no valida, output_error:" + str(var_dir))
28 self.txtInfo.append("Incorrect path:" + str(var_dir))
30 29 return False
31 30
32 31
@@ -50,7 +49,7
50 49
51 50 #Si no se encuentra ningun archivo
52 51 if len(output) == 0:
53 self.txtInfo.append("No se encontraron archivos")
52 self.txtInfo.append("File not found")
54 53 self.btnGbkp.setEnabled(False)
55 54 return
56 55
@@ -73,8 +72,6
73 72 self.var_sublist=[]
74 73 for i in self.var_list[self.lstStartDay.currentIndex():self.lstStartDay.currentIndex() + self.lstStopDay.currentIndex()+1]:
75 74 self.var_sublist.append(i)
76 if len(self.var_sublist) == 0:
77 self.txtInfo.append("No existen archivos encontrados")
78 75
79 76
80 77 #----------------------------------------------------- Verifica los parametros faltantes -----------------------------------------------------------
@@ -82,12 +79,12
82 79 def validate_parameters(self):
83 80 #Verifica que las ruta del proyecto sea valida
84 81 if self.statusRpath == False:
85 self.txtInfo.append("Ruta de proyecto no valida")
82 self.txtInfo.append("Incorrect proyect path")
86 83 return False
87 84
88 85 #Verifica la etiqueta
89 86 if len(self.var_Elabel) == 0:
90 self.txtInfo.append("Debe ingresar el nombre de la etiqueta")
87 self.txtInfo.append("Enter label")
91 88 return False
92 89
93 90 return True
@@ -96,14 +93,17
96 93 #------------------------------------------------- Crea directorios en la ruta indicada -----------------------------------------------------------
97 94
98 95 def make_dirs(list_dirs, self):
96 """
97
98 """
99 99
100 100 for var_dir in list_dirs:
101 101 shutil.rmtree(self.var_Rpath+'/'+var_dir, True)
102 102 var_output=commands.getstatusoutput("mkdir -p "+self.var_Rpath+'/'+var_dir)[0]
103 103 if var_output != 0:
104 self.txtInfo.append("Error al crear el directorio "+var_dir+", output_error:" + str(var_output))
104 self.txtInfo.append("Error creating directory: "+var_dir+", output_error:" + str(var_output))
105 105 return False
106 self.txtInfo.append('Carpetas creadas correctamente')
106 self.txtInfo.append('Directories created correctly')
107 107 return True
108 108
109 109
@@ -156,13 +156,13
156 156 var_file.write(var_tmp_path+'='+line+'\n')
157 157 var_file.close()
158 158
159 self.txtInfo.append("Archivos .dat creados")
159 self.txtInfo.append("configuration files created")
160 160 return var_n
161 161
162 162
163 163 #------------------------------ Genera los archivos .print con los cuales se creara los postscript -----------------------------------
164 164
165 def make_files_print2(self):
165 def make_files_print(self):
166 166
167 167 var_Rpath_ppath=self.var_Rpath+"/ppath" #Ruta de los archivos a grabar
168 168 var_Rpath_gpath=self.var_Rpath+"/gpath" #Ruta de los archivos postscript
@@ -203,8 +203,6
203 203 list_files.append([var_first_folder, var_first_file, var_last_file])
204 204
205 205 var_lines2 = lines_print(list_files, self.var_Elabel)
206 self.txtInfo.append("lineas: "+str(len(var_lines2)))
207
208 206
209 207 for k in range(0, len(var_lines2) / 5):
210 208 var_lines=["\n"]
@@ -214,8 +212,6
214 212 var_lines.append("\n")
215 213 var_labels.append(var_lines)
216 214
217 self.txtInfo.append("labels totales: "+str(len(var_labels)))
218
219 215 for i in range(0, (len(var_labels) // 33) +1 ):
220 216 var_file=var_Rpath_gpath+"/"+self.var_Elabel+"_"+i2s(i+1)
221 217 file_ps = open(var_file+".print","w")
@@ -226,7 +222,6
226 222
227 223 for label in var_sub_labels:
228 224 for line in label:
229 self.txtInfo.insertPlainText(line)
230 225 file_ps.write(line)
231 226 file_ps.close()
232 227 var_cmd="enscript "+var_file+".print -p "+var_file+".ps -f Times-Roman7 " \
@@ -256,64 +251,9
256 251
257 252 var_lines.append(var_first_file[-12:-8]+" "+var_first_file[-8:-5]+" "+var_folder +" "+var_first_file[-5:-2]+" "
258 253 +var_last_file[-5:-2]+" "+var_date_first_file+" "+var_date_last_file+"\n")
259 # var_lines = 33 * var_lines
260 254 #Nos aseguramos que sea un mutiplo de 5
261 255 while (len(var_lines) % 5) != 0:
262 256 var_lines.append("\n")
263 257
264 258 return var_lines
265 259
266
267 #def make_files_print(self):
268 #
269 # var_Rpath_ppath=self.var_Rpath+"/ppath" #Ruta de los archivos a grabar
270 #
271 # # Se leen todos los archivos .dat creados para crear las etiquetas en los archivos .print
272 # for var_n in range(1, self.var_Discs + 1):
273 # #se abren los archivos .dat en modo lectura
274 # var_file = open(var_Rpath_ppath+"/"+self.var_Elabel+"_"+i2s(var_n)+".dat","r")
275 # lines=var_file.readlines() # Se lee las lineas en el archivo y se almacenan en la lista
276 # # Se crea el archivo .print
277 # var_file_print = open(var_Rpath_ppath+"/"+self.var_Elabel+"_"+i2s(var_n)+".print","w")
278 # var_file_print.write(self.var_Elabel+" "+i2s(var_n)+"/"+i2s(self.var_Discs)+"\n")
279 # var_file_print.write("Year Doy Folder Set Time range\n")
280 #
281 # var_first_folder = lines[0].split('=')[0]
282 # var_first_file = (lines[0].split('=')[1])[:-1]
283 # var_date_first_file=commands.getstatusoutput("date -r "+var_first_file+" +'%T'")[1]
284 #
285 # for j in range(1, len(lines)-1):
286 # var_tmp_folder = lines[j].split('=')[0]
287 # var_tmp_file = (lines[j].split('=')[1])[:-1]
288 #
289 # # Si el subfolder superior o la fecha del archivo cambia se genera una nueva linea
290 # if (var_tmp_folder != var_first_folder) or (var_tmp_file[0:-5] != var_first_file[0:-5]):
291 # var_last_file = (lines[j-1].split('=')[1])[:-1]
292 # var_date_last_file=commands.getstatusoutput("date -r "+var_last_file+" +'%T'")[1]
293 # # Si el archivo se grabara directamente en la / del DVD y no en un /directorio/
294 # # se usa la etiqueta para indicar la parte de la etiqueta donde va el subdirectorio
295 # if var_first_folder == '/':
296 # var_folder = self.var_Elabel
297 # else:
298 # var_folder = var_first_folder.split('/')[-2]
299 #
300 # var_file_print.write(var_first_file[-12:-8]+" "+var_first_file[-8:-5]+" "+var_folder +" "+var_first_file[-5:-2]+" "
301 # +var_last_file[-5:-2]+" "+var_date_first_file+" "+var_date_last_file+"\n")
302 #
303 # var_first_folder = lines[j].split('=')[0]
304 # var_first_file = (lines[j].split('=')[1])[:-1]
305 # var_date_first_file=commands.getstatusoutput("date -r "+var_first_file+" +'%T'")[1]
306 #
307 # var_last_file = (lines[-1].split('=')[1])[:-1]
308 # var_date_last_file=commands.getstatusoutput("date -r "+var_last_file+" +'%T'")[1]
309 #
310 # if var_first_folder == '/':
311 # var_folder = self.var_Elabel
312 # else:
313 # var_folder = var_first_folder.split('/')[-2]
314 #
315 # var_file_print.write(var_first_file[-12:-8]+" "+var_first_file[-8:-5]+" "+var_folder +" "+var_first_file[-5:-2]+" "
316 # +var_last_file[-5:-2]+" "+var_date_first_file+" "+var_date_last_file+"\n")
317 #
318 # var_file.close()
319 # var_file_print.close()
@@ -146,6 +146,7
146 146 self.tabParameters.setEnabled(not(var_bool))
147 147 self.lstDcapacity.setEnabled(not(var_bool))
148 148 self.txtDcapacity.setEnabled(not(var_bool))
149 self.actionChange_Parameters.setEnabled(var_bool)
149 150 self.btnGbkp.setEnabled(not(var_bool))
150 151 self.btnRestart.setEnabled(var_bool)
151 152 self.btnStartburn.setEnabled(var_bool)
@@ -1,7 +1,7
1 1 <?xml version="1.0" encoding="UTF-8"?>
2 2 <!DOCTYPE Project SYSTEM "Project-4.6.dtd">
3 3 <!-- eric4 project file for project jro_backup_manager -->
4 <!-- Saved: 2010-05-21, 23:57:59 -->
4 <!-- Saved: 2010-05-23, 21:14:20 -->
5 5 <!-- Copyright (C) 2010 , -->
6 6 <Project version="4.6">
7 7 <Language>en</Language>
@@ -22,10 +22,12
22 22 <Source>functions/functions2.py</Source>
23 23 <Source>functions/func_doc.py</Source>
24 24 <Source>ui/Ui_Parameters.py</Source>
25 <Source>ui/Ui_About.py</Source>
25 26 </Sources>
26 27 <Forms>
27 28 <Form>ui/MainWindow.ui</Form>
28 29 <Form>ui/Parameters.ui</Form>
30 <Form>ui/About.ui</Form>
29 31 </Forms>
30 32 <Translations>
31 33 </Translations>
@@ -9,6 +9,7
9 9 from PyQt4 import QtCore
10 10 from Ui_MainWindow import Ui_MainWindow
11 11 from Ui_Parameters import Ui_Parameters
12 from Ui_About import Ui_About
12 13 from PyQt4 import QtGui
13 14 from subprocess import *
14 15 import sys
@@ -51,7 +52,7
51 52
52 53 #Revisa si existe el archivo de confirguracion
53 54 if os.path.isfile("parameters.conf"):
54 self.txtInfo.append("Archivo de configuracion encontrado")
55 self.txtInfo.append("Parameters were loaded from configuration file")
55 56 functions2.get_parameters_conf(self)
56 57 self.txtInfo.append("El proyecto es de "+str(self.var_Discs)+" discos")
57 58 else:
@@ -69,6 +70,7
69 70
70 71 # self.connect(self.actionChange_Parameters, QtCore.SIGNAL("triggered()"), self.dlgui.exec)
71 72 self.connect(self.actionChange_Parameters, QtCore.SIGNAL("triggered()"), self.changeParameters)
73 self.connect(self.actionAbout, QtCore.SIGNAL("triggered()"), self.about)
72 74
73 75 self.var_process = QtCore.QProcess()
74 76 self.connect(self.var_process, QtCore.SIGNAL('readyReadStandardOutput()'), self.readOuput)
@@ -84,12 +86,17
84 86 dlgui=Ui_Parameters()
85 87 dlgui.setupUi(dlg)
86 88 if (dlg.exec_() == QtGui.QDialog.Accepted):
87 self.txtInfo.append(str(dlgui.txtNcopys.value()))
89 if dlgui.txtDisc.value() > self.var_Discs or dlgui.txtCopy.value() > dlgui.txtNcopys.value():
90 self.txtInfo.append("Wrong parameters")
88 91 # txtDisc
89 92 # txtCopy
90
91
92
93
94
95 def about(self):
96 dlg_about=QtGui.QDialog()
97 dlgui_about=Ui_About()
98 dlgui_about.setupUi(dlg_about)
99 dlg_about.exec_()
93 100
94 101 #----------------------------------------------------- Funciones del proceso ---------------------------------------------------------------
95 102
@@ -276,11 +283,15
276 283 return
277 284
278 285 var_files_list = functions.list_files(self) #Se obtiene la lista de archivos a grabar
286
279 287 self.var_Discs = functions.make_files_dat(var_files_list, self) #Se crean los archivos .dat
280 functions.make_files_print2(self) # Se crean los archivos .print
288
289 functions.make_files_print(self) # Se crean los archivos .print
290
281 291 functions2.make_parameters_conf(self) # se crea el archivo parameters.conf
282 self.txtInfo.append("Numero de archivos .iso a grabar: "+str(self.var_Discs))
283 self.txtInfo.append("Numero de DVDs totales a grabar: "+str(self.var_Discs * self.var_Copys))
292
293 self.txtInfo.append("Total number of discs for recording: "+str(self.var_Discs * self.var_Copys))
294
284 295 #Se bloquean los parametros de configuracion
285 296 functions2.enabled_items1(True, self)
286 297
@@ -312,12 +323,12
312 323
313 324 #Verifica que exista algun dispositivo de grabacion seleccionado
314 325 if not(functions2.selected_devices(self)):
315 self.txtInfo.append("No hay ningun dispositivo de grabacion seleccionado ")
326 self.txtInfo.append("There is no recording device selected")
316 327 return
317 328
318 329 #Lista los dispositivos de grabacion a usar
319 330 for dev in self.var_devices:
320 self.txtInfo.append("dispositivo :"+dev)
331 self.txtInfo.append("recording device :"+dev)
321 332
322 333 #Asigna las variables con los valores iniciales
323 334 self.var_disc_n = 0 # numero de disco actual para grabacion
@@ -347,7 +358,7
347 358 #Si ya se grabaron todos los discos
348 359 if self.var_disc_n > self.var_Discs:
349 360 self.bool_state_burning = False
350 self.txtInfo.append("GRABACION TERMINADA")
361 self.txtInfo.append("Recording process is complete")
351 362 # functions2.eject_devices(self) # Expulsa las bandejas de los dispostivos de grabacion
352 363
353 364 return
@@ -405,7 +416,7
405 416 self.bool_state_burning = False
406 417 self.var_process.terminate() #Termina el proceso, si puede
407 418 # self.var_process.kill() #Mata el proceso, no es la forma adecuada, solo usar si terminate() no funciona
408 self.txtInfo.append("SE DETUVO LA GRABACION MANUALMENTE")
419 self.txtInfo.append("Stopped recording")
409 420 functions2.enabled_items2(False, self)
410 421 self.btnStartburn.setText("Start Burn")
411 422
@@ -451,5 +462,4
451 462 """
452 463 Slot documentation goes here.
453 464 """
454 # TODO: not implemented yet
455 raise NotImplementedError
465 pass
@@ -27,7 +27,7
27 27 </sizepolicy>
28 28 </property>
29 29 <property name="currentIndex">
30 <number>2</number>
30 <number>0</number>
31 31 </property>
32 32 <widget class="QWidget" name="tabParameters">
33 33 <property name="enabled">
@@ -251,12 +251,19
251 251 <widget class="QWidget" name="grpDevA" native="true">
252 252 <layout class="QVBoxLayout" name="verticalLayout_11">
253 253 <item>
254 <widget class="QLineEdit" name="txtDeviceA"/>
255 </item>
256 <item>
257 <widget class="QLineEdit" name="txtBspeedA">
258 <property name="text">
259 <string>16</string>
254 <widget class="QLineEdit" name="txtDeviceA">
255 <property name="readOnly">
256 <bool>true</bool>
257 </property>
258 </widget>
259 </item>
260 <item>
261 <widget class="QSpinBox" name="txtBspeedA">
262 <property name="minimum">
263 <number>1</number>
264 </property>
265 <property name="value">
266 <number>16</number>
260 267 </property>
261 268 </widget>
262 269 </item>
@@ -265,6 +272,9
265 272 <property name="text">
266 273 <string>-sao</string>
267 274 </property>
275 <property name="readOnly">
276 <bool>true</bool>
277 </property>
268 278 </widget>
269 279 </item>
270 280 <item>
@@ -295,12 +305,19
295 305 <widget class="QWidget" name="grpDevB" native="true">
296 306 <layout class="QVBoxLayout" name="verticalLayout_12">
297 307 <item>
298 <widget class="QLineEdit" name="txtDeviceB"/>
299 </item>
300 <item>
301 <widget class="QLineEdit" name="txtBspeedB">
302 <property name="text">
303 <string>16</string>
308 <widget class="QLineEdit" name="txtDeviceB">
309 <property name="readOnly">
310 <bool>true</bool>
311 </property>
312 </widget>
313 </item>
314 <item>
315 <widget class="QSpinBox" name="txtBspeedB">
316 <property name="minimum">
317 <number>1</number>
318 </property>
319 <property name="value">
320 <number>16</number>
304 321 </property>
305 322 </widget>
306 323 </item>
@@ -309,6 +326,9
309 326 <property name="text">
310 327 <string>-sao</string>
311 328 </property>
329 <property name="readOnly">
330 <bool>true</bool>
331 </property>
312 332 </widget>
313 333 </item>
314 334 <item>
@@ -339,12 +359,19
339 359 <widget class="QWidget" name="grpDevC" native="true">
340 360 <layout class="QVBoxLayout" name="verticalLayout_13">
341 361 <item>
342 <widget class="QLineEdit" name="txtDeviceC"/>
343 </item>
344 <item>
345 <widget class="QLineEdit" name="txtBspeedC">
346 <property name="text">
347 <string>16</string>
362 <widget class="QLineEdit" name="txtDeviceC">
363 <property name="readOnly">
364 <bool>true</bool>
365 </property>
366 </widget>
367 </item>
368 <item>
369 <widget class="QSpinBox" name="txtBspeedC">
370 <property name="minimum">
371 <number>1</number>
372 </property>
373 <property name="value">
374 <number>16</number>
348 375 </property>
349 376 </widget>
350 377 </item>
@@ -353,6 +380,9
353 380 <property name="text">
354 381 <string>-sao</string>
355 382 </property>
383 <property name="readOnly">
384 <bool>true</bool>
385 </property>
356 386 </widget>
357 387 </item>
358 388 <item>
@@ -383,12 +413,19
383 413 <widget class="QWidget" name="grpDevD" native="true">
384 414 <layout class="QVBoxLayout" name="verticalLayout_14">
385 415 <item>
386 <widget class="QLineEdit" name="txtDeviceD"/>
387 </item>
388 <item>
389 <widget class="QLineEdit" name="txtBspeedD">
390 <property name="text">
391 <string>16</string>
416 <widget class="QLineEdit" name="txtDeviceD">
417 <property name="readOnly">
418 <bool>true</bool>
419 </property>
420 </widget>
421 </item>
422 <item>
423 <widget class="QSpinBox" name="txtBspeedD">
424 <property name="minimum">
425 <number>1</number>
426 </property>
427 <property name="value">
428 <number>16</number>
392 429 </property>
393 430 </widget>
394 431 </item>
@@ -397,6 +434,9
397 434 <property name="text">
398 435 <string>-sao</string>
399 436 </property>
437 <property name="readOnly">
438 <bool>true</bool>
439 </property>
400 440 </widget>
401 441 </item>
402 442 <item>
@@ -419,49 +459,58
419 459 <enum>Qt::Vertical</enum>
420 460 </property>
421 461 <property name="sizeType">
422 <enum>QSizePolicy::Fixed</enum>
462 <enum>QSizePolicy::Minimum</enum>
423 463 </property>
424 464 <property name="sizeHint" stdset="0">
425 465 <size>
426 466 <width>20</width>
427 <height>25</height>
467 <height>40</height>
428 468 </size>
429 469 </property>
430 470 </spacer>
431 471 </item>
432 472 <item>
433 <widget class="QLabel" name="lblDevice">
434 <property name="text">
435 <string>Device</string>
436 </property>
437 </widget>
438 </item>
439 <item>
440 <widget class="QLabel" name="lblBspeed">
441 <property name="text">
442 <string>Burn Speed</string>
443 </property>
444 </widget>
445 </item>
446 <item>
447 <widget class="QLabel" name="lblBmode">
448 <property name="text">
449 <string>Burn Mode</string>
450 </property>
451 </widget>
452 </item>
453 <item>
454 <spacer name="horizontalSpacer_11">
455 <property name="orientation">
456 <enum>Qt::Horizontal</enum>
457 </property>
458 <property name="sizeHint" stdset="0">
459 <size>
460 <width>40</width>
461 <height>20</height>
462 </size>
463 </property>
464 </spacer>
473 <widget class="QWidget" name="grpDevD_2" native="true">
474 <layout class="QVBoxLayout" name="verticalLayout_20">
475 <item>
476 <widget class="QLabel" name="lblDevice">
477 <property name="text">
478 <string>Device</string>
479 </property>
480 </widget>
481 </item>
482 <item>
483 <widget class="QLabel" name="lblBspeed">
484 <property name="text">
485 <string>Burn Speed</string>
486 </property>
487 </widget>
488 </item>
489 <item>
490 <widget class="QLabel" name="lblBmode">
491 <property name="text">
492 <string>Burn Mode</string>
493 </property>
494 </widget>
495 </item>
496 <item>
497 <spacer name="verticalSpacer_4">
498 <property name="orientation">
499 <enum>Qt::Vertical</enum>
500 </property>
501 <property name="sizeType">
502 <enum>QSizePolicy::Fixed</enum>
503 </property>
504 <property name="sizeHint" stdset="0">
505 <size>
506 <width>20</width>
507 <height>40</height>
508 </size>
509 </property>
510 </spacer>
511 </item>
512 </layout>
513 </widget>
465 514 </item>
466 515 </layout>
467 516 </item>
@@ -1216,12 +1265,6
1216 1265 <height>21</height>
1217 1266 </rect>
1218 1267 </property>
1219 <widget class="QMenu" name="menuParameters">
1220 <property name="title">
1221 <string>Parameters</string>
1222 </property>
1223 <addaction name="actionChange_Parameters"/>
1224 </widget>
1225 1268 <widget class="QMenu" name="menuFile">
1226 1269 <property name="title">
1227 1270 <string>File</string>
@@ -1234,12 +1277,21
1234 1277 </property>
1235 1278 <addaction name="actionAbout"/>
1236 1279 </widget>
1280 <widget class="QMenu" name="menuParameters">
1281 <property name="title">
1282 <string>Parameters</string>
1283 </property>
1284 <addaction name="actionChange_Parameters"/>
1285 </widget>
1237 1286 <addaction name="menuFile"/>
1238 1287 <addaction name="menuParameters"/>
1239 1288 <addaction name="menuHelp"/>
1240 1289 </widget>
1241 1290 <widget class="QStatusBar" name="statusbar"/>
1242 1291 <action name="actionChange_Parameters">
1292 <property name="enabled">
1293 <bool>false</bool>
1294 </property>
1243 1295 <property name="text">
1244 1296 <string>Change Parameters</string>
1245 1297 </property>
@@ -1251,7 +1303,7
1251 1303 </action>
1252 1304 <action name="actionAbout">
1253 1305 <property name="text">
1254 <string>About JRO BACKUP MANAGER</string>
1306 <string>About</string>
1255 1307 </property>
1256 1308 </action>
1257 1309 </widget>
@@ -1333,8 +1385,8
1333 1385 <y>341</y>
1334 1386 </hint>
1335 1387 <hint type="destinationlabel">
1336 <x>495</x>
1337 <y>338</y>
1388 <x>599</x>
1389 <y>349</y>
1338 1390 </hint>
1339 1391 </hints>
1340 1392 </connection>
@@ -2,7 +2,7
2 2
3 3 # Form implementation generated from reading ui file '/home/ricardoar/JRO_SVN/eric4/jro_backup_manager/ui/MainWindow.ui'
4 4 #
5 # Created: Sun May 23 12:15:30 2010
5 # Created: Sun May 23 20:29:23 2010
6 6 # by: PyQt4 UI code generator 4.7.2
7 7 #
8 8 # WARNING! All changes made in this file will be lost!
@@ -150,12 +150,16
150 150 self.verticalLayout_11 = QtGui.QVBoxLayout(self.grpDevA)
151 151 self.verticalLayout_11.setObjectName("verticalLayout_11")
152 152 self.txtDeviceA = QtGui.QLineEdit(self.grpDevA)
153 self.txtDeviceA.setReadOnly(True)
153 154 self.txtDeviceA.setObjectName("txtDeviceA")
154 155 self.verticalLayout_11.addWidget(self.txtDeviceA)
155 self.txtBspeedA = QtGui.QLineEdit(self.grpDevA)
156 self.txtBspeedA = QtGui.QSpinBox(self.grpDevA)
157 self.txtBspeedA.setMinimum(1)
158 self.txtBspeedA.setProperty("value", 16)
156 159 self.txtBspeedA.setObjectName("txtBspeedA")
157 160 self.verticalLayout_11.addWidget(self.txtBspeedA)
158 161 self.txtBmodeA = QtGui.QLineEdit(self.grpDevA)
162 self.txtBmodeA.setReadOnly(True)
159 163 self.txtBmodeA.setObjectName("txtBmodeA")
160 164 self.verticalLayout_11.addWidget(self.txtBmodeA)
161 165 self.btnTdevA = QtGui.QPushButton(self.grpDevA)
@@ -174,12 +178,16
174 178 self.verticalLayout_12 = QtGui.QVBoxLayout(self.grpDevB)
175 179 self.verticalLayout_12.setObjectName("verticalLayout_12")
176 180 self.txtDeviceB = QtGui.QLineEdit(self.grpDevB)
181 self.txtDeviceB.setReadOnly(True)
177 182 self.txtDeviceB.setObjectName("txtDeviceB")
178 183 self.verticalLayout_12.addWidget(self.txtDeviceB)
179 self.txtBspeedB = QtGui.QLineEdit(self.grpDevB)
184 self.txtBspeedB = QtGui.QSpinBox(self.grpDevB)
185 self.txtBspeedB.setMinimum(1)
186 self.txtBspeedB.setProperty("value", 16)
180 187 self.txtBspeedB.setObjectName("txtBspeedB")
181 188 self.verticalLayout_12.addWidget(self.txtBspeedB)
182 189 self.txtBmodeB = QtGui.QLineEdit(self.grpDevB)
190 self.txtBmodeB.setReadOnly(True)
183 191 self.txtBmodeB.setObjectName("txtBmodeB")
184 192 self.verticalLayout_12.addWidget(self.txtBmodeB)
185 193 self.btnTdevB = QtGui.QPushButton(self.grpDevB)
@@ -198,12 +206,16
198 206 self.verticalLayout_13 = QtGui.QVBoxLayout(self.grpDevC)
199 207 self.verticalLayout_13.setObjectName("verticalLayout_13")
200 208 self.txtDeviceC = QtGui.QLineEdit(self.grpDevC)
209 self.txtDeviceC.setReadOnly(True)
201 210 self.txtDeviceC.setObjectName("txtDeviceC")
202 211 self.verticalLayout_13.addWidget(self.txtDeviceC)
203 self.txtBspeedC = QtGui.QLineEdit(self.grpDevC)
212 self.txtBspeedC = QtGui.QSpinBox(self.grpDevC)
213 self.txtBspeedC.setMinimum(1)
214 self.txtBspeedC.setProperty("value", 16)
204 215 self.txtBspeedC.setObjectName("txtBspeedC")
205 216 self.verticalLayout_13.addWidget(self.txtBspeedC)
206 217 self.txtBmodeC = QtGui.QLineEdit(self.grpDevC)
218 self.txtBmodeC.setReadOnly(True)
207 219 self.txtBmodeC.setObjectName("txtBmodeC")
208 220 self.verticalLayout_13.addWidget(self.txtBmodeC)
209 221 self.btnTdevC = QtGui.QPushButton(self.grpDevC)
@@ -222,12 +234,16
222 234 self.verticalLayout_14 = QtGui.QVBoxLayout(self.grpDevD)
223 235 self.verticalLayout_14.setObjectName("verticalLayout_14")
224 236 self.txtDeviceD = QtGui.QLineEdit(self.grpDevD)
237 self.txtDeviceD.setReadOnly(True)
225 238 self.txtDeviceD.setObjectName("txtDeviceD")
226 239 self.verticalLayout_14.addWidget(self.txtDeviceD)
227 self.txtBspeedD = QtGui.QLineEdit(self.grpDevD)
240 self.txtBspeedD = QtGui.QSpinBox(self.grpDevD)
241 self.txtBspeedD.setMinimum(1)
242 self.txtBspeedD.setProperty("value", 16)
228 243 self.txtBspeedD.setObjectName("txtBspeedD")
229 244 self.verticalLayout_14.addWidget(self.txtBspeedD)
230 245 self.txtBmodeD = QtGui.QLineEdit(self.grpDevD)
246 self.txtBmodeD.setReadOnly(True)
231 247 self.txtBmodeD.setObjectName("txtBmodeD")
232 248 self.verticalLayout_14.addWidget(self.txtBmodeD)
233 249 self.btnTdevD = QtGui.QPushButton(self.grpDevD)
@@ -567,6 +583,7
567 583 self.statusbar.setObjectName("statusbar")
568 584 MainWindow.setStatusBar(self.statusbar)
569 585 self.actionChange_Parameters = QtGui.QAction(MainWindow)
586 self.actionChange_Parameters.setEnabled(True)
570 587 self.actionChange_Parameters.setObjectName("actionChange_Parameters")
571 588 self.actionQuit = QtGui.QAction(MainWindow)
572 589 self.actionQuit.setObjectName("actionQuit")
@@ -580,7 +597,7
580 597 self.menubar.addAction(self.menuHelp.menuAction())
581 598
582 599 self.retranslateUi(MainWindow)
583 self.tabWidget.setCurrentIndex(2)
600 self.tabWidget.setCurrentIndex(0)
584 601 self.lstDcapacity.setCurrentIndex(2)
585 602 QtCore.QObject.connect(self.actionQuit, QtCore.SIGNAL("triggered()"), MainWindow.close)
586 603 QtCore.QObject.connect(self.chkCheck, QtCore.SIGNAL("toggled(bool)"), self.txtTDpath.setEnabled)
@@ -622,19 +639,15
622 639 self.lblStopDay.setText(QtGui.QApplication.translate("MainWindow", "Stop Day:", None, QtGui.QApplication.UnicodeUTF8))
623 640 self.tabWidget.setTabText(self.tabWidget.indexOf(self.tabParameters), QtGui.QApplication.translate("MainWindow", "Parameters", None, QtGui.QApplication.UnicodeUTF8))
624 641 self.chkDevA.setText(QtGui.QApplication.translate("MainWindow", "Dev A", None, QtGui.QApplication.UnicodeUTF8))
625 self.txtBspeedA.setText(QtGui.QApplication.translate("MainWindow", "16", None, QtGui.QApplication.UnicodeUTF8))
626 642 self.txtBmodeA.setText(QtGui.QApplication.translate("MainWindow", "-sao", None, QtGui.QApplication.UnicodeUTF8))
627 643 self.btnTdevA.setText(QtGui.QApplication.translate("MainWindow", "Test DevA", None, QtGui.QApplication.UnicodeUTF8))
628 644 self.chkDevB.setText(QtGui.QApplication.translate("MainWindow", "Dev B", None, QtGui.QApplication.UnicodeUTF8))
629 self.txtBspeedB.setText(QtGui.QApplication.translate("MainWindow", "16", None, QtGui.QApplication.UnicodeUTF8))
630 645 self.txtBmodeB.setText(QtGui.QApplication.translate("MainWindow", "-sao", None, QtGui.QApplication.UnicodeUTF8))
631 646 self.btnTdevB.setText(QtGui.QApplication.translate("MainWindow", "Test DevB", None, QtGui.QApplication.UnicodeUTF8))
632 647 self.chkDevC.setText(QtGui.QApplication.translate("MainWindow", "Dev C", None, QtGui.QApplication.UnicodeUTF8))
633 self.txtBspeedC.setText(QtGui.QApplication.translate("MainWindow", "16", None, QtGui.QApplication.UnicodeUTF8))
634 648 self.txtBmodeC.setText(QtGui.QApplication.translate("MainWindow", "-sao", None, QtGui.QApplication.UnicodeUTF8))
635 649 self.btnTdevC.setText(QtGui.QApplication.translate("MainWindow", "Test DevC", None, QtGui.QApplication.UnicodeUTF8))
636 650 self.chkDevD.setText(QtGui.QApplication.translate("MainWindow", "Dev D", None, QtGui.QApplication.UnicodeUTF8))
637 self.txtBspeedD.setText(QtGui.QApplication.translate("MainWindow", "16", None, QtGui.QApplication.UnicodeUTF8))
638 651 self.txtBmodeD.setText(QtGui.QApplication.translate("MainWindow", "-sao", None, QtGui.QApplication.UnicodeUTF8))
639 652 self.btnTdevD.setText(QtGui.QApplication.translate("MainWindow", "Test DevD", None, QtGui.QApplication.UnicodeUTF8))
640 653 self.lblDevice.setText(QtGui.QApplication.translate("MainWindow", "Device", None, QtGui.QApplication.UnicodeUTF8))
General Comments 0
You need to be logged in to leave comments. Login now