From fa254cccd4f35b787dc1d75004d4d5a0a6b38105 Mon Sep 17 00:00:00 2001 From: fluxgen Date: Thu, 12 Jun 2003 14:30:01 +0000 Subject: getting workspace name directly in constructor --- src/Workspace.cc | 15 +++++++-------- src/Workspace.hh | 2 +- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/Workspace.cc b/src/Workspace.cc index 11a972b..dc60873 100644 --- a/src/Workspace.cc +++ b/src/Workspace.cc @@ -22,11 +22,11 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Workspace.cc,v 1.70 2003/06/05 13:21:10 rathnor Exp $ +// $Id: Workspace.cc,v 1.71 2003/06/12 14:30:00 fluxgen Exp $ #include "Workspace.hh" -#include "i18n.hh" +#include "I18n.hh" #include "fluxbox.hh" #include "Screen.hh" #include "Window.hh" @@ -113,24 +113,23 @@ private: Workspace::GroupList Workspace::m_groups; -Workspace::Workspace(BScreen &scrn, FbTk::MultLayers &layermanager, unsigned int i): +Workspace::Workspace(BScreen &scrn, FbTk::MultLayers &layermanager, + const std::string &name, unsigned int i): m_screen(scrn), m_lastfocus(0), m_clientmenu(*scrn.menuTheme(), scrn.screenNumber(), scrn.imageControl()), m_layermanager(layermanager), - m_name(""), + m_name(name), m_id(i) { - m_cascade_x = new int[scrn.numHeads()+1]; - m_cascade_y = new int[scrn.numHeads()+1]; + m_cascade_x = new int[scrn.numHeads() + 1]; + m_cascade_y = new int[scrn.numHeads() + 1]; for (int i=0; i < scrn.numHeads()+1; i++) { m_cascade_x[i] = 32 + scrn.getHeadX(i); m_cascade_y[i] = 32 + scrn.getHeadY(i); } m_clientmenu.setInternalMenu(); - setName(screen().getNameOfWorkspace(m_id)); - } diff --git a/src/Workspace.hh b/src/Workspace.hh index a8c6e8c..bca7e41 100644 --- a/src/Workspace.hh +++ b/src/Workspace.hh @@ -47,7 +47,7 @@ class Workspace:private FbTk::NotCopyable { public: typedef std::vector Windows; - Workspace(BScreen &screen, FbTk::MultLayers &layermanager, + Workspace(BScreen &screen, FbTk::MultLayers &layermanager, const std::string &name, unsigned int workspaceid = 0); ~Workspace(); -- cgit v0.11.2