if (!m)return;if (idx < 0)d->models.append(m);else d->models.insert(idx, m);connect(m,SIGNAL(rowsAboutToBeInserted(QModelIndex, int, int)),this, SLOT(s_rowsAboutToBeInserted(QModelIndex, int, int)));connect(m,SIGNAL(rowsInserted(QModelIndex, int, int)),this, SLOT(s_rowsInserted(QModelIndex, int, int)));connect(m,SIGNAL(rowsAboutToBeRemoved(QModelIndex, int, int)),this, SLOT(s_rowsAboutToBeRemoved(QModelIndex, int, int)));connect(m,SIGNAL(rowsRemoved(QModelIndex, int, int)),this, SLOT(s_rowsRemoved(QModelIndex, int, int)));connect(m,SIGNAL(dataChanged(QModelIndex,QModelIndex)),this, SLOT(s_dataChanged(QModelIndex,QModelIndex)));connect(m,SIGNAL(modelReset()),this, SLOT(s_modelReset()));connect(m,SIGNAL(layoutAboutToBeChanged()),this, SIGNAL(layoutAboutToBeChanged()));connect(m,SIGNAL(layoutChanged()),this, SIGNAL(layoutChanged()));connect(m,SIGNAL(destroyed(QObject *)),this, SLOT(s_destroyed(QObject *)));d->columnCount = -1;d->rowCount = -1;d->tops.clear();reset();}void RowsJoinerProxy::removeSourceModel(QAbstractItemModel * m){if (!m)return;disconnect(m,