code format
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
#include "blockview.h"
|
||||
|
||||
#include <QApplication>
|
||||
|
||||
|
||||
#define BLOCKITEM_DEFAULT_PIN_MARGIN 20
|
||||
|
||||
BlockItem::BlockItem(QGraphicsItem * parent): QGraphicsObject(parent), PropertyStorage(),
|
||||
g_main(this), g_selection(this) {
|
||||
BlockItem::BlockItem(QGraphicsItem * parent): QGraphicsObject(parent), PropertyStorage(), g_main(this), g_selection(this) {
|
||||
setData(bvidType, bvitBlock);
|
||||
setZValue(2.);
|
||||
setAcceptHoverEvents(true);
|
||||
@@ -58,11 +58,9 @@ void BlockItem::_resize(QSizeF s) {
|
||||
|
||||
void BlockItem::_moveToTop(bool only_decors) {
|
||||
qreal dy = -g_main.rect().center().y() + 10;
|
||||
if (!only_decors)
|
||||
moveBy(0., dy);
|
||||
foreach (QGraphicsItem * d, decors_)
|
||||
if (!only_decors) moveBy(0., dy);
|
||||
foreach(QGraphicsItem * d, decors_)
|
||||
d->moveBy(0., -dy);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -70,30 +68,27 @@ BlockItemPin * BlockItem::addPin(BlockItemPin * pin, bool update_) {
|
||||
pin->setParentItem(this);
|
||||
if (!pins_[pin->alignment()].contains(pin)) pins_[pin->alignment()] << pin;
|
||||
pin->parent_ = this;
|
||||
if (update_)
|
||||
arrangePins();
|
||||
if (update_) arrangePins();
|
||||
return pin;
|
||||
}
|
||||
|
||||
|
||||
BlockItemPin * BlockItem::addPin(Qt::Alignment align, int bus_type, const QString & text, bool update_) {
|
||||
BlockItemPin * pin = new BlockItemPin(align, bus_type, text, this);
|
||||
pin->parent_ = this;
|
||||
pin->parent_ = this;
|
||||
pins_[pin->alignment()] << pin;
|
||||
if (update_)
|
||||
arrangePins();
|
||||
if (update_) arrangePins();
|
||||
return pin;
|
||||
}
|
||||
|
||||
|
||||
void BlockItem::removePin(BlockItemPin * pin) {
|
||||
if (!pin) return;
|
||||
QMutableMapIterator<Qt::Alignment, QVector<BlockItemPin * > > it(pins_);
|
||||
QMutableMapIterator<Qt::Alignment, QVector<BlockItemPin *>> it(pins_);
|
||||
while (it.hasNext()) {
|
||||
it.next();
|
||||
QVector<BlockItemPin * > & pv(it.value());
|
||||
if (pv.contains(pin))
|
||||
pv.remove(it.value().indexOf(pin));
|
||||
QVector<BlockItemPin *> & pv(it.value());
|
||||
if (pv.contains(pin)) pv.remove(it.value().indexOf(pin));
|
||||
}
|
||||
delete pin;
|
||||
arrangePins();
|
||||
@@ -102,12 +97,13 @@ void BlockItem::removePin(BlockItemPin * pin) {
|
||||
|
||||
void BlockItem::addDecor(QGraphicsItem * item) {
|
||||
if (decors_.contains(item)) return;
|
||||
if (qgraphicsitem_cast<QGraphicsPixmapItem*>(item))
|
||||
qgraphicsitem_cast<QGraphicsPixmapItem*>(item)->setTransformationMode(Qt::SmoothTransformation);
|
||||
if (qgraphicsitem_cast<QGraphicsSimpleTextItem*>(item))
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem*>(item)->setData(bvidDecorText, qgraphicsitem_cast<QGraphicsSimpleTextItem*>(item)->text());
|
||||
if (qgraphicsitem_cast<AlignedTextItem*>(item))
|
||||
qgraphicsitem_cast<AlignedTextItem*>(item)->setData(bvidDecorText, qgraphicsitem_cast<AlignedTextItem*>(item)->text());
|
||||
if (qgraphicsitem_cast<QGraphicsPixmapItem *>(item))
|
||||
qgraphicsitem_cast<QGraphicsPixmapItem *>(item)->setTransformationMode(Qt::SmoothTransformation);
|
||||
if (qgraphicsitem_cast<QGraphicsSimpleTextItem *>(item))
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem *>(item)->setData(bvidDecorText,
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem *>(item)->text());
|
||||
if (qgraphicsitem_cast<AlignedTextItem *>(item))
|
||||
qgraphicsitem_cast<AlignedTextItem *>(item)->setData(bvidDecorText, qgraphicsitem_cast<AlignedTextItem *>(item)->text());
|
||||
item->setData(bvidMoveParent, true);
|
||||
item->setData(bvidBlockDecor, true);
|
||||
decors_ << item;
|
||||
@@ -117,12 +113,13 @@ void BlockItem::addDecor(QGraphicsItem * item) {
|
||||
|
||||
void BlockItem::addDecor(QGraphicsItem & item) {
|
||||
if (decors_.contains(&item)) return;
|
||||
if (qgraphicsitem_cast<QGraphicsPixmapItem*>(&item))
|
||||
qgraphicsitem_cast<QGraphicsPixmapItem*>(&item)->setTransformationMode(Qt::SmoothTransformation);
|
||||
if (qgraphicsitem_cast<QGraphicsSimpleTextItem*>(&item))
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem*>(&item)->setData(bvidDecorText, qgraphicsitem_cast<QGraphicsSimpleTextItem*>(&item)->text());
|
||||
if (qgraphicsitem_cast<AlignedTextItem*>(&item))
|
||||
qgraphicsitem_cast<AlignedTextItem*>(&item)->setData(bvidDecorText, qgraphicsitem_cast<AlignedTextItem*>(&item)->text());
|
||||
if (qgraphicsitem_cast<QGraphicsPixmapItem *>(&item))
|
||||
qgraphicsitem_cast<QGraphicsPixmapItem *>(&item)->setTransformationMode(Qt::SmoothTransformation);
|
||||
if (qgraphicsitem_cast<QGraphicsSimpleTextItem *>(&item))
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem *>(&item)->setData(bvidDecorText,
|
||||
qgraphicsitem_cast<QGraphicsSimpleTextItem *>(&item)->text());
|
||||
if (qgraphicsitem_cast<AlignedTextItem *>(&item))
|
||||
qgraphicsitem_cast<AlignedTextItem *>(&item)->setData(bvidDecorText, qgraphicsitem_cast<AlignedTextItem *>(&item)->text());
|
||||
item.setData(bvidMoveParent, true);
|
||||
item.setData(bvidBlockDecor, true);
|
||||
item.setParentItem(this);
|
||||
@@ -130,22 +127,21 @@ void BlockItem::addDecor(QGraphicsItem & item) {
|
||||
|
||||
|
||||
void BlockItem::removeDecor(QGraphicsItem * item) {
|
||||
if (scene() && item)
|
||||
scene()->sendEvent(item, new QGraphicsSceneEvent(QEvent::Close));
|
||||
if (scene() && item) scene()->sendEvent(item, new QGraphicsSceneEvent(QEvent::Close));
|
||||
decors_.removeAll(item);
|
||||
delete item;
|
||||
}
|
||||
|
||||
|
||||
QVector<BlockItemPin * > BlockItem::takePins() {
|
||||
QVector<BlockItemPin * > ret = pins();
|
||||
QVector<BlockItemPin *> BlockItem::takePins() {
|
||||
QVector<BlockItemPin *> ret = pins();
|
||||
pins_.clear();
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
void BlockItem::clearPins() {
|
||||
QList<QVector<BlockItemPin * > > mp = pins_.values();
|
||||
QList<QVector<BlockItemPin *>> mp = pins_.values();
|
||||
for (int i = 0; i < mp.size(); ++i)
|
||||
qDeleteAll(mp[i]);
|
||||
pins_.clear();
|
||||
@@ -156,7 +152,7 @@ void BlockItem::clearDecors() {
|
||||
bool pbs = false;
|
||||
if (scene()) pbs = scene()->blockSignals(true);
|
||||
if (scene()) {
|
||||
foreach (QGraphicsItem * i, decors_)
|
||||
foreach(QGraphicsItem * i, decors_)
|
||||
scene()->sendEvent(i, new QGraphicsSceneEvent(QEvent::Close));
|
||||
}
|
||||
qDeleteAll(decors_);
|
||||
@@ -168,9 +164,9 @@ void BlockItem::clearDecors() {
|
||||
}
|
||||
|
||||
|
||||
QVector<BlockItemPin * > BlockItem::pins() const {
|
||||
QList<QVector<BlockItemPin * > > mp = pins_.values();
|
||||
QVector<BlockItemPin * > ret;
|
||||
QVector<BlockItemPin *> BlockItem::pins() const {
|
||||
QList<QVector<BlockItemPin *>> mp = pins_.values();
|
||||
QVector<BlockItemPin *> ret;
|
||||
for (int i = 0; i < mp.size(); ++i)
|
||||
ret << mp[i];
|
||||
return ret;
|
||||
@@ -186,15 +182,15 @@ QByteArray BlockItem::saveModel() {
|
||||
|
||||
|
||||
void BlockItem::loadModel(const QByteArray & data) {
|
||||
//qDebug() << "load from" << data.size() << "bytes";
|
||||
// qDebug() << "load from" << data.size() << "bytes";
|
||||
clearPins();
|
||||
clearDecors();
|
||||
col = Qt::lightGray;
|
||||
_resize(QSizeF(100., 60.));
|
||||
if (data.isEmpty()) return;
|
||||
ChunkStream cs(data);
|
||||
QVector<BlockItemPin * > tp;
|
||||
QList<QGraphicsItem * > dl;
|
||||
QVector<BlockItemPin *> tp;
|
||||
QList<QGraphicsItem *> dl;
|
||||
int version = -1;
|
||||
while (!cs.atEnd()) {
|
||||
switch (cs.read()) {
|
||||
@@ -204,30 +200,32 @@ void BlockItem::loadModel(const QByteArray & data) {
|
||||
case 4: setColor(cs.getData<QColor>()); break;
|
||||
case 5:
|
||||
cs.get(tp);
|
||||
foreach (BlockItemPin * p, tp) addPin(p);
|
||||
foreach(BlockItemPin * p, tp)
|
||||
addPin(p);
|
||||
break;
|
||||
case 6:
|
||||
cs.get(dl);
|
||||
foreach (QGraphicsItem * d, dl) addDecor(d);
|
||||
foreach(QGraphicsItem * d, dl)
|
||||
addDecor(d);
|
||||
break;
|
||||
case 7: setPinsMargin(cs.getData<int>()); break;
|
||||
case 0xFF: cs.get(version); break;
|
||||
}
|
||||
}
|
||||
if (version <= 0)
|
||||
_moveToTop(true);
|
||||
if (version <= 0) _moveToTop(true);
|
||||
}
|
||||
|
||||
|
||||
QByteArray BlockItem::save() const {
|
||||
ChunkStream cs;
|
||||
QMap<QString, QList<BlockItem::Property> > pp;
|
||||
foreach (BlockItemPin * p, pins()) {
|
||||
//qDebug() << "save pin" << p->text() << "->" << p->properties().size();
|
||||
QMap<QString, QList<BlockItem::Property>> pp;
|
||||
foreach(BlockItemPin * p, pins()) {
|
||||
// qDebug() << "save pin" << p->text() << "->" << p->properties().size();
|
||||
pp[p->text()] = p->properties();
|
||||
}
|
||||
cs << cs.chunk(1, pos()) << cs.chunk(2, rotation()) << cs.chunk(3, props) << cs.chunk(5, pp) << cs.chunk(6, size());
|
||||
cs << cs.chunk(10, data(2000)) << cs.chunk(11, data(2001)) << cs.chunk(12, prop_bindings) << cs.chunk(0xFF, _blockitem_current_version_);
|
||||
cs << cs.chunk(10, data(2000)) << cs.chunk(11, data(2001)) << cs.chunk(12, prop_bindings)
|
||||
<< cs.chunk(0xFF, _blockitem_current_version_);
|
||||
return cs.data();
|
||||
}
|
||||
|
||||
@@ -235,7 +233,7 @@ QByteArray BlockItem::save() const {
|
||||
void BlockItem::load(const QByteArray & data) {
|
||||
if (data.isEmpty()) return;
|
||||
ChunkStream cs(data);
|
||||
QMap<QString, QList<BlockItem::Property> > _p;
|
||||
QMap<QString, QList<BlockItem::Property>> _p;
|
||||
int version = -1;
|
||||
while (!cs.atEnd()) {
|
||||
switch (cs.read()) {
|
||||
@@ -244,17 +242,16 @@ void BlockItem::load(const QByteArray & data) {
|
||||
case 3: cs.get(props); break;
|
||||
case 5:
|
||||
cs.get(_p);
|
||||
//qDebug() << "load pins" << _p.size();
|
||||
foreach (BlockItemPin * p, pins()) {
|
||||
//qDebug() << "load pin" << p->text() << "->" << _p.contains(p->text());
|
||||
if (_p.contains(p->text()))
|
||||
p->properties() = _p[p->text()];
|
||||
// qDebug() << "load pins" << _p.size();
|
||||
foreach(BlockItemPin * p, pins()) {
|
||||
// qDebug() << "load pin" << p->text() << "->" << _p.contains(p->text());
|
||||
if (_p.contains(p->text())) p->properties() = _p[p->text()];
|
||||
}
|
||||
break;
|
||||
case 6: setSize(cs.getData<QSizeF>()); break;
|
||||
case 10: setData(2000, cs.getData<QVariant>()); break;
|
||||
case 11: setData(2001, cs.getData<QVariant>()); break;
|
||||
case 12: prop_bindings = cs.getData<QList<QPair<QString, QString> > >(); break;
|
||||
case 12: prop_bindings = cs.getData<QList<QPair<QString, QString>>>(); break;
|
||||
case 0xFF: cs.get(version); break;
|
||||
}
|
||||
}
|
||||
@@ -272,8 +269,8 @@ BlockItem * BlockItem::copy() const {
|
||||
ret->setSelected(false);
|
||||
ret->props = props;
|
||||
ret->setPinsMargin(pinsMargin());
|
||||
QVector<BlockItemPin * > mp = pins();
|
||||
foreach (BlockItemPin * p, mp) {
|
||||
QVector<BlockItemPin *> mp = pins();
|
||||
foreach(BlockItemPin * p, mp) {
|
||||
BlockItemPin * np = new BlockItemPin();
|
||||
np->setBusType(p->busType());
|
||||
np->setAlignment(p->alignment());
|
||||
@@ -283,39 +280,38 @@ BlockItem * BlockItem::copy() const {
|
||||
ret->addPin(np);
|
||||
}
|
||||
QByteArray ba;
|
||||
foreach (QGraphicsItem * i, decors_) {
|
||||
foreach(QGraphicsItem * i, decors_) {
|
||||
ba.clear();
|
||||
QGraphicsItem * ni = 0;
|
||||
QDataStream s(&ba, QIODevice::ReadWrite); s << i;
|
||||
QDataStream s2(ba); s2 >> ni;
|
||||
if (ni)
|
||||
ret->addDecor(ni);
|
||||
QDataStream s(&ba, QIODevice::ReadWrite);
|
||||
s << i;
|
||||
QDataStream s2(ba);
|
||||
s2 >> ni;
|
||||
if (ni) ret->addDecor(ni);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
QList<BlockBusItem * > BlockItem::connectedBuses() const {
|
||||
QList<BlockBusItem * > ret;
|
||||
foreach (BlockItemPin * p, pins())
|
||||
QList<BlockBusItem *> BlockItem::connectedBuses() const {
|
||||
QList<BlockBusItem *> ret;
|
||||
foreach(BlockItemPin * p, pins())
|
||||
ret << p->connectedBuses();
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
BlockItemPin * BlockItem::pinByText(const QString & t) const {
|
||||
foreach (BlockItemPin * p, pins())
|
||||
if (p->text() == t)
|
||||
return p;
|
||||
foreach(BlockItemPin * p, pins())
|
||||
if (p->text() == t) return p;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
BlockItemPin * BlockItem::pinAtBus(BlockBusItem * bus) const {
|
||||
if (bus == 0) return 0;
|
||||
foreach (BlockItemPin * p, pins())
|
||||
if (p->connectedBuses().contains(bus))
|
||||
return p;
|
||||
foreach(BlockItemPin * p, pins())
|
||||
if (p->connectedBuses().contains(bus)) return p;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -337,7 +333,8 @@ void BlockItem::hoverEnterEvent(QGraphicsSceneHoverEvent * e) {
|
||||
anim_thick.setStartValue(thickness());
|
||||
anim_thick.setEndValue(2.5);
|
||||
anim_thick.start();
|
||||
} else setThickness(2.5);
|
||||
} else
|
||||
setThickness(2.5);
|
||||
emit blockHoverEnter(this);
|
||||
}
|
||||
|
||||
@@ -349,7 +346,8 @@ void BlockItem::hoverLeaveEvent(QGraphicsSceneHoverEvent * e) {
|
||||
anim_thick.setStartValue(thickness());
|
||||
anim_thick.setEndValue(1);
|
||||
anim_thick.start();
|
||||
} else setThickness(1);
|
||||
} else
|
||||
setThickness(1);
|
||||
emit blockHoverLeave(this);
|
||||
}
|
||||
|
||||
@@ -357,25 +355,29 @@ void BlockItem::hoverLeaveEvent(QGraphicsSceneHoverEvent * e) {
|
||||
#define _POS(m) (i - ((cp.size() - 1) / 2)) * m
|
||||
|
||||
void BlockItem::arrangePins() {
|
||||
QVector<BlockItemPin * > pl = pins();
|
||||
QVector<BlockItemPin *> pl = pins();
|
||||
pins_.clear();
|
||||
foreach (BlockItemPin * p, pl)
|
||||
foreach(BlockItemPin * p, pl)
|
||||
pins_[p->alignment()] << p;
|
||||
QVector<BlockItemPin * > cp = pins_.value(Qt::AlignBottom);
|
||||
for (int i = 0; i < cp.size(); ++i) cp[i]->setPos(_POS(pins_margin), bottom());
|
||||
QVector<BlockItemPin *> cp = pins_.value(Qt::AlignBottom);
|
||||
for (int i = 0; i < cp.size(); ++i)
|
||||
cp[i]->setPos(_POS(pins_margin), bottom());
|
||||
cp = pins_.value(Qt::AlignTop);
|
||||
for (int i = 0; i < cp.size(); ++i) cp[i]->setPos(_POS(pins_margin), top());
|
||||
for (int i = 0; i < cp.size(); ++i)
|
||||
cp[i]->setPos(_POS(pins_margin), top());
|
||||
cp = pins_.value(Qt::AlignLeft);
|
||||
for (int i = 0; i < cp.size(); ++i) cp[i]->setPos(left(), i * pins_margin);
|
||||
for (int i = 0; i < cp.size(); ++i)
|
||||
cp[i]->setPos(left(), i * pins_margin);
|
||||
cp = pins_.value(Qt::AlignRight);
|
||||
for (int i = 0; i < cp.size(); ++i) cp[i]->setPos(right(), i * pins_margin);
|
||||
for (int i = 0; i < cp.size(); ++i)
|
||||
cp[i]->setPos(right(), i * pins_margin);
|
||||
}
|
||||
|
||||
#undef _POS
|
||||
|
||||
|
||||
void BlockItem::removeBindings(const QString & bind_name) {
|
||||
for(int i=0; i<prop_bindings.size(); ++i) {
|
||||
for (int i = 0; i < prop_bindings.size(); ++i) {
|
||||
if (prop_bindings[i].second == bind_name) {
|
||||
prop_bindings.removeAt(i);
|
||||
i--;
|
||||
@@ -385,7 +387,7 @@ void BlockItem::removeBindings(const QString & bind_name) {
|
||||
|
||||
|
||||
void BlockItem::removeBindingByProperty(const QString & prop_name) {
|
||||
for(int i=0; i<prop_bindings.size(); ++i) {
|
||||
for (int i = 0; i < prop_bindings.size(); ++i) {
|
||||
if (prop_bindings[i].first == prop_name) {
|
||||
prop_bindings.removeAt(i);
|
||||
i--;
|
||||
@@ -402,7 +404,7 @@ void BlockItem::addBinding(const QString & prop_name, const QString & bind_name)
|
||||
|
||||
|
||||
void BlockItem::applyBinding(const QString & bind_name, const QVariant & bind_value) {
|
||||
for(int i=0; i<prop_bindings.size(); ++i) {
|
||||
for (int i = 0; i < prop_bindings.size(); ++i) {
|
||||
if (prop_bindings[i].second == bind_name) {
|
||||
setPropertyValue(prop_bindings[i].first, bind_value);
|
||||
}
|
||||
@@ -411,7 +413,7 @@ void BlockItem::applyBinding(const QString & bind_name, const QVariant & bind_va
|
||||
|
||||
|
||||
void BlockItem::applyBindings(const PropertyStorage & bindings) {
|
||||
for(int i=0; i<prop_bindings.size(); ++i) {
|
||||
for (int i = 0; i < prop_bindings.size(); ++i) {
|
||||
if (bindings.isPropertyExists(prop_bindings[i].second)) {
|
||||
setPropertyValue(prop_bindings[i].first, bindings.propertyValueByName(prop_bindings[i].second));
|
||||
}
|
||||
@@ -419,18 +421,18 @@ void BlockItem::applyBindings(const PropertyStorage & bindings) {
|
||||
}
|
||||
|
||||
|
||||
void BlockItem::setBindings(const QList<QPair<QString, QString> > & bindings) {
|
||||
void BlockItem::setBindings(const QList<QPair<QString, QString>> & bindings) {
|
||||
prop_bindings = bindings;
|
||||
}
|
||||
|
||||
|
||||
QList<QPair<QString, QString> > BlockItem::getBindings() {
|
||||
QList<QPair<QString, QString>> BlockItem::getBindings() {
|
||||
return prop_bindings;
|
||||
}
|
||||
|
||||
|
||||
QString BlockItem::getBindName(const QString & prop_name) const {
|
||||
for(int i=0; i<prop_bindings.size(); ++i) {
|
||||
for (int i = 0; i < prop_bindings.size(); ++i) {
|
||||
if (prop_bindings[i].first == prop_name) {
|
||||
return prop_bindings[i].second;
|
||||
}
|
||||
@@ -441,14 +443,14 @@ QString BlockItem::getBindName(const QString & prop_name) const {
|
||||
|
||||
QStringList BlockItem::getBindNames() const {
|
||||
QStringList ret;
|
||||
for(int i=0; i<prop_bindings.size(); ++i)
|
||||
for (int i = 0; i < prop_bindings.size(); ++i)
|
||||
if (!ret.contains(prop_bindings[i].second)) ret << prop_bindings[i].second;
|
||||
return ret;
|
||||
}
|
||||
|
||||
QStringList BlockItem::getBindProps() const {
|
||||
QStringList ret;
|
||||
for(int i=0; i<prop_bindings.size(); ++i)
|
||||
for (int i = 0; i < prop_bindings.size(); ++i)
|
||||
ret << prop_bindings[i].first;
|
||||
return ret;
|
||||
}
|
||||
@@ -456,7 +458,7 @@ QStringList BlockItem::getBindProps() const {
|
||||
|
||||
QVariant BlockItem::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant & value) {
|
||||
if (change == QGraphicsItem::ItemSelectedChange) {
|
||||
// qDebug() << "select" << value.toBool();
|
||||
// qDebug() << "select" << value.toBool();
|
||||
if (value.toBool() && !isSelected() && ((BlockView *)scene()->views().back())->isBlockAnimationEnabled() && t_sel.elapsed() > 50) {
|
||||
g_selection.setRect(enlargedRect(g_main.rect(), 0, 0, 16));
|
||||
anim_sel.setStartValue(selectionRect());
|
||||
@@ -490,4 +492,3 @@ QRectF BlockItem::selectionRect() const {
|
||||
void BlockItem::setSelectionRect(const QRectF & r) {
|
||||
g_selection.setRect(r);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user