sync with bb-cvs

This commit is contained in:
Dana Jansens 2002-06-01 17:54:32 +00:00
parent 4e0fde35ac
commit 1775e867c4
9 changed files with 29 additions and 16 deletions

View file

@ -40,6 +40,7 @@ extern "C" {
} }
#include <algorithm> #include <algorithm>
#include <assert.h>
using namespace std; using namespace std;
#include "i18n.hh" #include "i18n.hh"

View file

@ -25,13 +25,15 @@
# include "../config.h" # include "../config.h"
#endif // HAVE_CONFIG_H #endif // HAVE_CONFIG_H
#include "Color.hh"
#include "BaseDisplay.hh"
extern "C" { extern "C" {
#include <stdio.h> #include <stdio.h>
} }
#include <assert.h>
#include "Color.hh"
#include "BaseDisplay.hh"
BColor::ColorCache BColor::colorcache; BColor::ColorCache BColor::colorcache;
bool BColor::cleancache = false; bool BColor::cleancache = false;

View file

@ -90,8 +90,6 @@ BGCCache::~BGCCache(void) {
std::for_each(cache, cache + cache_total_size, PointerAssassin()); std::for_each(cache, cache + cache_total_size, PointerAssassin());
delete [] cache; delete [] cache;
delete [] contexts; delete [] contexts;
cache = 0;
contexts = 0;
} }
@ -116,6 +114,7 @@ BGCCacheContext *BGCCache::nextContext(unsigned int scr) {
fprintf(stderr, "BGCCache: context fault!\n"); fprintf(stderr, "BGCCache: context fault!\n");
abort(); abort();
return (BGCCacheContext*) 0; // not reached
} }

View file

@ -66,8 +66,11 @@ extern "C" {
#endif // HAVE_STDARG_H #endif // HAVE_STDARG_H
} }
#include <assert.h>
#include <algorithm> #include <algorithm>
#include <functional> #include <functional>
#include <string>
using std::string; using std::string;
#include "i18n.hh" #include "i18n.hh"
@ -1039,7 +1042,7 @@ void BScreen::changeWorkspaceID(unsigned int id) {
if (blackbox->getFocusedWindow() && if (blackbox->getFocusedWindow() &&
blackbox->getFocusedWindow()->getScreen() == this && blackbox->getFocusedWindow()->getScreen() == this &&
(! blackbox->getFocusedWindow()->isStuck())) { ! blackbox->getFocusedWindow()->isStuck()) {
current_workspace->setLastFocusedWindow(blackbox->getFocusedWindow()); current_workspace->setLastFocusedWindow(blackbox->getFocusedWindow());
blackbox->setFocusedWindow((BlackboxWindow *) 0); blackbox->setFocusedWindow((BlackboxWindow *) 0);
} }

View file

@ -32,6 +32,8 @@ extern "C" {
#endif #endif
} }
#include <assert.h>
#include "Texture.hh" #include "Texture.hh"
#include "BaseDisplay.hh" #include "BaseDisplay.hh"
#include "Image.hh" #include "Image.hh"

View file

@ -52,6 +52,8 @@ extern "C" {
#include <X11/Xatom.h> #include <X11/Xatom.h>
#include <assert.h>
#include <algorithm> #include <algorithm>
#include "Util.hh" #include "Util.hh"

View file

@ -38,6 +38,8 @@ extern "C" {
#endif // HAVE_STRING_H #endif // HAVE_STRING_H
} }
#include <assert.h>
#include <functional> #include <functional>
#include <string> #include <string>
@ -506,26 +508,26 @@ bool Workspace::smartPlacement(Rect& win, const Rect& availableArea) {
if (screen->getPlacementPolicy() == BScreen::RowSmartPlacement) { if (screen->getPlacementPolicy() == BScreen::RowSmartPlacement) {
if(screen->getRowPlacementDirection() == BScreen::LeftRight) { if(screen->getRowPlacementDirection() == BScreen::LeftRight) {
if(screen->getColPlacementDirection() == BScreen::TopBottom) if(screen->getColPlacementDirection() == BScreen::TopBottom)
sort(spaces.begin(), spaces.end(), rowLRTB); std::sort(spaces.begin(), spaces.end(), rowLRTB);
else else
sort(spaces.begin(), spaces.end(), rowLRBT); std::sort(spaces.begin(), spaces.end(), rowLRBT);
} else { } else {
if(screen->getColPlacementDirection() == BScreen::TopBottom) if(screen->getColPlacementDirection() == BScreen::TopBottom)
sort(spaces.begin(), spaces.end(), rowRLTB); std::sort(spaces.begin(), spaces.end(), rowRLTB);
else else
sort(spaces.begin(), spaces.end(), rowRLBT); std::sort(spaces.begin(), spaces.end(), rowRLBT);
} }
} else { } else {
if(screen->getColPlacementDirection() == BScreen::TopBottom) { if(screen->getColPlacementDirection() == BScreen::TopBottom) {
if(screen->getRowPlacementDirection() == BScreen::LeftRight) if(screen->getRowPlacementDirection() == BScreen::LeftRight)
sort(spaces.begin(), spaces.end(), colLRTB); std::sort(spaces.begin(), spaces.end(), colLRTB);
else else
sort(spaces.begin(), spaces.end(), colRLTB); std::sort(spaces.begin(), spaces.end(), colRLTB);
} else { } else {
if(screen->getRowPlacementDirection() == BScreen::LeftRight) if(screen->getRowPlacementDirection() == BScreen::LeftRight)
sort(spaces.begin(), spaces.end(), colLRBT); std::sort(spaces.begin(), spaces.end(), colLRBT);
else else
sort(spaces.begin(), spaces.end(), colRLBT); std::sort(spaces.begin(), spaces.end(), colRLBT);
} }
} }

View file

@ -90,6 +90,8 @@ extern "C" {
#endif // HAVE_LIBGEN_H #endif // HAVE_LIBGEN_H
} }
#include <assert.h>
#include <algorithm> #include <algorithm>
#include <string> #include <string>
using std::string; using std::string;