~ubuntu-branches/ubuntu/precise/fritzing/precise

« back to all changes in this revision

Viewing changes to src/items/tracewire.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Georges Khaznadar
  • Date: 2011-08-26 10:11:05 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20110826101105-w5hmn7zcf93ig5v6
Tags: 0.6.3b-1
* upgrapded to the newer upstream version
* parameters of the function GraphicsUtils::distanceFromLine in 
  src/svg/groundplanegenerator.cpp:767 are now declared as doubles,
  which Closes: #636441
* the new version fixes src/utils/folderutils.cpp, which
  Closes: #636061

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 
19
19
********************************************************************
20
20
 
21
 
$Revision: 5143 $:
 
21
$Revision: 5375 $:
22
22
$Author: cohen@irascible.com $:
23
 
$Date: 2011-07-01 02:37:01 +0200 (Fri, 01 Jul 2011) $
 
23
$Date: 2011-08-08 21:38:25 +0200 (Mon, 08 Aug 2011) $
24
24
 
25
25
********************************************************************/
26
26
 
49
49
{
50
50
}
51
51
 
52
 
QComboBox * TraceWire::createWidthComboBox(qreal m, QWidget * parent) 
 
52
QComboBox * TraceWire::createWidthComboBox(double m, QWidget * parent) 
53
53
{
54
54
        QComboBox * comboBox = new FocusOutComboBox(parent);  // new QComboBox(parent);
55
55
        comboBox->setEditable(true);
109
109
 
110
110
int TraceWire::widthEntry(const QString & text, QObject * sender) {
111
111
 
112
 
        QComboBox * comboBox = dynamic_cast<QComboBox *>(sender);
 
112
        QComboBox * comboBox = qobject_cast<QComboBox *>(sender);
113
113
        if (comboBox == NULL) return 0;
114
114
 
115
115
        int w = comboBox->itemData(comboBox->currentIndex()).toInt();
165
165
 
166
166
TraceWire * TraceWire::getTrace(ConnectorItem * connectorItem)
167
167
{
168
 
        return dynamic_cast<TraceWire *>(connectorItem->attachedTo());
 
168
        return qobject_cast<TraceWire *>(connectorItem->attachedTo());
169
169
}
170
170
 
171
171
void TraceWire::setSchematic(bool schematic) {