diff options
Diffstat (limited to 'src/FbTk/FbWindow.cc')
-rw-r--r-- | src/FbTk/FbWindow.cc | 8 |
1 files changed, 4 insertions, 4 deletions
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 @@ | |||
19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
20 | // DEALINGS IN THE SOFTWARE. | 20 | // DEALINGS IN THE SOFTWARE. |
21 | 21 | ||
22 | // $Id: FbWindow.cc,v 1.33 2004/05/17 15:01:32 rathnor Exp $ | 22 | // $Id: FbWindow.cc,v 1.34 2004/05/24 13:09:32 rathnor Exp $ |
23 | 23 | ||
24 | #include "FbWindow.hh" | 24 | #include "FbWindow.hh" |
25 | 25 | ||
@@ -240,11 +240,11 @@ void FbWindow::updateTransparent(int the_x, int the_y, unsigned int the_width, u | |||
240 | 240 | ||
241 | void FbWindow::setAlpha(unsigned char alpha) { | 241 | void FbWindow::setAlpha(unsigned char alpha) { |
242 | #ifdef HAVE_XRENDER | 242 | #ifdef HAVE_XRENDER |
243 | if (m_transparent.get() == 0 && alpha != 0) { | 243 | if (m_transparent.get() == 0 && alpha < 255) { |
244 | m_transparent.reset(new Transparent(getRootPixmap(screenNumber()), window(), alpha, screenNumber())); | 244 | m_transparent.reset(new Transparent(getRootPixmap(screenNumber()), window(), alpha, screenNumber())); |
245 | } else if (alpha != 0 && alpha != m_transparent->alpha()) | 245 | } else if (alpha < 255 && alpha != m_transparent->alpha()) |
246 | m_transparent->setAlpha(alpha); | 246 | m_transparent->setAlpha(alpha); |
247 | else if (alpha == 0) | 247 | else if (alpha == 255) |
248 | m_transparent.reset(0); // destroy transparent object | 248 | m_transparent.reset(0); // destroy transparent object |
249 | #endif // HAVE_XRENDER | 249 | #endif // HAVE_XRENDER |
250 | } | 250 | } |