Back to index

salome-gui  6.5.0
SUIT_DataBrowser.cxx File Reference
#include "SUIT_DataBrowser.h"
#include "SUIT_TreeModel.h"
#include <QtxTreeView.h>
#include <QShortcut>

Go to the source code of this file.


bool modelIndexLessThan (const QModelIndex &lhs, const QModelIndex &rhs)
 function to sort QModelIndexList with qSort

Function Documentation

bool modelIndexLessThan ( const QModelIndex &  lhs,
const QModelIndex &  rhs 

function to sort QModelIndexList with qSort

Definition at line 238 of file SUIT_DataBrowser.cxx.

  QModelIndex lhs_parent=lhs.parent();
  QModelIndex rhs_parent=rhs.parent();
  if(lhs_parent < rhs_parent)return true;
  if(lhs_parent == rhs_parent) return lhs < rhs;
  return false;