blob: eb30b0495a62bf395e28809f0fbf2243eb25705a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# Copyright 2004-2007 Nanorex, Inc. See LICENSE file for details.
"""
PartProp.py
$Id$
"""
from PyQt4.Qt import QDialog, SIGNAL
from commands.PartProperties.PartPropDialog import Ui_PartPropDialog
class PartProp(QDialog, Ui_PartPropDialog):
def __init__(self, assy):
QDialog.__init__(self)
self.setupUi(self)
self.connect(self.okPushButton,SIGNAL("clicked()"),self.accept)
self.connect(self.cancelPushButton,SIGNAL("clicked()"),self.reject)
self.nameLineEdit.setText(assy.name)
self.mmpformatLabel.setText("MMP File Format: " + assy.mmpformat)
# Get statistics of part and display them in the statView widget.
from commands.GroupProperties.GroupProp import Statistics
stats = Statistics(assy.tree)
stats.display(self.statsView)
def accept(self):
QDialog.accept(self)
def reject(self):
QDialog.reject(self)
|