Skip to content

Commit

Permalink
[autofix.ci] apply automated fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
autofix-ci[bot] authored Jan 17, 2025
1 parent bfc91c7 commit c8cbdbb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions src/ui/favoritespanewidget.cc
Original file line number Diff line number Diff line change
Expand Up @@ -897,15 +897,15 @@ QModelIndex FavoritesModel::findItemInFolder( const QString & itemName, int item
return QModelIndex();
}

TreeItem *FavoritesPaneWidget::findFolderByName(TreeItem *parent, const QString &name)
TreeItem * FavoritesPaneWidget::findFolderByName( TreeItem * parent, const QString & name )
{
for (int i = 0; i < parent->childCount(); i++) {
TreeItem *child = parent->child(i);
if (child->type() == TreeItem::Folder && child->data().toString() == name) {
return child;
}
for ( int i = 0; i < parent->childCount(); i++ ) {
TreeItem * child = parent->child( i );
if ( child->type() == TreeItem::Folder && child->data().toString() == name ) {
return child;
}
return nullptr;
}
return nullptr;
}

TreeItem * FavoritesModel::getItem( const QModelIndex & index ) const
Expand Down Expand Up @@ -1185,7 +1185,7 @@ bool FavoritesModel::setDataFromXml( QString const & dataStr )
beginResetModel();

if ( !rootItem ) {
rootItem = new TreeItem( QVariant(), 0, TreeItem::Root );
rootItem = new TreeItem( QVariant(), 0, TreeItem::Root );
}

QDomNode rootNode = dom.documentElement();
Expand Down
2 changes: 1 addition & 1 deletion src/ui/favoritespanewidget.hh
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ private slots:

private:
virtual bool eventFilter( QObject *, QEvent * );
TreeItem *findFolderByName(TreeItem *parent, const QString &name);
TreeItem * findFolderByName( TreeItem * parent, const QString & name );
Config::Class * m_cfg = nullptr;
QTreeView * m_favoritesTree = nullptr;
QMenu * m_favoritesMenu = nullptr;
Expand Down

0 comments on commit c8cbdbb

Please sign in to comment.