~ubuntu-branches/ubuntu/trusty/fritzing/trusty-proposed

« back to all changes in this revision

Viewing changes to src/connectors/connector.h

  • Committer: Package Import Robot
  • Author(s): Enrique Hernández Bello
  • Date: 2012-11-11 21:38:56 UTC
  • mfrom: (1.1.5)
  • Revision ID: package-import@ubuntu.com-20121111213856-0825ywdrtdcshl91
Tags: 0.7.10b-1
* New upstream version. Closes: #661495, #692998
* Removed useless patches.
* Removed SetupAPI.lib from sourceless files.
* Skip dfsg tarball creation if there are no sourceless files.
* Added libqt4-sql-sqlite to dependencies. Thanks to Tom Hummel <tom@bluespice.org>.

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 
19
19
********************************************************************
20
20
 
21
 
$Revision: 5666 $:
 
21
$Revision: 6409 $:
22
22
$Author: cohen@irascible.com $:
23
 
$Date: 2011-12-05 18:07:55 +0100 (Mon, 05 Dec 2011) $
 
23
$Date: 2012-09-13 05:05:28 +0200 (Thu, 13 Sep 2012) $
24
24
 
25
25
********************************************************************/
26
26
 
35
35
#include <QSvgRenderer>
36
36
#include <QPointer>
37
37
 
38
 
#include "../viewidentifierclass.h"
39
38
#include "../viewlayer.h"
40
39
 
41
40
class Connector : public QObject
54
53
        Connector(class ConnectorShared *, class ModelPart * modelPart);
55
54
        ~Connector();
56
55
 
57
 
        Connector::ConnectorType connectorType();
 
56
        Connector::ConnectorType connectorType() const;
58
57
        void addViewItem(class ConnectorItem *);
59
58
        void removeViewItem(class ConnectorItem *);
60
59
        class ConnectorShared * connectorShared();
62
61
        void disconnectFrom(Connector *);
63
62
        void saveAsPart(QXmlStreamWriter & writer);
64
63
        const QList<Connector *> & toConnectors();
65
 
        ConnectorItem * connectorItemByViewLayerID(ViewIdentifierClass::ViewIdentifier viewIdentifier, ViewLayer::ViewLayerID);
 
64
        ConnectorItem * connectorItemByViewLayerID(ViewLayer::ViewIdentifier viewIdentifier, ViewLayer::ViewLayerID);
66
65
        bool connectionIsAllowed(Connector* that);
67
 
        const QString & connectorSharedID();
68
 
        const QString & connectorSharedName();  
69
 
        const QString & connectorSharedDescription();
 
66
        const QString & connectorSharedID() const;
 
67
        const QString & connectorSharedName() const;    
 
68
        const QString & connectorSharedDescription() const;
70
69
        class ErcData * connectorSharedErcData();
71
70
        const QString & busID();
72
71
        class Bus * bus();
74
73
        long modelIndex();
75
74
        ModelPart * modelPart();
76
75
        int connectorItemCount();
77
 
        void unprocess(ViewIdentifierClass::ViewIdentifier viewIdentifier, ViewLayer::ViewLayerID viewLayerID);
78
 
        struct SvgIdLayer * fullPinInfo(ViewIdentifierClass::ViewIdentifier viewId, ViewLayer::ViewLayerID viewLayerID);
 
76
        void unprocess(ViewLayer::ViewIdentifier viewIdentifier, ViewLayer::ViewLayerID viewLayerID);
 
77
        struct SvgIdLayer * fullPinInfo(ViewLayer::ViewIdentifier viewId, ViewLayer::ViewLayerID viewLayerID);
 
78
        const QList<SvgIdLayer *> svgIdLayers() const;
79
79
        QList< QPointer<class ConnectorItem> > viewItems();
80
 
        const QString & legID(ViewIdentifierClass::ViewIdentifier, ViewLayer::ViewLayerID);
 
80
        const QString & legID(ViewLayer::ViewIdentifier, ViewLayer::ViewLayerID);
81
81
        void setConnectorLocalName(const QString &);
82
82
        const QString & connectorLocalName();
 
83
        void addPin(ViewLayer::ViewIdentifier, const QString & svgId, ViewLayer::ViewLayerID, const QString & terminalId, const QString & legId, bool hybrid);
83
84
 
84
85
public:
85
86
        static void initNames();
88
89
 
89
90
protected:
90
91
        void writeLayerAttr(QXmlStreamWriter &writer, ViewLayer::ViewLayerID);
91
 
        void writeSvgIdAttr(QXmlStreamWriter &writer, ViewIdentifierClass::ViewIdentifier view, QString connId);
92
 
        void writeTerminalIdAttr(QXmlStreamWriter &writer, ViewIdentifierClass::ViewIdentifier view, QString terminalId);
 
92
        void writeSvgIdAttr(QXmlStreamWriter &writer, ViewLayer::ViewIdentifier view, QString connId);
 
93
        void writeTerminalIdAttr(QXmlStreamWriter &writer, ViewLayer::ViewIdentifier view, QString terminalId);
93
94
 
94
95
protected:
95
96
        QPointer<class ConnectorShared> m_connectorShared;