Two attempt to optimize the managment of the updates and focus changes in the glarea

This commit is contained in:
Paolo Cignoni cignoni 2012-06-08 14:42:45 +00:00
parent c85bd6054b
commit 809fd2903f
2 changed files with 5 additions and 5 deletions

View File

@ -780,8 +780,8 @@ void GLArea::keyPressEvent ( QKeyEvent * e )
void GLArea::mousePressEvent(QMouseEvent*e)
{
e->accept();
setFocus();
e->accept();
if(!this->hasFocus()) this->setFocus();
if(!isRaster() || isRaster())
{

View File

@ -238,14 +238,14 @@ void LayerDialog::updateLog(GLLogStream &log)
QString preFilter = "<font face=\"courier\" size=2 color=\"black\">" ;
QString post = "</font>";
QString logText;
foreach(logElem, logStringList){
QString logText = logElem.second;
logText += logElem.second;
if(logElem.first == GLLogStream::SYSTEM) logText = preSystem + logText + post;
if(logElem.first == GLLogStream::WARNING) logText = preWarn + logText + post;
if(logElem.first == GLLogStream::FILTER) logText = preFilter + logText + post;
ui->logPlainTextEdit->appendHtml(logText);
}
ui->logPlainTextEdit->appendHtml(logText);
}
void LayerDialog::updateTable()