mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-17 16:11:12 +02:00
2021-10-05 Fred Gleason <fredg@paravelsystems.com>
* Added 'RDTextValidator::setUpperCaseOnly()' and 'RDTextValidator::setLowerCaseOnly()' methods. * Added the RDGroupListModel::indexOf()' method. * Fixed a bug in the 'Rename Group' dialog in rdadmin(1) that caused the group being renamed to be deleted when simply attempting to change the case of its name. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -159,6 +159,17 @@ QVariant RDGroupListModel::data(const QModelIndex &index,int role) const
|
||||
}
|
||||
|
||||
|
||||
QModelIndex RDGroupListModel::indexOf(const QString &grpname) const
|
||||
{
|
||||
int row=d_visible_groups.indexOf(grpname);
|
||||
|
||||
if(row<0) {
|
||||
return QModelIndex();
|
||||
}
|
||||
return index(row,0);
|
||||
}
|
||||
|
||||
|
||||
QString RDGroupListModel::groupName(const QModelIndex &row) const
|
||||
{
|
||||
return d_texts.at(row.row()).at(0).toString();
|
||||
|
Reference in New Issue
Block a user