Commit 61bfeff6 authored by Dirk Wilden's avatar Dirk Wilden

speeeeeeed

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@8405 383ad7c9-94d9-4d36-a494-682f7c89f535
parent fe58e470
......@@ -167,6 +167,8 @@ void LoggerWidget::scrollTo(int _pos){
/// Append a new logmessage to log viewer
void LoggerWidget::append(QString _text, Logtype _type){
QTime time;
time.start();
list_->addItem(_text);
......@@ -204,7 +206,9 @@ void LoggerWidget::append(QString _text, Logtype _type){
break;
}
if ( !isHidden() )
list_->scrollToBottom();
}
//-------------------------------------------------------------------------------------
......@@ -240,6 +244,11 @@ void LoggerWidget::updateList(){
list_->scrollToBottom();
}
//-------------------------------------------------------------------------------------
void LoggerWidget::showEvent ( QShowEvent * event ) {
list_->scrollToBottom();
}
//-------------------------------------------------------------------------------------
/// handle keyPressEvents
......
......@@ -82,6 +82,12 @@ class LoggerWidget : public QWidget
*/
void contextMenuEvent ( QContextMenuEvent * event );
/** \brief Called when the widget is shown
*
* Function scrolls to bottom if the object gets visible
*/
void showEvent ( QShowEvent * event );
private:
QListWidget* list_;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment