all repos — fluxbox @ 18174570f3ca1227eb19c18982daa3897e0d7636

custom fork of the fluxbox windowmanager

cleaning in getNameOfWorkspace
fluxgen fluxgen
commit

18174570f3ca1227eb19c18982daa3897e0d7636

parent

c5e51485c6db0abe66578cacfe7c6e3d3f9c80a9

1 files changed, 6 insertions(+), 7 deletions(-)

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

@@ -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: Screen.cc,v 1.60 2002/08/04 15:48:13 fluxgen Exp $ +// $Id: Screen.cc,v 1.61 2002/08/11 22:28:18 fluxgen Exp $ //use GNU extensions #ifndef _GNU_SOURCE

@@ -1081,14 +1081,13 @@ workspaceNames.push_back(name);

} -void BScreen::getNameOfWorkspace(unsigned int workspace, char **name) { +string BScreen::getNameOfWorkspace(unsigned int workspace) const { if (workspace < workspaceNames.size()) { - const char *wkspc_name = workspaceNames[workspace].c_str(); + return workspaceNames[workspace]; + } else { + return ""; + } - if (wkspc_name) - *name = StringUtil::strdup(wkspc_name); - } else - *name = 0; }