From 64a49abdb29a778bbdc07f5acab710974e87ef4b Mon Sep 17 00:00:00 2001 From: Arin Alexander Date: Thu, 31 Jan 2019 22:03:33 +0300 Subject: [PATCH] Band size changing via keyboard has been fixed --- common.pri | 2 +- limereport/lrpageitemdesignintf.cpp | 11 ++++++++++- limereport/lrpageitemdesignintf.h | 1 + 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/common.pri b/common.pri index ed59d80..f10eaf8 100644 --- a/common.pri +++ b/common.pri @@ -77,7 +77,7 @@ RCC_DIR = $${ARCH_DIR}/$${BUILD_TYPE}/rcc LIMEREPORT_VERSION_MAJOR = 1 LIMEREPORT_VERSION_MINOR = 4 -LIMEREPORT_VERSION_RELEASE = 122 +LIMEREPORT_VERSION_RELEASE = 123 LIMEREPORT_VERSION = '\\"$${LIMEREPORT_VERSION_MAJOR}.$${LIMEREPORT_VERSION_MINOR}.$${LIMEREPORT_VERSION_RELEASE}\\"' DEFINES += LIMEREPORT_VERSION_STR=\"$${LIMEREPORT_VERSION}\" diff --git a/limereport/lrpageitemdesignintf.cpp b/limereport/lrpageitemdesignintf.cpp index b4ba954..21e9c81 100644 --- a/limereport/lrpageitemdesignintf.cpp +++ b/limereport/lrpageitemdesignintf.cpp @@ -303,7 +303,11 @@ void PageItemDesignIntf::registerBand(BandDesignIntf *band) band->setParentItem(this); band->setWidth(pageRect().width()/band->columnsCount()); connect(band, SIGNAL(destroyed(QObject*)),this,SLOT(bandDeleted(QObject*))); - connect(band, SIGNAL(posChanged(QObject*,QPointF,QPointF)),this,SLOT(bandPositionChanged(QObject*,QPointF,QPointF))); + connect(band, SIGNAL(posChanged(QObject*, QPointF, QPointF)), + this, SLOT(bandPositionChanged(QObject*, QPointF, QPointF))); + connect(band, SIGNAL(geometryChanged(QObject*, QRectF, QRectF)), + this, SLOT(bandGeometryChanged(QObject*, QRectF, QRectF))); + } } @@ -699,6 +703,11 @@ void PageItemDesignIntf::bandPositionChanged(QObject* object, QPointF newPos, QP relocateBands(); } +void PageItemDesignIntf::bandGeometryChanged(QObject* object, QRectF newGeometry, QRectF oldGeometry) +{ + bandPositionChanged(object, newGeometry.topLeft(), oldGeometry.topLeft()); +} + void PageItemDesignIntf::collectionLoadFinished(const QString &collectionName) { if (collectionName.compare("children",Qt::CaseInsensitive)==0){ diff --git a/limereport/lrpageitemdesignintf.h b/limereport/lrpageitemdesignintf.h index d7fd6b0..e24556a 100644 --- a/limereport/lrpageitemdesignintf.h +++ b/limereport/lrpageitemdesignintf.h @@ -131,6 +131,7 @@ public: protected slots: void bandDeleted(QObject* band); void bandPositionChanged(QObject* object, QPointF newPos, QPointF oldPos); + void bandGeometryChanged(QObject* object, QRectF newGeometry, QRectF oldGeometry); protected: void collectionLoadFinished(const QString& collectionName); QRectF& pageRect(){return m_pageRect;}