All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines
Public Member Functions
QGpGuiTools::LoopProgressWidget Class Reference

Brief description of class still missing. More...

#include <LoopProgressWidget.h>

List of all members.

Public Member Functions

 LoopProgressWidget (QWidget *parent=0)
void setLoop (ParallelLoop *loop)
 ~LoopProgressWidget ()

Detailed Description

Brief description of class still missing.

Full description of class still missing


Constructor & Destructor Documentation

Description of constructor still missing

References TRACE.

    : QScrollArea(parent)
{
  TRACE;
  //::setWidgetColor(viewport(), Qt::gray);
  setWidgetResizable(true);
  setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
}

Description of destructor still missing

References TRACE.

{
  TRACE;
}

Member Function Documentation

References QGpGuiTools::Application::instance(), QGpCoreTools::CoreApplicationPrivate::maximumThreadCount(), TRACE, and w.

{
  TRACE;
  // Clear all progress widgets
  delete widget();
  _labelList.clear();
  _progressList.clear();
  // Create new ones
  QWidget * w=new QWidget(this);
  QVBoxLayout * layout=new QVBoxLayout(w);
  setWidget(w);
  // We setup the maximum number of possible parallel threads
  // Effectively some of them might not start according to system load
  int nProgress=Application::instance()->maximumThreadCount();
  for(int i=0; i<nProgress; i++ ) {
    QLabel * l=new QLabel(w);
    _labelList.append(l);
    layout->addWidget(l);
    QProgressBar * p=new QProgressBar(w);
    _progressList.append(p);
    layout->addWidget(p);
    connect(loop, SIGNAL(statusChanged(int, QString)), this, SLOT(setStatus(int, QString)));
    connect(loop, SIGNAL(progressInit(int, int)), this, SLOT(initProgress(int, int)));
    connect(loop, SIGNAL(progressChanged(int, int)), this, SLOT(setProgress(int, int)));
  }
  layout->addStretch();
}

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines