all repos — fluxbox @ 06245dca91b460d6e6df80191477ac20f4f1dd21

custom fork of the fluxbox windowmanager

fixed enums
fluxgen fluxgen
commit

06245dca91b460d6e6df80191477ac20f4f1dd21

parent

17f438db1ee854bbc85e8d1e7f91ee28b501b7ab

3 files changed, 26 insertions(+), 28 deletions(-)

jump to
M src/Theme.ccsrc/Theme.cc

@@ -41,7 +41,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Theme.cc,v 1.13 2002/01/09 14:11:20 fluxgen Exp $ +// $Id: Theme.cc,v 1.14 2002/01/11 10:43:55 fluxgen Exp $ #ifndef _GNU_SOURCE #define _GNU_SOURCE

@@ -69,7 +69,6 @@ #include <string>

#include <iostream> using namespace std; - Theme::Theme(Display *display, Window rootwindow, Colormap colormap, int screennum, BImageControl *ic, const char *filename, const char *rootcommand): m_imagecontrol(ic),

@@ -78,7 +77,6 @@ m_colormap(colormap),

m_screennum(screennum), m_rootcommand(rootcommand==0 ? "" : rootcommand) //we dont want to send 0-pointer to std::string { - //default settings m_menustyle.titlefont.set = m_menustyle.framefont.set = m_toolbarstyle.font.set = m_windowstyle.font.set = m_windowstyle.tab.font.set = 0;

@@ -362,27 +360,27 @@ if (XrmGetResource(m_database, "menu.bullet", "Menu.Bullet",

&value_type, &value)) { if (! strncasecmp(value.addr, "empty", value.size)) - m_menustyle.bullet = Basemenu::Empty; + m_menustyle.bullet = Basemenu::EMPTY; else if (! strncasecmp(value.addr, "square", value.size)) - m_menustyle.bullet = Basemenu::Square; + m_menustyle.bullet = Basemenu::SQUARE; else if (! strncasecmp(value.addr, "diamond", value.size)) - m_menustyle.bullet = Basemenu::Diamond; + m_menustyle.bullet = Basemenu::DIAMOND; else - m_menustyle.bullet = Basemenu::Triangle; + m_menustyle.bullet = Basemenu::TRIANGLE; } else - m_menustyle.bullet = Basemenu::Triangle; + m_menustyle.bullet = Basemenu::TRIANGLE; if (XrmGetResource(m_database, "menu.bullet.position", "Menu.Bullet.Position", &value_type, &value)) { if (! strncasecmp(value.addr, "right", value.size)) - m_menustyle.bullet_pos = Basemenu::Right; + m_menustyle.bullet_pos = Basemenu::RIGHT; else - m_menustyle.bullet_pos = Basemenu::Left; + m_menustyle.bullet_pos = Basemenu::LEFT; } else - m_menustyle.bullet_pos = Basemenu::Left; + m_menustyle.bullet_pos = Basemenu::LEFT; //---------- font

@@ -669,6 +667,7 @@ displaystring.append(tmpstring); // append m_screennum

cerr<<__FILE__<<"("<<__LINE__<<"): displaystring="<<displaystring.c_str()<<endl; bexec(m_rootcommand.c_str(), const_cast<char *>(displaystring.c_str())); + #else // __EMX__ spawnlp(P_NOWAIT, "cmd.exe", "cmd.exe", "/c", m_rootcommand.c_str(), NULL); #endif // !__EMX__

@@ -687,12 +686,12 @@ string displaystring("DISPLAY=");

displaystring.append(DisplayString(m_display)); displaystring.append(tmpstring); // append m_screennum cerr<<__FILE__<<"("<<__LINE__<<"): displaystring="<<displaystring.c_str()<<endl; - + bexec(value.addr, const_cast<char *>(displaystring.c_str())); #else // __EMX__ spawnlp(P_NOWAIT, "cmd.exe", "cmd.exe", "/c", value.addr, NULL); #endif // !__EMX__ - + #ifdef DEBUG fprintf(stderr, "rootcommand:%s\n", value.addr); #endif

@@ -965,7 +964,6 @@ }

void Theme::reconfigure() { - //Window rootwindow = DefaultRootWindow(m_display); XGCValues gcv; unsigned long gc_value_mask = GCForeground; if (! I18n::instance()->multibyte())
M src/Window.hhsrc/Window.hh

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Window.hh,v 1.3 2002/01/09 14:11:20 fluxgen Exp $ +// $Id: Window.hh,v 1.4 2002/01/11 10:40:59 fluxgen Exp $ #ifndef _WINDOW_HH_ #define _WINDOW_HH_

@@ -257,7 +257,7 @@ button_w, button_h, grip_w, grip_h, mwm_border_w, border_h,

bevel_w, resize_w, resize_h, snap_w, snap_h; } frame; - enum { F_NoInput = 0, F_Passive, F_LocallyActive, F_GloballyActive }; + enum { F_NOINPUT = 0, F_PASSIVE, F_LOCALLYACTIVE, F_GLOBALLYACTIVE }; void createButton(int type, ButtonEventProc, ButtonEventProc, ButtonDrawProc); Window findTitleButton(int type);
M src/Workspace.ccsrc/Workspace.cc

@@ -355,27 +355,27 @@ toolbar_h = screen->getToolbar()->getHeight() +

(screen->getBorderWidth2x() * 2), place_x = 0, place_y = 0, change_x = 1, change_y = 1; - if (screen->getColPlacementDirection() == BScreen::BottomTop) + if (screen->getColPlacementDirection() == BScreen::BOTTOMTOP) change_y = -1; - if (screen->getRowPlacementDirection() == BScreen::RightLeft) + if (screen->getRowPlacementDirection() == BScreen::RIGHTLEFT) change_x = -1; register int test_x, test_y, curr_w, curr_h; switch (screen->getPlacementPolicy()) { - case BScreen::RowSmartPlacement: { + case BScreen::ROWSMARTPLACEMENT: { test_y = screen->getBorderWidth() + screen->getEdgeSnapThreshold(); - if (screen->getColPlacementDirection() == BScreen::BottomTop) + if (screen->getColPlacementDirection() == BScreen::BOTTOMTOP) test_y = screen->getHeight() - win_h - test_y; - while (((screen->getColPlacementDirection() == BScreen::BottomTop) ? + while (((screen->getColPlacementDirection() == BScreen::BOTTOMTOP) ? test_y > 0 : test_y + win_h < (signed) screen->getHeight()) && ! placed) { test_x = screen->getBorderWidth() + screen->getEdgeSnapThreshold(); - if (screen->getRowPlacementDirection() == BScreen::RightLeft) + if (screen->getRowPlacementDirection() == BScreen::RIGHTLEFT) test_x = screen->getWidth() - win_w - test_x; - while (((screen->getRowPlacementDirection() == BScreen::RightLeft) ? + while (((screen->getRowPlacementDirection() == BScreen::RIGHTLEFT) ? test_x > 0 : test_x + win_w < (signed) screen->getWidth()) && ! placed) { placed = True;

@@ -425,19 +425,19 @@ }

break; } - case BScreen::ColSmartPlacement: { + case BScreen::COLSMARTPLACEMENT: { test_x = screen->getBorderWidth() + screen->getEdgeSnapThreshold(); - if (screen->getRowPlacementDirection() == BScreen::RightLeft) + if (screen->getRowPlacementDirection() == BScreen::RIGHTLEFT) test_x = screen->getWidth() - win_w - test_x; - while (((screen->getRowPlacementDirection() == BScreen::RightLeft) ? + while (((screen->getRowPlacementDirection() == BScreen::RIGHTLEFT) ? test_x > 0 : test_x + win_w < (signed) screen->getWidth()) && ! placed) { test_y = screen->getBorderWidth() + screen->getEdgeSnapThreshold(); - if (screen->getColPlacementDirection() == BScreen::BottomTop) + if (screen->getColPlacementDirection() == BScreen::BOTTOMTOP) test_y = screen->getHeight() - win_h - test_y; - while (((screen->getColPlacementDirection() == BScreen::BottomTop) ? + while (((screen->getColPlacementDirection() == BScreen::BOTTOMTOP) ? test_y > 0 : test_y + win_h < (signed) screen->getHeight()) && ! placed) { placed = True;