aboutsummaryrefslogtreecommitdiff
path: root/src/Screen.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Screen.cc')
-rw-r--r--src/Screen.cc41
1 files changed, 9 insertions, 32 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index df272f2..d508c5c 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.185 2003/06/18 13:42:21 fluxgen Exp $ 25// $Id: Screen.cc,v 1.186 2003/06/20 01:30:08 fluxgen Exp $
26 26
27 27
28#include "Screen.hh" 28#include "Screen.hh"
@@ -464,7 +464,6 @@ BScreen::ScreenResource::ScreenResource(FbTk::ResourceManager &rm,
464 image_dither(rm, false, scrname+".imageDither", altscrname+".ImageDither"), 464 image_dither(rm, false, scrname+".imageDither", altscrname+".ImageDither"),
465 opaque_move(rm, false, "session.opaqueMove", "Session.OpaqueMove"), 465 opaque_move(rm, false, "session.opaqueMove", "Session.OpaqueMove"),
466 full_max(rm, true, scrname+".fullMaximization", altscrname+".FullMaximization"), 466 full_max(rm, true, scrname+".fullMaximization", altscrname+".FullMaximization"),
467 max_over_slit(rm, true, scrname+".maxOverSlit",altscrname+".MaxOverSlit"),
468 sloppy_window_grouping(rm, true, 467 sloppy_window_grouping(rm, true,
469 scrname+".sloppywindowgrouping", altscrname+".SloppyWindowGrouping"), 468 scrname+".sloppywindowgrouping", altscrname+".SloppyWindowGrouping"),
470 workspace_warping(rm, true, scrname+".workspacewarping", altscrname+".WorkspaceWarping"), 469 workspace_warping(rm, true, scrname+".workspacewarping", altscrname+".WorkspaceWarping"),
@@ -482,22 +481,13 @@ BScreen::ScreenResource::ScreenResource(FbTk::ResourceManager &rm,
482 scrname+".toolbar.widthPercent", altscrname+".Toolbar.WidthPercent"), 481 scrname+".toolbar.widthPercent", altscrname+".Toolbar.WidthPercent"),
483 edge_snap_threshold(rm, 0, scrname+".edgeSnapThreshold", altscrname+".EdgeSnapThreshold"), 482 edge_snap_threshold(rm, 0, scrname+".edgeSnapThreshold", altscrname+".EdgeSnapThreshold"),
484 menu_alpha(rm, 255, scrname+".menuAlpha", altscrname+".MenuAlpha"), 483 menu_alpha(rm, 255, scrname+".menuAlpha", altscrname+".MenuAlpha"),
485 slit_layernum(rm, Fluxbox::Layer(Fluxbox::instance()->getDockLayer()), 484
486 scrname+".slit.layer", altscrname+".Slit.Layer"),
487 toolbar_layernum(rm, Fluxbox::Layer(Fluxbox::instance()->getDesktopLayer()), 485 toolbar_layernum(rm, Fluxbox::Layer(Fluxbox::instance()->getDesktopLayer()),
488 scrname+".toolbar.layer", altscrname+".Toolbar.Layer"), 486 scrname+".toolbar.layer", altscrname+".Toolbar.Layer"),
489 toolbar_mode(rm, ToolbarHandler::ICONS, scrname+".toolbar.mode", altscrname+".Toolbar.Mode"), 487 toolbar_mode(rm, ToolbarHandler::ICONS, scrname+".toolbar.mode", altscrname+".Toolbar.Mode"),
490 toolbar_on_head(rm, 0, scrname+".toolbar.onhead", altscrname+".Toolbar.onHead"), 488 toolbar_on_head(rm, 0, scrname+".toolbar.onhead", altscrname+".Toolbar.onHead"),
491 toolbar_placement(rm, Toolbar::BOTTOMCENTER, 489 toolbar_placement(rm, Toolbar::BOTTOMCENTER,
492 scrname+".toolbar.placement", altscrname+".Toolbar.Placement"), 490 scrname+".toolbar.placement", altscrname+".Toolbar.Placement") {
493 slit_auto_hide(rm, false,
494 scrname+".slit.autoHide", altscrname+".Slit.AutoHide"),
495 slit_placement(rm, Slit::BOTTOMRIGHT,
496 scrname+".slit.placement", altscrname+".Slit.Placement"),
497 slit_direction(rm, Slit::VERTICAL,
498 scrname+".slit.direction", altscrname+".Slit.Direction"),
499 slit_alpha(rm, 255, scrname+".slit.alpha", altscrname+".Slit.Alpha"),
500 slit_on_head(rm, 0, scrname+".slit.onhead", altscrname+".Slit.onHead") {
501 491
502}; 492};
503 493
@@ -522,6 +512,9 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
522 *resource.rootcommand)), 512 *resource.rootcommand)),
523 m_root_window(scrn), 513 m_root_window(scrn),
524 resource(rm, screenname, altscreenname), 514 resource(rm, screenname, altscreenname),
515 m_name(screenname),
516 m_altname(altscreenname),
517 m_resource_manager(rm),
525 m_toolbarhandler(0), 518 m_toolbarhandler(0),
526 m_available_workspace_area(new Strut(0, 0, 0, 0)), 519 m_available_workspace_area(new Strut(0, 0, 0, 0)),
527 m_xinerama_headinfo(0) { 520 m_xinerama_headinfo(0) {
@@ -618,7 +611,7 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
618 m_current_workspace = m_workspaces_list.front(); 611 m_current_workspace = m_workspaces_list.front();
619 612
620#ifdef SLIT 613#ifdef SLIT
621 m_slit.reset(new Slit(*this, *layerManager().getLayer(getSlitLayerNum()), 614 m_slit.reset(new Slit(*this, *layerManager().getLayer(Fluxbox::instance()->getDesktopLayer()),
622 Fluxbox::instance()->getSlitlistFilename().c_str())); 615 Fluxbox::instance()->getSlitlistFilename().c_str()));
623#endif // SLIT 616#endif // SLIT
624 617
@@ -900,11 +893,8 @@ void BScreen::reconfigure() {
900 } 893 }
901 894
902#ifdef SLIT 895#ifdef SLIT
903 if (slit()) { 896 if (slit())
904 slit()->setPlacement(static_cast<Slit::Placement>(getSlitPlacement()));
905 slit()->setDirection(static_cast<Slit::Direction>(getSlitDirection()));
906 slit()->reconfigure(); 897 slit()->reconfigure();
907 }
908#endif // SLIT 898#endif // SLIT
909 899
910 //reconfigure workspaces 900 //reconfigure workspaces
@@ -2234,10 +2224,7 @@ void BScreen::setupConfigmenu(FbTk::Menu &menu) {
2234 BoolMenuItem(i18n->getMessage(ConfigmenuSet, ConfigmenuFocusLast, 2224 BoolMenuItem(i18n->getMessage(ConfigmenuSet, ConfigmenuFocusLast,
2235 "Focus Last Window on Workspace"), 2225 "Focus Last Window on Workspace"),
2236 *resource.focus_last, saverc_cmd)); 2226 *resource.focus_last, saverc_cmd));
2237 menu.insert(new 2227
2238 BoolMenuItem(i18n->getMessage(ConfigmenuSet, ConfigmenuMaxOverSlit,
2239 "Maximize Over Slit"),
2240 *resource.max_over_slit, saverc_cmd));
2241 menu.insert(new 2228 menu.insert(new
2242 BoolMenuItem(i18n->getMessage(ConfigmenuSet, ConfigmenuWorkspaceWarping, 2229 BoolMenuItem(i18n->getMessage(ConfigmenuSet, ConfigmenuWorkspaceWarping,
2243 "Workspace Warping"), 2230 "Workspace Warping"),
@@ -2689,13 +2676,3 @@ void BScreen::setOnHead<Toolbar>(Toolbar &tbar, int head) {
2689 tbar.reconfigure(); 2676 tbar.reconfigure();
2690} 2677}
2691 2678
2692template <>
2693int BScreen::getOnHead<Slit>(Slit &tbar) {
2694 return getSlitOnHead();
2695}
2696
2697template <>
2698void BScreen::setOnHead<Slit>(Slit &slit, int head) {
2699 saveSlitOnHead(head);
2700 slit.reconfigure();
2701}