From 898ce50c09d501500721f3b2cd74e502bf5fbc95 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Mon, 11 May 2015 12:33:15 -0400 Subject: Put in a quick check/safeguard for invalid panel sizing. --- lumina-desktop/LPanel.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/lumina-desktop/LPanel.cpp b/lumina-desktop/LPanel.cpp index 3755e9a6..7531d53e 100644 --- a/lumina-desktop/LPanel.cpp +++ b/lumina-desktop/LPanel.cpp @@ -109,6 +109,7 @@ void LPanel::UpdatePanel(){ layout->setDirection(QBoxLayout::TopToBottom); } int ht = settings->value(PPREFIX+"height", 30).toInt(); //this is technically the distance into the screen from the edge + if(ht<=1){ ht = 30; } //some kind of error in the saved height - use the default value int hidesize = qRound(ht*0.01); //use 1% of the panel size if(hidesize<2){ hidesize=2; } //minimum of 2 pixels (need space for the mouse to go over it) if(hidden){ viswidth = hidesize; } -- cgit