Source Code (Use browser search to find items of interest.)

Class Index

caitoo'LogWindow (./kdenetwork/caitoo/logwindow.h:84)

class LogWindow : public KDialogBase {
  
  Q_OBJECT
  
public:
  LogWindow();
  ~LogWindow() {}

  void logGeneral( const QString &message );
  QString getText() const;

public slots:
  void logTransfer( uint id, const QString &filename, const QString &message );

protected:
  void closeEvent( QCloseEvent * );

private:
  QTextView *mixed_log;
  SeparatedLog *sep_log;
};


caitoo'LogWindow::LogWindow() (./kdenetwork/caitoo/logwindow.cpp:179)

LogWindow::LogWindow()
  : KDialogBase( Tabbed, i18n("Log Window"), Close, Close, 0, "", false ) {

  // add pages
  QFrame *page = addPage( i18n("Mixed") );
  QVBoxLayout *topLayout = new QVBoxLayout( page, 0, spacingHint() );
  mixed_log = new QTextView( page );
  mixed_log->setTextFormat( RichText );
  topLayout->addWidget( mixed_log );  

  page = addPage( i18n("Separated") );
  topLayout = new QVBoxLayout( page, 0, spacingHint() );
  sep_log = new SeparatedLog( page );
  topLayout->addWidget( sep_log );  

  setButtonOKText( i18n("Close") );

  connect(this, SIGNAL( closeClicked() ),
	  this, SLOT( close() ) );

//   resize( 500, 300 );
}



caitoo'LogWindow::closeEvent() (./kdenetwork/caitoo/logwindow.cpp:203)

void LogWindow::closeEvent( QCloseEvent* ) {
  kmain->m_paShowLog->setChecked( false );
}



caitoo'LogWindow::logGeneral() (./kdenetwork/caitoo/logwindow.cpp:208)

void LogWindow::logGeneral( const QString &message ) {
  QString tmps;

  tmps = "<code><font color=\"blue\">" + QTime::currentTime().toString() +
    "</font> : <strong>" + message + "</strong></code><br/>";

  mixed_log->append(tmps);
}



caitoo'LogWindow::logTransfer() (./kdenetwork/caitoo/logwindow.cpp:218)

void LogWindow::logTransfer( uint id, const QString &filename, const QString &message ) {
  QString tmp1, tmp2;

  tmp1 = "<code><font color=\"blue\">" + QTime::currentTime().toString() +
    "</font> : " + message + "</code><br/>";
  tmp2.sprintf( "<strong>%d</strong> : ", id );

  mixed_log->append( tmp2 + tmp1);
  sep_log->addLog( id, filename, tmp1 );
}



caitoo'LogWindow::getText() (./kdenetwork/caitoo/logwindow.cpp:230)

QString LogWindow::getText() const {
  return removeHTML( mixed_log->text() );
}