forked from blue/squawk
Refactoring of signal/slots connection to new qt syntax
This commit is contained in:
parent
9d491e9e93
commit
0b57e6a77f
16 changed files with 81 additions and 83 deletions
|
@ -32,7 +32,7 @@ Models::Group::~Group()
|
|||
void Models::Group::appendChild(Models::Item* child)
|
||||
{
|
||||
Item::appendChild(child);
|
||||
connect(child, SIGNAL(childChanged(Models::Item*, int, int)), this, SLOT(refresh()));
|
||||
connect(child, &Item::childChanged, this, &Group::refresh);
|
||||
changed(1);
|
||||
refresh();
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ QVariant Models::Group::data(int column) const
|
|||
void Models::Group::_removeChild(int index)
|
||||
{
|
||||
Item* child = childItems[index];
|
||||
disconnect(child, SIGNAL(childChanged(Models::Item*, int, int)), this, SLOT(refresh()));
|
||||
disconnect(child, &Item::childChanged, this, &Group::refresh);
|
||||
Item::_removeChild(index);
|
||||
changed(1);
|
||||
refresh();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue