|
|
@@ -1,28 +0,0 @@ |
|
|
|
#include "CircleElement.h" |
|
|
|
#include <QLineF> |
|
|
|
#include <QBrush> |
|
|
|
|
|
|
|
CircleElement::CircleElement(Tone *tone): tone(tone){ |
|
|
|
QLineF * guidingLine = new QLineF(); |
|
|
|
guidingLine->setP1(QPoint(0,100)); |
|
|
|
guidingLine->setP2(QPoint(0,0)); |
|
|
|
guidingLine->setAngle(90- 30 * tone->getQuintenPosition()); |
|
|
|
setRect(guidingLine->p2().x(),guidingLine->p2().y(), 70,70); |
|
|
|
setPos(guidingLine->p2()); |
|
|
|
setBrush(QBrush(tone->getColor())); |
|
|
|
|
|
|
|
delete guidingLine; |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
CircleElement::CircleElement(){}; |
|
|
|
CircleElement::~CircleElement(){}; |
|
|
|
|
|
|
|
Tone * CircleElement::getTone()const{ |
|
|
|
return tone; |
|
|
|
}; |
|
|
|
|
|
|
|
//SLOTS: |
|
|
|
void CircleElement::redraw(){ |
|
|
|
setBrush(QBrush(tone->getColor())); |
|
|
|
}; |