summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Tiefenbruck <mark@fluxbox.org>2007-12-28 06:22:38 (GMT)
committerMark Tiefenbruck <mark@fluxbox.org>2007-12-28 06:22:38 (GMT)
commit0ec165e85b313588d43dbdc2450da9838c4c528f (patch)
treeaee798a6f8f108908e3e6932bef11b8eb564aa2a
parent32eb2a148ea7a257a058658af36e9f8c801a524a (diff)
downloadfluxbox_lack-0ec165e85b313588d43dbdc2450da9838c4c528f.zip
fluxbox_lack-0ec165e85b313588d43dbdc2450da9838c4c528f.tar.bz2
move STLUtil to FbTk
-rw-r--r--src/AttentionNoticeHandler.cc4
-rw-r--r--src/FbTk/Makefile.am2
-rw-r--r--src/FbTk/STLUtil.hh (renamed from src/STLUtil.hh)13
-rw-r--r--src/IconbarTool.cc4
-rw-r--r--src/Makefile.am1
-rw-r--r--src/Screen.cc5
6 files changed, 13 insertions, 16 deletions
diff --git a/src/AttentionNoticeHandler.cc b/src/AttentionNoticeHandler.cc
index 3f28695..a28c7fb 100644
--- a/src/AttentionNoticeHandler.cc
+++ b/src/AttentionNoticeHandler.cc
@@ -25,8 +25,8 @@
25 25
26#include "Window.hh" 26#include "Window.hh"
27#include "Screen.hh" 27#include "Screen.hh"
28#include "STLUtil.hh"
29 28
29#include "FbTk/STLUtil.hh"
30#include "FbTk/Subject.hh" 30#include "FbTk/Subject.hh"
31#include "FbTk/Timer.hh" 31#include "FbTk/Timer.hh"
32#include "FbTk/Resource.hh" 32#include "FbTk/Resource.hh"
@@ -50,7 +50,7 @@ private:
50 50
51 51
52AttentionNoticeHandler::~AttentionNoticeHandler() { 52AttentionNoticeHandler::~AttentionNoticeHandler() {
53 STLUtil::destroyAndClearSecond(m_attentions); 53 FbTk::STLUtil::destroyAndClearSecond(m_attentions);
54} 54}
55 55
56void AttentionNoticeHandler::addAttention(Focusable &client) { 56void AttentionNoticeHandler::addAttention(Focusable &client) {
diff --git a/src/FbTk/Makefile.am b/src/FbTk/Makefile.am
index 5f1c246..f5970fd 100644
--- a/src/FbTk/Makefile.am
+++ b/src/FbTk/Makefile.am
@@ -57,7 +57,7 @@ libFbTk_a_SOURCES = App.hh App.cc Color.cc Color.hh Command.hh \
57 MenuSeparator.hh MenuSeparator.cc \ 57 MenuSeparator.hh MenuSeparator.cc \
58 stringstream.hh \ 58 stringstream.hh \
59 TypeAhead.hh SearchResult.hh SearchResult.cc ITypeAheadable.hh \ 59 TypeAhead.hh SearchResult.hh SearchResult.cc ITypeAheadable.hh \
60 Select2nd.hh \ 60 Select2nd.hh STLUtil.hh \
61 CachedPixmap.hh CachedPixmap.cc \ 61 CachedPixmap.hh CachedPixmap.cc \
62 ${xpm_SOURCE} \ 62 ${xpm_SOURCE} \
63 ${xft_SOURCE} \ 63 ${xft_SOURCE} \
diff --git a/src/STLUtil.hh b/src/FbTk/STLUtil.hh
index a9b08e0..ec783d9 100644
--- a/src/STLUtil.hh
+++ b/src/FbTk/STLUtil.hh
@@ -1,4 +1,4 @@
1// STLUtil.cc for fluxbox 1// STLUtil.cc for FbTk
2// Copyright (c) 2006 Fluxbox Team (fluxgen at fluxbox dot org) 2// Copyright (c) 2006 Fluxbox Team (fluxgen at fluxbox dot org)
3// 3//
4// Permission is hereby granted, free of charge, to any person obtaining a 4// Permission is hereby granted, free of charge, to any person obtaining a
@@ -19,13 +19,11 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id$ 22#ifndef FBTK_STLUTIL_HH
23 23#define FBTK_STLUTIL_HH
24
25#ifndef STLUTIL_HH
26#define STLUTIL_HH
27 24
28/// contains useful utilities for STL 25/// contains useful utilities for STL
26namespace FbTk {
29namespace STLUtil { 27namespace STLUtil {
30 28
31/// calls delete on each item in the container and then clears the container 29/// calls delete on each item in the container and then clears the container
@@ -51,6 +49,7 @@ void destroyAndClearSecond(A &a) {
51 a.clear(); 49 a.clear();
52} 50}
53 51
54}; 52}; // end namespace STLUtil
53}; // end namespace FbTk
55 54
56#endif // STLUTIL_Hh 55#endif // STLUTIL_Hh
diff --git a/src/IconbarTool.cc b/src/IconbarTool.cc
index de56569..4275ec9 100644
--- a/src/IconbarTool.cc
+++ b/src/IconbarTool.cc
@@ -37,8 +37,8 @@
37#include "FocusControl.hh" 37#include "FocusControl.hh"
38#include "FbCommands.hh" 38#include "FbCommands.hh"
39#include "Layer.hh" 39#include "Layer.hh"
40#include "STLUtil.hh"
41 40
41#include "FbTk/STLUtil.hh"
42#include "FbTk/I18n.hh" 42#include "FbTk/I18n.hh"
43#include "FbTk/Menu.hh" 43#include "FbTk/Menu.hh"
44#include "FbTk/MenuItem.hh" 44#include "FbTk/MenuItem.hh"
@@ -523,7 +523,7 @@ void IconbarTool::renderButton(IconButton &button, bool clear) {
523 523
524void IconbarTool::deleteIcons() { 524void IconbarTool::deleteIcons() {
525 m_icon_container.removeAll(); 525 m_icon_container.removeAll();
526 STLUtil::destroyAndClearSecond(m_icons); 526 FbTk::STLUtil::destroyAndClearSecond(m_icons);
527} 527}
528 528
529void IconbarTool::removeWindow(Focusable &win) { 529void IconbarTool::removeWindow(Focusable &win) {
diff --git a/src/Makefile.am b/src/Makefile.am
index b40affd..312d52a 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -143,7 +143,6 @@ fluxbox_SOURCES = AtomHandler.hh ArrowButton.hh ArrowButton.cc \
143 AttentionNoticeHandler.hh AttentionNoticeHandler.cc \ 143 AttentionNoticeHandler.hh AttentionNoticeHandler.cc \
144 IconButton.hh IconButton.cc \ 144 IconButton.hh IconButton.cc \
145 IconbarTheme.hh IconbarTheme.cc \ 145 IconbarTheme.hh IconbarTheme.cc \
146 STLUtil.hh \
147 Focusable.hh FocusableList.hh FocusableList.cc \ 146 Focusable.hh FocusableList.hh FocusableList.cc \
148 ${newwmspec_SOURCE} ${gnome_SOURCE} \ 147 ${newwmspec_SOURCE} ${gnome_SOURCE} \
149 ${REMEMBER_SOURCE} ${TOOLBAR_SOURCE} 148 ${REMEMBER_SOURCE} ${TOOLBAR_SOURCE}
diff --git a/src/Screen.cc b/src/Screen.cc
index c304b7e..03d8fd2 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -37,8 +37,6 @@
37#include "FocusControl.hh" 37#include "FocusControl.hh"
38#include "ScreenPlacement.hh" 38#include "ScreenPlacement.hh"
39 39
40#include "STLUtil.hh"
41
42// themes 40// themes
43#include "FbWinFrameTheme.hh" 41#include "FbWinFrameTheme.hh"
44#include "MenuTheme.hh" 42#include "MenuTheme.hh"
@@ -79,6 +77,7 @@
79#include "FbTk/Select2nd.hh" 77#include "FbTk/Select2nd.hh"
80#include "FbTk/Compose.hh" 78#include "FbTk/Compose.hh"
81#include "FbTk/FbString.hh" 79#include "FbTk/FbString.hh"
80#include "FbTk/STLUtil.hh"
82 81
83//use GNU extensions 82//use GNU extensions
84#ifndef _GNU_SOURCE 83#ifndef _GNU_SOURCE
@@ -588,7 +587,7 @@ BScreen::~BScreen() {
588 imageControl().removeImage(pos_pixmap); 587 imageControl().removeImage(pos_pixmap);
589 588
590 removeWorkspaceNames(); 589 removeWorkspaceNames();
591 using namespace STLUtil; 590 using namespace FbTk::STLUtil;
592 destroyAndClear(m_workspaces_list); 591 destroyAndClear(m_workspaces_list);
593 destroyAndClear(m_managed_resources); 592 destroyAndClear(m_managed_resources);
594 593