@@ -112,6 +112,12 @@ void QgsAttributeActionDialog::insertRow( int row, const QgsAction& action )
112
112
item->setCheckState ( action.capture () ? Qt::Checked : Qt::Unchecked );
113
113
mAttributeActionTable ->setItem ( row, Capture, item );
114
114
115
+ // Capture output
116
+ item = new QTableWidgetItem ();
117
+ item->setFlags ( item->flags () & ~( Qt::ItemIsEditable ) );
118
+ item->setCheckState ( action.showInAttributeTable () ? Qt::Checked : Qt::Unchecked );
119
+ mAttributeActionTable ->setItem ( row, ShowInAttributeTable, item );
120
+
115
121
// Icon
116
122
QIcon icon = action.icon ();
117
123
QTableWidgetItem* headerItem = new QTableWidgetItem ( icon, " " );
@@ -190,6 +196,7 @@ QgsAction QgsAttributeActionDialog::rowToAction( int row ) const
190
196
mAttributeActionTable ->item ( row, ActionText )->text (),
191
197
mAttributeActionTable ->verticalHeaderItem ( row )->data ( Qt::UserRole ).toString (),
192
198
mAttributeActionTable ->item ( row, Capture )->checkState () == Qt::Checked,
199
+ mAttributeActionTable ->item ( row, ShowInAttributeTable )->checkState () == Qt::Checked,
193
200
mAttributeActionTable ->item ( row, ShortTitle )->text () );
194
201
return action;
195
202
}
@@ -290,6 +297,7 @@ void QgsAttributeActionDialog::itemDoubleClicked( QTableWidgetItem* item )
290
297
mAttributeActionTable ->verticalHeaderItem ( row )->data ( Qt::UserRole ).toString (),
291
298
mAttributeActionTable ->item ( row, ActionText )->text (),
292
299
mAttributeActionTable ->item ( row, Capture )->checkState () == Qt::Checked,
300
+ mAttributeActionTable ->item ( row, ShowInAttributeTable )->checkState () == Qt::Checked,
293
301
mLayer
294
302
);
295
303
@@ -303,6 +311,7 @@ void QgsAttributeActionDialog::itemDoubleClicked( QTableWidgetItem* item )
303
311
mAttributeActionTable ->item ( row, ShortTitle )->setText ( actionProperties.shortTitle () );
304
312
mAttributeActionTable ->item ( row, ActionText )->setText ( actionProperties.actionText () );
305
313
mAttributeActionTable ->item ( row, Capture )->setCheckState ( actionProperties.capture () ? Qt::Checked : Qt::Unchecked );
314
+ mAttributeActionTable ->item ( row, ShowInAttributeTable )->setCheckState ( actionProperties.showInAttributeTable () ? Qt::Checked : Qt::Unchecked );
306
315
mAttributeActionTable ->verticalHeaderItem ( row )->setData ( Qt::UserRole, actionProperties.iconPath () );
307
316
mAttributeActionTable ->verticalHeaderItem ( row )->setIcon ( QIcon ( actionProperties.iconPath () ) );
308
317
}
0 commit comments