aboutsummaryrefslogtreecommitdiff
path: root/src/Screen.cc
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2003-04-25 11:56:13 (GMT)
committerfluxgen <fluxgen>2003-04-25 11:56:13 (GMT)
commitd2a50e03206f58557cfed0ab4bcd12a2c833eb0a (patch)
tree40c63c82206433c14bfea0e8b1d6a80eda7155ec /src/Screen.cc
parente3921394c98ce6e894d7ac0c6d5af2ba0e6fb062 (diff)
downloadfluxbox-d2a50e03206f58557cfed0ab4bcd12a2c833eb0a.zip
fluxbox-d2a50e03206f58557cfed0ab4bcd12a2c833eb0a.tar.bz2
minor fix for root pixmap
Diffstat (limited to 'src/Screen.cc')
-rw-r--r--src/Screen.cc40
1 files changed, 24 insertions, 16 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index 57ae7f0..ac60d79 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: Screen.cc,v 1.132 2003/04/25 11:05:11 fluxgen Exp $ 25// $Id: Screen.cc,v 1.133 2003/04/25 11:56:13 fluxgen Exp $
26 26
27 27
28#include "Screen.hh" 28#include "Screen.hh"
@@ -544,21 +544,6 @@ BScreen::BScreen(ResourceManager &rm,
544 (unsigned char *) &bpid, 1); 544 (unsigned char *) &bpid, 1);
545#endif // HAVE_GETPID 545#endif // HAVE_GETPID
546 546
547 Atom real_type;
548 int real_format;
549 unsigned long items_read, items_left;
550 unsigned int *data;
551 if (XGetWindowProperty(disp, getRootWindow(),
552 XInternAtom(disp, "_XROOTPMAP_ID", false),
553 0L, 1L,
554 false, XA_PIXMAP, &real_type,
555 &real_format, &items_read, &items_left,
556 (unsigned char **) &data) == Success &&
557 items_read) {
558 m_root_pm = (Pixmap) (*data);
559 XFree(data);
560 } else
561 m_root_pm = 0;
562 547
563 cycling_window = focused_list.end(); 548 cycling_window = focused_list.end();
564 549
@@ -784,6 +769,29 @@ FbTk::Menu &BScreen::getToolbarModemenu() {
784unsigned int BScreen::getCurrentWorkspaceID() const { 769unsigned int BScreen::getCurrentWorkspaceID() const {
785 return current_workspace->workspaceID(); 770 return current_workspace->workspaceID();
786} 771}
772
773Pixmap BScreen::rootPixmap() const {
774
775 Pixmap root_pm = 0;
776 Display *disp = FbTk::App::instance()->display();
777 Atom real_type;
778 int real_format;
779 unsigned long items_read, items_left;
780 unsigned int *data;
781 if (XGetWindowProperty(disp, getRootWindow(),
782 XInternAtom(disp, "_XROOTPMAP_ID", false),
783 0L, 1L,
784 false, XA_PIXMAP, &real_type,
785 &real_format, &items_read, &items_left,
786 (unsigned char **) &data) == Success &&
787 items_read) {
788 root_pm = (Pixmap) (*data);
789 XFree(data);
790 }
791
792 return root_pm;
793
794}
787 795
788/// TODO 796/// TODO
789unsigned int BScreen::getMaxLeft() const { 797unsigned int BScreen::getMaxLeft() const {