diff options
-rw-r--r-- | viewer.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -91,6 +91,11 @@ void Viewer::displayFile(int index){ if(index < 0){
return;
}
+ if(index == 0){
+ setBackgroundRole(QPalette::Base);
+ }else{
+ setBackgroundRole(QPalette::AlternateBase);
+ }
QPixmap pm(mFiles.at(mCurIndex));
pm = pm.scaled(mMaxSize, Qt::KeepAspectRatio, Qt::SmoothTransformation);
mLabel->setPixmap(pm);
|