aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/FbTk/FbWindow.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/FbTk/FbWindow.cc b/src/FbTk/FbWindow.cc
index 2863b3a..5a6417f 100644
--- a/src/FbTk/FbWindow.cc
+++ b/src/FbTk/FbWindow.cc
@@ -46,7 +46,7 @@ namespace FbTk {
46 46
47FbWindow::FbWindow():FbDrawable(), m_parent(0), m_screen_num(0), m_window(0), m_x(0), m_y(0), 47FbWindow::FbWindow():FbDrawable(), m_parent(0), m_screen_num(0), m_window(0), m_x(0), m_y(0),
48 m_width(0), m_height(0), m_border_width(0), m_depth(0), m_destroy(true), 48 m_width(0), m_height(0), m_border_width(0), m_depth(0), m_destroy(true),
49 m_lastbg_pm(0), m_renderer(0) { 49 m_lastbg_color_set(false), m_lastbg_color(0), m_lastbg_pm(0), m_renderer(0) {
50 50
51} 51}
52 52
@@ -57,6 +57,7 @@ FbWindow::FbWindow(const FbWindow& the_copy):FbDrawable(),
57 m_width(the_copy.width()), m_height(the_copy.height()), 57 m_width(the_copy.width()), m_height(the_copy.height()),
58 m_border_width(the_copy.borderWidth()), 58 m_border_width(the_copy.borderWidth()),
59 m_depth(the_copy.depth()), m_destroy(true), 59 m_depth(the_copy.depth()), m_destroy(true),
60 m_lastbg_color_set(false), m_lastbg_color(0),
60 m_lastbg_pm(0), m_renderer(the_copy.m_renderer) { 61 m_lastbg_pm(0), m_renderer(the_copy.m_renderer) {
61 the_copy.m_window = 0; 62 the_copy.m_window = 0;
62} 63}
@@ -91,8 +92,7 @@ FbWindow::FbWindow(const FbWindow &parent,
91 m_parent(&parent), 92 m_parent(&parent),
92 m_screen_num(parent.screenNumber()), 93 m_screen_num(parent.screenNumber()),
93 m_destroy(true), 94 m_destroy(true),
94 m_lastbg_color_set(false), 95 m_lastbg_color_set(false), m_lastbg_color(0),
95 m_lastbg_color(0x42),
96 m_lastbg_pm(0), m_renderer(0) { 96 m_lastbg_pm(0), m_renderer(0) {
97 97
98 create(parent.window(), x, y, width, height, eventmask, 98 create(parent.window(), x, y, width, height, eventmask,
@@ -109,6 +109,7 @@ FbWindow::FbWindow(Window client):FbDrawable(), m_parent(0),
109 m_border_width(0), 109 m_border_width(0),
110 m_depth(0), 110 m_depth(0),
111 m_destroy(false), // don't destroy this window 111 m_destroy(false), // don't destroy this window
112 m_lastbg_color_set(false), m_lastbg_color(0),
112 m_lastbg_pm(0), m_renderer(0) { 113 m_lastbg_pm(0), m_renderer(0) {
113 114
114 setNew(client); 115 setNew(client);
@@ -153,6 +154,9 @@ void FbWindow::updateBackground(bool only_if_alpha) {
153 unsigned char alpha = 255; 154 unsigned char alpha = 255;
154 bool free_newbg = false; 155 bool free_newbg = false;
155 156
157 if (m_lastbg_pm == None && !m_lastbg_color_set)
158 return;
159
156 if (m_transparent.get() != 0) 160 if (m_transparent.get() != 0)
157 alpha = m_transparent->alpha(); 161 alpha = m_transparent->alpha();
158 162