From ca307efe3e719fbc3917ae54af4e2243ae0e4044 Mon Sep 17 00:00:00 2001 From: rathnor Date: Mon, 24 May 2004 13:09:32 +0000 Subject: handling of alpha = 0 --- ChangeLog | 3 +++ src/FbTk/FbWindow.cc | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index b50a312..67a8fce 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ (Format: Year/Month/Day) Changes for 0.9.10: +*04/05/24: + * Fix handling alpha value of zero (Simon) + FbWindow.cc *04/05/21: * fluxbox-generate_menu: Updated polish locales from: Łukasz Wrzosek (unl at poczta dot fm) diff --git a/src/FbTk/FbWindow.cc b/src/FbTk/FbWindow.cc index 5ebd9f2..e7649d7 100644 --- a/src/FbTk/FbWindow.cc +++ b/src/FbTk/FbWindow.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbWindow.cc,v 1.33 2004/05/17 15:01:32 rathnor Exp $ +// $Id: FbWindow.cc,v 1.34 2004/05/24 13:09:32 rathnor Exp $ #include "FbWindow.hh" @@ -240,11 +240,11 @@ void FbWindow::updateTransparent(int the_x, int the_y, unsigned int the_width, u void FbWindow::setAlpha(unsigned char alpha) { #ifdef HAVE_XRENDER - if (m_transparent.get() == 0 && alpha != 0) { + if (m_transparent.get() == 0 && alpha < 255) { m_transparent.reset(new Transparent(getRootPixmap(screenNumber()), window(), alpha, screenNumber())); - } else if (alpha != 0 && alpha != m_transparent->alpha()) + } else if (alpha < 255 && alpha != m_transparent->alpha()) m_transparent->setAlpha(alpha); - else if (alpha == 0) + else if (alpha == 255) m_transparent.reset(0); // destroy transparent object #endif // HAVE_XRENDER } -- cgit v0.11.2