ChartItem: Series property editor has been added

This commit is contained in:
Arin Alexander
2020-01-31 20:00:28 +03:00
parent a75677ec51
commit 85b3c940d4
12 changed files with 121 additions and 18 deletions

View File

@@ -95,13 +95,17 @@ void ObjectInspectorTreeView::mousePressEvent(QMouseEvent *event)
if ((event->button()==Qt::LeftButton)){
QModelIndex index=indexAt(event->pos());
if (index.isValid()){
if (event->pos().x()<indentation()) {
if (event->pos().x() < indentation()) {
if (!nodeFromIndex(index)->isHaveValue())
setExpanded(index,!isExpanded(index));
} else {
if ((index.column()==1)&&(!nodeFromIndex(index)->isHaveChildren())) {
setCurrentIndex(index);
edit(index);
Qt::ItemFlags flags = index.model()->flags(index);
if ( !(((flags & Qt::ItemIsEditable) == 0) || ((flags & Qt::ItemIsEnabled) == 0)) )
edit(index);
return ;
}
}