From 87a016680e3677da3993f333561e79eb0cead7d5 Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 29 Jun 2011 16:05:55 +0000 Subject: TQt4 port ktechlab This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/ktechlab@1238801 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/electronics/pin.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/electronics/pin.cpp') diff --git a/src/electronics/pin.cpp b/src/electronics/pin.cpp index 56848fc..f9a08d8 100644 --- a/src/electronics/pin.cpp +++ b/src/electronics/pin.cpp @@ -13,10 +13,10 @@ #include #include -Pin::Pin( ECNode * parent ) +Pin::Pin( ECNode * tqparent ) { - assert(parent); - m_pECNode = parent; + assert(tqparent); + m_pECNode = tqparent; m_voltage = 0.; m_current = 0.; m_eqId = -2; @@ -70,7 +70,7 @@ void Pin::setSwitchConnected( Pin * pin, bool isConnected ) if (isConnected) { - if ( !m_switchConnectedPins.contains(pin) ) + if ( !m_switchConnectedPins.tqcontains(pin) ) m_switchConnectedPins.append(pin); } else @@ -80,14 +80,14 @@ void Pin::setSwitchConnected( Pin * pin, bool isConnected ) void Pin::addCircuitDependentPin( Pin * pin ) { - if ( pin && !m_circuitDependentPins.contains(pin) ) + if ( pin && !m_circuitDependentPins.tqcontains(pin) ) m_circuitDependentPins.append(pin); } void Pin::addGroundDependentPin( Pin * pin ) { - if ( pin && !m_groundDependentPins.contains(pin) ) + if ( pin && !m_groundDependentPins.tqcontains(pin) ) m_groundDependentPins.append(pin); } @@ -101,7 +101,7 @@ void Pin::removeDependentPins() void Pin::addElement( Element * e ) { - if ( !e || m_elementList.contains(e) ) + if ( !e || m_elementList.tqcontains(e) ) return; m_elementList.append(e); } @@ -115,7 +115,7 @@ void Pin::removeElement( Element * e ) void Pin::addSwitch( Switch * sw ) { - if ( !sw || m_switchList.contains( sw ) ) + if ( !sw || m_switchList.tqcontains( sw ) ) return; m_switchList << sw; } @@ -129,14 +129,14 @@ void Pin::removeSwitch( Switch * sw ) void Pin::addInputWire( Wire * wire ) { - if ( wire && !m_inputWireList.contains(wire) ) + if ( wire && !m_inputWireList.tqcontains(wire) ) m_inputWireList << wire; } void Pin::addOutputWire( Wire * wire ) { - if ( wire && !m_outputWireList.contains(wire) ) + if ( wire && !m_outputWireList.tqcontains(wire) ) m_outputWireList << wire; } -- cgit v1.2.1