mirror of
https://github.com/fralx/LimeReport.git
synced 2024-12-24 16:44:39 +03:00
to fix the crash issue. due to extractAcceptableValue() function was return an empty list
This commit is contained in:
parent
3c2388dce5
commit
7e4e6684c6
@ -32,6 +32,8 @@
|
|||||||
#include "objectinspector/editors/lrcomboboxeditor.h"
|
#include "objectinspector/editors/lrcomboboxeditor.h"
|
||||||
#include "lrtextitem.h"
|
#include "lrtextitem.h"
|
||||||
|
|
||||||
|
#include <QtDebug>
|
||||||
|
|
||||||
namespace{
|
namespace{
|
||||||
LimeReport::ObjectPropItem * createAlignItem(
|
LimeReport::ObjectPropItem * createAlignItem(
|
||||||
QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly
|
QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly
|
||||||
@ -160,7 +162,12 @@ QString AlignmentItemEditor::displayValue() const
|
|||||||
|
|
||||||
void AlignmentItemEditor::setPropertyValue(QVariant value)
|
void AlignmentItemEditor::setPropertyValue(QVariant value)
|
||||||
{
|
{
|
||||||
ObjectPropItem::setPropertyValue(extractAcceptableValue(value.toInt())[0]);
|
//ObjectPropItem::setPropertyValue(extractAcceptableValue(value.toInt())[0]);
|
||||||
|
qDebug()<<"value "<<value;
|
||||||
|
QVector<int> _accpepttableValueList= extractAcceptableValue(value.toInt());
|
||||||
|
if(_accpepttableValueList.isEmpty()) return;
|
||||||
|
|
||||||
|
ObjectPropItem::setPropertyValue(_accpepttableValueList[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user