From 72b878f78c0df0a54cf8e9f04bb2e22dd6715658 Mon Sep 17 00:00:00 2001
From: fluxgen <fluxgen>
Date: Tue, 16 Dec 2003 17:06:52 +0000
Subject: fixed some icc warnings

---
 src/FbTk/App.hh               |  2 +-
 src/FbTk/Button.hh            |  4 ++--
 src/FbTk/Color.hh             |  4 ++--
 src/FbTk/Command.hh           |  2 +-
 src/FbTk/Compose.hh           |  4 ++--
 src/FbTk/Directory.hh         |  4 ++--
 src/FbTk/EventHandler.hh      | 22 +++++++++++-----------
 src/FbTk/EventManager.hh      |  4 ++--
 src/FbTk/FbDrawable.hh        |  4 ++--
 src/FbTk/FbPixmap.hh          |  4 ++--
 src/FbTk/FbWindow.hh          |  4 ++--
 src/FbTk/Font.hh              |  4 ++--
 src/FbTk/GContext.hh          |  4 ++--
 src/FbTk/Image.cc             |  6 ++++--
 src/FbTk/Image.hh             |  4 ++--
 src/FbTk/ImageControl.hh      |  4 ++--
 src/FbTk/KeyUtil.hh           |  4 ++--
 src/FbTk/Layer.hh             |  4 ++--
 src/FbTk/LayerItem.hh         |  4 ++--
 src/FbTk/MacroCommand.hh      |  4 ++--
 src/FbTk/Menu.cc              | 12 ++++--------
 src/FbTk/Menu.hh              |  4 ++--
 src/FbTk/MenuItem.hh          |  4 ++--
 src/FbTk/MenuTheme.hh         |  4 ++--
 src/FbTk/NotCopyable.hh       |  3 ++-
 src/FbTk/Observer.hh          |  4 ++--
 src/FbTk/RefCount.hh          |  2 +-
 src/FbTk/Resource.hh          |  4 ++--
 src/FbTk/SignalHandler.hh     |  4 ++--
 src/FbTk/SimpleCommand.hh     |  2 +-
 src/FbTk/StringUtil.cc        |  3 ++-
 src/FbTk/StringUtil.hh        |  6 +++---
 src/FbTk/Subject.hh           |  4 ++--
 src/FbTk/Text.hh              |  4 ++--
 src/FbTk/TextBox.cc           |  6 ++----
 src/FbTk/TextButton.hh        |  4 ++--
 src/FbTk/Texture.hh           |  4 ++--
 src/FbTk/Theme.hh             |  6 +++---
 src/FbTk/Timer.hh             |  2 +-
 src/FbTk/XFontImp.hh          |  4 ++--
 src/FbTk/XLayer.hh            |  4 ++--
 src/FbTk/XLayerItem.hh        |  4 ++--
 src/FbTk/XftFontImp.hh        |  4 ++--
 src/FbTk/XmbFontImp.hh        |  4 ++--
 src/FbTk/XrmDatabaseHelper.hh | 18 +++++++++---------
 45 files changed, 107 insertions(+), 109 deletions(-)

diff --git a/src/FbTk/App.hh b/src/FbTk/App.hh
index 4bcffed..53dc42a 100644
--- a/src/FbTk/App.hh
+++ b/src/FbTk/App.hh
@@ -59,6 +59,6 @@ private:
     Display *m_display;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_APP_HH
diff --git a/src/FbTk/Button.hh b/src/FbTk/Button.hh
index dbbdeda..9df0bcd 100644
--- a/src/FbTk/Button.hh
+++ b/src/FbTk/Button.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Button.hh,v 1.7 2003/10/13 23:43:11 fluxgen Exp $
+// $Id: Button.hh,v 1.8 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_BUTTON_HH
 #define FBTK_BUTTON_HH
@@ -85,6 +85,6 @@ private:
     RefCount<Command> m_onclick[5]; ///< what to do when this button is clicked with button num
 };
 
-};
+} // namespace FbTk
 
 #endif // FBTK_BUTTON_HH
diff --git a/src/FbTk/Color.hh b/src/FbTk/Color.hh
index b699dcc..1ab926b 100644
--- a/src/FbTk/Color.hh
+++ b/src/FbTk/Color.hh
@@ -22,7 +22,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Color.hh,v 1.5 2003/10/09 16:48:09 rathnor Exp $
+// $Id: Color.hh,v 1.6 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_COLOR_HH
 #define FBTK_COLOR_HH
@@ -70,6 +70,6 @@ private:
     int m_screen;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_COLOR_HH
diff --git a/src/FbTk/Command.hh b/src/FbTk/Command.hh
index 2f917a5..4a20add 100644
--- a/src/FbTk/Command.hh
+++ b/src/FbTk/Command.hh
@@ -31,6 +31,6 @@ public:
     virtual void execute() = 0;
 };
 
-};
+} // end namespace FbTk
 
 #endif // FBTK_COMMAND_HH
diff --git a/src/FbTk/Compose.hh b/src/FbTk/Compose.hh
index 697023c..91d1665 100644
--- a/src/FbTk/Compose.hh
+++ b/src/FbTk/Compose.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Compose.hh,v 1.1 2003/08/24 10:37:31 fluxgen Exp $
+// $Id: Compose.hh,v 1.2 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_COMPOSE_HH
 #define FBTK_COMPOSE_HH
@@ -55,6 +55,6 @@ Compose(const A& a, const B& b) {
     return Compose_base<A, B>(a, b);
 }
 
-}; // namespace FbTk
+} // namespace FbTk
 
 #endif // FBTK_COMPOSE_HH
diff --git a/src/FbTk/Directory.hh b/src/FbTk/Directory.hh
index 7862a51..8d3a42d 100644
--- a/src/FbTk/Directory.hh
+++ b/src/FbTk/Directory.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Directory.hh,v 1.2 2003/08/17 13:19:54 fluxgen Exp $
+// $Id: Directory.hh,v 1.3 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_DIRECTORY_HH
 #define FBTK_DIRECTORY_HH
@@ -60,6 +60,6 @@ private:
     size_t m_num_entries; ///< number of file entries in directory
 };
 
-};
+} // end namespace FbTk
 
 #endif // FBTK_DIRECTORY_HH
diff --git a/src/FbTk/EventHandler.hh b/src/FbTk/EventHandler.hh
index 6e60cc2..c2263be 100644
--- a/src/FbTk/EventHandler.hh
+++ b/src/FbTk/EventHandler.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: EventHandler.hh,v 1.5 2003/05/10 23:14:22 fluxgen Exp $
+// $Id: EventHandler.hh,v 1.6 2003/12/16 17:06:49 fluxgen Exp $
 
 /// @file holds EventHandler interface for X events
 
@@ -48,17 +48,17 @@ public:
     /**
        Events that don't have an specific event function
     */
-    virtual void handleEvent(XEvent &ev) { }
-    virtual void buttonPressEvent(XButtonEvent &ev) { }
-    virtual void buttonReleaseEvent(XButtonEvent &ev) { }
-    virtual void exposeEvent(XExposeEvent &ev) { }
-    virtual void motionNotifyEvent(XMotionEvent &ev) { }
-    virtual void keyPressEvent(XKeyEvent &ev) { }
-    virtual void keyReleaseEvent(XKeyEvent &ev) { }
-    virtual void leaveNotifyEvent(XCrossingEvent &ev) { }
-    virtual void enterNotifyEvent(XCrossingEvent &ev) { }
+    virtual void handleEvent(XEvent &) { }
+    virtual void buttonPressEvent(XButtonEvent &) { }
+    virtual void buttonReleaseEvent(XButtonEvent &) { }
+    virtual void exposeEvent(XExposeEvent &) { }
+    virtual void motionNotifyEvent(XMotionEvent &) { }
+    virtual void keyPressEvent(XKeyEvent &) { }
+    virtual void keyReleaseEvent(XKeyEvent &) { }
+    virtual void leaveNotifyEvent(XCrossingEvent &) { }
+    virtual void enterNotifyEvent(XCrossingEvent &) { }
 };
 
-};
+} // end namespace FbTk
 
 #endif // FBTK_EVENTHANDLER_HH
diff --git a/src/FbTk/EventManager.hh b/src/FbTk/EventManager.hh
index 1ad401e..4b693ff 100644
--- a/src/FbTk/EventManager.hh
+++ b/src/FbTk/EventManager.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: EventManager.hh,v 1.6 2003/10/14 16:23:16 rathnor Exp $
+// $Id: EventManager.hh,v 1.7 2003/12/16 17:06:49 fluxgen Exp $
 
 #include "EventHandler.hh"
 #include <map>
@@ -57,4 +57,4 @@ private:
     std::map<Window, EventHandler *> m_parent;
 };
 
-}; //end namespace FbTk
+} //end namespace FbTk
diff --git a/src/FbTk/FbDrawable.hh b/src/FbTk/FbDrawable.hh
index 30c7371..06c7a9d 100644
--- a/src/FbTk/FbDrawable.hh
+++ b/src/FbTk/FbDrawable.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: FbDrawable.hh,v 1.3 2003/09/06 15:39:06 fluxgen Exp $
+// $Id: FbDrawable.hh,v 1.4 2003/12/16 17:06:49 fluxgen Exp $
 #ifndef FBTK_FBDRAWABLE_HH
 #define FBTK_FBDRAWABLE_HH
 
@@ -57,6 +57,6 @@ public:
     virtual unsigned int height() const = 0;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_FBDRAWABLE_HH
diff --git a/src/FbTk/FbPixmap.hh b/src/FbTk/FbPixmap.hh
index b922adc..2baccf8 100644
--- a/src/FbTk/FbPixmap.hh
+++ b/src/FbTk/FbPixmap.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: FbPixmap.hh,v 1.7 2003/09/10 21:28:13 fluxgen Exp $
+// $Id: FbPixmap.hh,v 1.8 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_FBPIXMAP_HH
 #define FBTK_FBPIXMAP_HH
@@ -74,7 +74,7 @@ private:
     unsigned int m_width, m_height;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_FBPIXMAP_HH
 
diff --git a/src/FbTk/FbWindow.hh b/src/FbTk/FbWindow.hh
index dd80b7f..60acec4 100644
--- a/src/FbTk/FbWindow.hh
+++ b/src/FbTk/FbWindow.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: FbWindow.hh,v 1.25 2003/09/14 09:51:40 fluxgen Exp $
+// $Id: FbWindow.hh,v 1.26 2003/12/16 17:06:49 fluxgen Exp $
 
 #ifndef FBTK_FBWINDOW_HH
 #define FBTK_FBWINDOW_HH
@@ -191,6 +191,6 @@ private:
 
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_FBWINDOW_HH
diff --git a/src/FbTk/Font.hh b/src/FbTk/Font.hh
index 4a2c4cb..2ddb7fa 100644
--- a/src/FbTk/Font.hh
+++ b/src/FbTk/Font.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-//$Id: Font.hh,v 1.5 2003/11/28 23:27:29 fluxgen Exp $
+//$Id: Font.hh,v 1.6 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_FONT_HH
 #define FBTK_FONT_HH
@@ -100,6 +100,6 @@ private:
     bool m_shadow; ///< shadow text
 };
 
-}; //end namespace FbTk
+} //end namespace FbTk
 
 #endif //FBTK_FONT_HH
diff --git a/src/FbTk/GContext.hh b/src/FbTk/GContext.hh
index 3f01b8c..94aec3e 100644
--- a/src/FbTk/GContext.hh
+++ b/src/FbTk/GContext.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: GContext.hh,v 1.5 2003/11/28 22:50:55 fluxgen Exp $
+// $Id: GContext.hh,v 1.6 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_GCONTEXT_HH
 #define FBTK_GCONTEXT_HH
@@ -62,7 +62,7 @@ public:
     }
 
     /// not implemented
-    inline void setFont(const FbTk::Font &font) {}
+    inline void setFont(const FbTk::Font &) {}
 
     /// set font id
     inline void setFont(int fid) {
diff --git a/src/FbTk/Image.cc b/src/FbTk/Image.cc
index f5ffc24..98b602c 100644
--- a/src/FbTk/Image.cc
+++ b/src/FbTk/Image.cc
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Image.cc,v 1.2 2003/11/16 22:33:55 rathnor Exp $
+// $Id: Image.cc,v 1.3 2003/12/16 17:06:51 fluxgen Exp $
 
 #include "Image.hh"
 #include "StringUtil.hh"
@@ -87,10 +87,12 @@ bool Image::registerType(const std::string &type, ImageBase &base) {
         s_image_map[ucase_type] != &base) 
         return false;
     // already registered?
-    if (s_image_map[ucase_type] = &base)
+    if (s_image_map[ucase_type] == &base)
         return true;
 
     s_image_map[ucase_type] = &base;
+
+    return true;
 }
 
 void Image::remove(ImageBase &base) {
diff --git a/src/FbTk/Image.hh b/src/FbTk/Image.hh
index 1dc3f1b..49c9340 100644
--- a/src/FbTk/Image.hh
+++ b/src/FbTk/Image.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Image.hh,v 1.2 2003/11/16 22:33:55 rathnor Exp $
+// $Id: Image.hh,v 1.3 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_IMAGE_HH
 #define FBTK_IMAGE_HH
@@ -65,7 +65,7 @@ public:
     virtual PixmapWithMask *load(const std::string &name, int screen_num) const = 0;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // IMAGE_HH
 
diff --git a/src/FbTk/ImageControl.hh b/src/FbTk/ImageControl.hh
index 29c43d6..2354fe0 100644
--- a/src/FbTk/ImageControl.hh
+++ b/src/FbTk/ImageControl.hh
@@ -22,7 +22,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: ImageControl.hh,v 1.5 2003/10/09 16:48:09 rathnor Exp $
+// $Id: ImageControl.hh,v 1.6 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef	 FBTK_IMAGECONTROL_HH
 #define	 FBTK_IMAGECONTROL_HH
@@ -139,7 +139,7 @@ private:
     static bool s_timed_cache;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_IMAGECONTROL_HH
 
diff --git a/src/FbTk/KeyUtil.hh b/src/FbTk/KeyUtil.hh
index 019fbc5..d1f1706 100644
--- a/src/FbTk/KeyUtil.hh
+++ b/src/FbTk/KeyUtil.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: KeyUtil.hh,v 1.3 2003/10/13 19:31:56 fluxgen Exp $
+// $Id: KeyUtil.hh,v 1.4 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_KEYUTIL_HH
 #define FBTK_KEYUTIL_HH
@@ -54,7 +54,7 @@ public:
     /**
        @return the modifier for the modstr else zero on failure.
     */
-    static unsigned int KeyUtil::getModifier(const char *modstr);
+    static unsigned int getModifier(const char *modstr);
 
     /**
        ungrabs all keys
diff --git a/src/FbTk/Layer.hh b/src/FbTk/Layer.hh
index f974918..a057610 100644
--- a/src/FbTk/Layer.hh
+++ b/src/FbTk/Layer.hh
@@ -20,7 +20,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Layer.hh,v 1.1 2003/01/16 12:41:27 rathnor Exp $
+// $Id: Layer.hh,v 1.2 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_LAYERTEMPLATE_HH
 #define FBTK_LAYERTEMPLATE_HH
@@ -195,7 +195,7 @@ void Layer<ItemType, Container>::restack() {
 }
 
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 
 #endif // FBTK_LAYERTEMPLATE_HH
diff --git a/src/FbTk/LayerItem.hh b/src/FbTk/LayerItem.hh
index 372cdea..09dda0d 100644
--- a/src/FbTk/LayerItem.hh
+++ b/src/FbTk/LayerItem.hh
@@ -20,7 +20,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: LayerItem.hh,v 1.1 2003/01/16 12:41:27 rathnor Exp $
+// $Id: LayerItem.hh,v 1.2 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_LAYERITEM_HH
 #define FBTK_LAYERITEM_HH
@@ -38,6 +38,6 @@ public:
     virtual void stepDown() = 0;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_LAYERITEM_HH
diff --git a/src/FbTk/MacroCommand.hh b/src/FbTk/MacroCommand.hh
index a75f98a..f710e8a 100644
--- a/src/FbTk/MacroCommand.hh
+++ b/src/FbTk/MacroCommand.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: MacroCommand.hh,v 1.2 2003/09/29 14:00:45 fluxgen Exp $
+// $Id: MacroCommand.hh,v 1.3 2003/12/16 17:06:51 fluxgen Exp $
 
 #ifndef FBTK_MACROCOMMAND_HH
 #define FBTK_MACROCOMMAND_HH
@@ -42,6 +42,6 @@ private:
     std::vector<RefCount<Command> > m_commandlist;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_MACROCOMMAND_HH
diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc
index 7bc6030..2ef5793 100644
--- a/src/FbTk/Menu.cc
+++ b/src/FbTk/Menu.cc
@@ -22,7 +22,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Menu.cc,v 1.48 2003/12/12 21:47:36 fluxgen Exp $
+// $Id: Menu.cc,v 1.49 2003/12/16 17:06:51 fluxgen Exp $
 
 //use GNU extensions
 #ifndef	 _GNU_SOURCE
@@ -404,10 +404,8 @@ void Menu::update(int active_index) {
         menu.persub = 0;
     }
 
-    menu.frame_h = (menu.item_h * menu.persub);
-    if (menu.frame_h < 0)
-        menu.frame_h = 0;
-
+    int itmp = (menu.item_h * menu.persub);
+    menu.frame_h = itmp < 0 ? 0 : itmp;
 
     int new_width = (menu.sublevels * menu.item_w);
     int new_height = menu.frame_h;
@@ -1229,7 +1227,7 @@ void Menu::exposeEvent(XExposeEvent &ee) {
         for (i = sbl; i <= sbl_d; i++) {
             // set the iterator to the first item in the sublevel needing redrawing
             unsigned int index = id + i * menu.persub;
-            if (index < static_cast<int>(menuitems.size()) && index >= 0) {
+            if (index < static_cast<int>(menuitems.size())) {
                 Menuitems::iterator it = menuitems.begin() + index;
                 Menuitems::iterator it_end = menuitems.end();
                 for (ii = id; ii <= id_d && it != it_end; ++it, ii++) {
@@ -1351,8 +1349,6 @@ void Menu::reconfigure() {
 
     if (menu.bevel_w > 10) // clamp to "normal" size
         menu.bevel_w = 10;
-    if (menu.bevel_w < 0)
-        menu.bevel_w = 1;
 
     if (m_border_width > 20) // clamp to normal size
         m_border_width = 20;
diff --git a/src/FbTk/Menu.hh b/src/FbTk/Menu.hh
index ec75477..600ecb6 100644
--- a/src/FbTk/Menu.hh
+++ b/src/FbTk/Menu.hh
@@ -22,7 +22,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Menu.hh,v 1.26 2003/12/12 18:18:49 fluxgen Exp $
+// $Id: Menu.hh,v 1.27 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef	 FBTK_MENU_HH
 #define	 FBTK_MENU_HH
@@ -225,6 +225,6 @@ private:
     Timer m_hide_timer;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_MENU_HH
diff --git a/src/FbTk/MenuItem.hh b/src/FbTk/MenuItem.hh
index 712b480..6aeb40c 100644
--- a/src/FbTk/MenuItem.hh
+++ b/src/FbTk/MenuItem.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: MenuItem.hh,v 1.3 2003/08/27 14:18:02 fluxgen Exp $
+// $Id: MenuItem.hh,v 1.4 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_MENUITEM_HH
 #define FBTK_MENUITEM_HH
@@ -96,6 +96,6 @@ private:
     bool m_toggle_item;
 };
 
-};// end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_MENUITEM_HH
diff --git a/src/FbTk/MenuTheme.hh b/src/FbTk/MenuTheme.hh
index 07c29ad..951ab55 100644
--- a/src/FbTk/MenuTheme.hh
+++ b/src/FbTk/MenuTheme.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: MenuTheme.hh,v 1.11 2003/12/12 18:18:49 fluxgen Exp $
+// $Id: MenuTheme.hh,v 1.12 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_MENUTHEME_HH
 #define FBTK_MENUTHEME_HH
@@ -146,6 +146,6 @@ private:
     
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_MENUTHEME_HH
diff --git a/src/FbTk/NotCopyable.hh b/src/FbTk/NotCopyable.hh
index 8310762..50919e4 100644
--- a/src/FbTk/NotCopyable.hh
+++ b/src/FbTk/NotCopyable.hh
@@ -32,11 +32,12 @@ class NotCopyable
 {
 protected:
     NotCopyable() {}
+    virtual ~NotCopyable() { }
 private:
     NotCopyable(const NotCopyable &rhs); // copy constructor
     NotCopyable &operator=(const NotCopyable &rhs); // assignment operator
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif //FBTK_NOTCOPYABLE_HH
diff --git a/src/FbTk/Observer.hh b/src/FbTk/Observer.hh
index bc5a3ce..54b7a70 100644
--- a/src/FbTk/Observer.hh
+++ b/src/FbTk/Observer.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Observer.hh,v 1.1 2003/02/15 01:21:40 fluxgen Exp $
+// $Id: Observer.hh,v 1.2 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_OBSERVER_HH
 #define FBTK_OBSERVER_HH
@@ -34,6 +34,6 @@ public:
     virtual void update(Subject *changedSubj) = 0;
 };
 
-}; // end namespace FBTK
+} // end namespace FBTK
 
 #endif // FBTK_OBSERVER_HH
diff --git a/src/FbTk/RefCount.hh b/src/FbTk/RefCount.hh
index 737ee1b..837bfd2 100644
--- a/src/FbTk/RefCount.hh
+++ b/src/FbTk/RefCount.hh
@@ -124,6 +124,6 @@ void RefCount<Pointer>::incRefCount() {
     (*m_refcount)++;
 }
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_REFCOUNT_HH
diff --git a/src/FbTk/Resource.hh b/src/FbTk/Resource.hh
index b1cca9a..06d4b67 100644
--- a/src/FbTk/Resource.hh
+++ b/src/FbTk/Resource.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Resource.hh,v 1.4 2003/09/13 09:29:26 fluxgen Exp $
+// $Id: Resource.hh,v 1.5 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_RESOURCE_HH
 #define FBTK_RESOURCE_HH
@@ -196,6 +196,6 @@ void ResourceManager::addResource(Resource<T> &r) {
 }
 	
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_RESOURCE_HH
diff --git a/src/FbTk/SignalHandler.hh b/src/FbTk/SignalHandler.hh
index c9deeb9..2de80a9 100644
--- a/src/FbTk/SignalHandler.hh
+++ b/src/FbTk/SignalHandler.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: SignalHandler.hh,v 1.5 2003/05/13 11:41:29 fluxgen Exp $
+// $Id: SignalHandler.hh,v 1.6 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_SIGNALHANDLER_HH
 #define FBTK_SIGNALHANDLER_HH
@@ -66,6 +66,6 @@ private:
     static SignalEventHandler *s_signal_handler[NSIG]; ///< NSIG defined in signal.h
 }; 
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_SIGNALHANDLER_HH
diff --git a/src/FbTk/SimpleCommand.hh b/src/FbTk/SimpleCommand.hh
index 0ed864b..04add98 100644
--- a/src/FbTk/SimpleCommand.hh
+++ b/src/FbTk/SimpleCommand.hh
@@ -39,6 +39,6 @@ private:
     Action m_action;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_SIMPLECOMMAND_HH
diff --git a/src/FbTk/StringUtil.cc b/src/FbTk/StringUtil.cc
index f7c14ce..4d282ad 100644
--- a/src/FbTk/StringUtil.cc
+++ b/src/FbTk/StringUtil.cc
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-//�$Id: StringUtil.cc,v 1.8 2003/10/25 22:06:53 fluxgen Exp $
+//�$Id: StringUtil.cc,v 1.9 2003/12/16 17:06:52 fluxgen Exp $
 
 #include "StringUtil.hh"
 
@@ -196,6 +196,7 @@ string::size_type removeTrailingWhitespace(std::string &str) {
             last_pos = str.find_first_of(" \t", last_pos);
         }
     }
+    return first_pos;
 }
 
 }; // end namespace StringUtil
diff --git a/src/FbTk/StringUtil.hh b/src/FbTk/StringUtil.hh
index d7c191c..5d6179d 100644
--- a/src/FbTk/StringUtil.hh
+++ b/src/FbTk/StringUtil.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-//$Id: StringUtil.hh,v 1.7 2003/10/25 22:06:53 fluxgen Exp $
+//$Id: StringUtil.hh,v 1.8 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_STRINGUTIL_HH
 #define FBTK_STRINGUTIL_HH
@@ -89,9 +89,9 @@ stringtok (Container &container, std::string const &in,
     }
 }
 
-}; // end namespace StringUtil
+} // end namespace StringUtil
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 
 #endif // FBTK_STRINGUTIL_HH
diff --git a/src/FbTk/Subject.hh b/src/FbTk/Subject.hh
index 000fc2e..54bf533 100644
--- a/src/FbTk/Subject.hh
+++ b/src/FbTk/Subject.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Subject.hh,v 1.4 2003/09/08 15:38:46 fluxgen Exp $
+// $Id: Subject.hh,v 1.5 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_SUBJECT_HH
 #define FBTK_SUBJECT_HH
@@ -54,6 +54,6 @@ private:
     static SubjectList s_subjectlist;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_SUBJECT_HH
diff --git a/src/FbTk/Text.hh b/src/FbTk/Text.hh
index 50c3282..0abe4ed 100644
--- a/src/FbTk/Text.hh
+++ b/src/FbTk/Text.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Text.hh,v 1.2 2003/08/11 14:59:40 fluxgen Exp $
+// $Id: Text.hh,v 1.3 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_TEXT_HH
 #define FBTK_TEXT_HH
@@ -36,6 +36,6 @@ int doAlignment(int max_width, int bevel, FbTk::Justify justify,
                 const FbTk::Font &font, const char * const text, 
                 unsigned int textlen, unsigned int &newlen);
 
-};
+} // end namespace FbTk
 
 #endif // FBTK_TEXT_HH
diff --git a/src/FbTk/TextBox.cc b/src/FbTk/TextBox.cc
index 519b56e..1eec4eb 100644
--- a/src/FbTk/TextBox.cc
+++ b/src/FbTk/TextBox.cc
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: TextBox.cc,v 1.3 2003/10/05 07:20:47 rathnor Exp $
+// $Id: TextBox.cc,v 1.4 2003/12/16 17:06:52 fluxgen Exp $
 
 #include "TextBox.hh"
 #include "Font.hh"
@@ -254,11 +254,9 @@ void TextBox::keyPressEvent(XKeyEvent &event) {
 }
 
 void TextBox::setCursorPosition(int pos) {
-    m_cursor_pos = pos;
+    m_cursor_pos = pos < 0 ? 0 : pos;
     if (m_cursor_pos > text().size())
         cursorEnd();
-    else if (m_cursor_pos < 0)
-        cursorHome();
 }
 
 void TextBox::adjustEndPos() {
diff --git a/src/FbTk/TextButton.hh b/src/FbTk/TextButton.hh
index 246461b..9ccae40 100644
--- a/src/FbTk/TextButton.hh
+++ b/src/FbTk/TextButton.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: TextButton.hh,v 1.3 2003/09/14 09:50:01 fluxgen Exp $
+// $Id: TextButton.hh,v 1.4 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_TEXTBUTTON_HH
 #define FBTK_TEXTBUTTON_HH
@@ -75,6 +75,6 @@ private:
     int m_bevel;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_TEXTBUTTON_HH
diff --git a/src/FbTk/Texture.hh b/src/FbTk/Texture.hh
index b7add3f..336086a 100644
--- a/src/FbTk/Texture.hh
+++ b/src/FbTk/Texture.hh
@@ -22,7 +22,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Texture.hh,v 1.5 2003/12/07 16:32:12 fluxgen Exp $
+// $Id: Texture.hh,v 1.6 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_TEXTURE_HH
 #define FBTK_TEXTURE_HH
@@ -97,6 +97,6 @@ private:
     unsigned long m_type;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_TEXTURE_HH
diff --git a/src/FbTk/Theme.hh b/src/FbTk/Theme.hh
index bea4680..e5c0394 100644
--- a/src/FbTk/Theme.hh
+++ b/src/FbTk/Theme.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: Theme.hh,v 1.11 2003/11/16 22:33:56 rathnor Exp $
+// $Id: Theme.hh,v 1.12 2003/12/16 17:06:52 fluxgen Exp $
 
 /**
  @file holds ThemeItem<T>, Theme and ThemeManager which is the base for any theme
@@ -104,7 +104,7 @@ public:
     /// remove ThemeItem
     template <typename T>
     void remove(ThemeItem<T> &item);
-    virtual bool fallback(ThemeItem_base &base) { return false; }
+    virtual bool fallback(ThemeItem_base &) { return false; }
     FbTk::Subject &reconfigSig() { return m_reconfig_sig; }
 
     
@@ -180,7 +180,7 @@ void Theme::remove(ThemeItem<T> &item)  {
     m_themeitems.remove(&item);
 }
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_THEME_HH
 
diff --git a/src/FbTk/Timer.hh b/src/FbTk/Timer.hh
index 5949b73..eb6f02a 100644
--- a/src/FbTk/Timer.hh
+++ b/src/FbTk/Timer.hh
@@ -99,7 +99,7 @@ private:
 
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_TIMER_HH
 
diff --git a/src/FbTk/XFontImp.hh b/src/FbTk/XFontImp.hh
index c297615..cc03034 100644
--- a/src/FbTk/XFontImp.hh
+++ b/src/FbTk/XFontImp.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: XFontImp.hh,v 1.4 2003/01/05 23:39:50 fluxgen Exp $
+// $Id: XFontImp.hh,v 1.5 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_XFONTIMP_HH
 #define FBTK_XFONTIMP_HH
@@ -83,6 +83,6 @@ private:
     bool m_rotate; ///< used to disable/enable rotation temprarly without reallocating m_rotfont
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // XFONTIMP_HH
diff --git a/src/FbTk/XLayer.hh b/src/FbTk/XLayer.hh
index 82bee5e..442f288 100644
--- a/src/FbTk/XLayer.hh
+++ b/src/FbTk/XLayer.hh
@@ -20,7 +20,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: XLayer.hh,v 1.4 2003/04/15 23:09:25 rathnor Exp $
+// $Id: XLayer.hh,v 1.5 2003/12/16 17:06:52 fluxgen Exp $
 
 
 #ifndef FBTK_XLAYER_HH
@@ -86,6 +86,6 @@ private:
 
 };
 
-};
+} // namespace FbTk
 
 #endif // FBTK_XLAYER_HH
diff --git a/src/FbTk/XLayerItem.hh b/src/FbTk/XLayerItem.hh
index bf53aa6..1ea355a 100644
--- a/src/FbTk/XLayerItem.hh
+++ b/src/FbTk/XLayerItem.hh
@@ -20,7 +20,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: XLayerItem.hh,v 1.7 2003/04/15 23:09:26 rathnor Exp $
+// $Id: XLayerItem.hh,v 1.8 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_XLAYERITEM_HH
 #define FBTK_XLAYERITEM_HH
@@ -83,6 +83,6 @@ private:
     Windows m_windows;
 };
 
-};
+}
 
 #endif // FBTK_XLAYERITEM_HH
diff --git a/src/FbTk/XftFontImp.hh b/src/FbTk/XftFontImp.hh
index ee13fe1..a29ad41 100644
--- a/src/FbTk/XftFontImp.hh
+++ b/src/FbTk/XftFontImp.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-//$Id: XftFontImp.hh,v 1.3 2003/01/05 23:39:49 fluxgen Exp $
+//$Id: XftFontImp.hh,v 1.4 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_XFTFONTIMP_HH
 #define FBTK_XFTFONTIMP_HH
@@ -47,6 +47,6 @@ private:
     bool m_utf8mode;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_XFTFONTIMP_HH
diff --git a/src/FbTk/XmbFontImp.hh b/src/FbTk/XmbFontImp.hh
index 9f58385..55383e9 100644
--- a/src/FbTk/XmbFontImp.hh
+++ b/src/FbTk/XmbFontImp.hh
@@ -19,7 +19,7 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: XmbFontImp.hh,v 1.3 2003/01/05 23:39:50 fluxgen Exp $
+// $Id: XmbFontImp.hh,v 1.4 2003/12/16 17:06:52 fluxgen Exp $
 
 #ifndef FBTK_XMBFONTIMP_HH
 #define FBTK_XMBFONTIMP_HH
@@ -48,6 +48,6 @@ private:
     const bool m_utf8mode;
 };
 
-}; // end namespace FbTk
+} // end namespace FbTk
 
 #endif // FBTK_XMBFONTIMP_HH
diff --git a/src/FbTk/XrmDatabaseHelper.hh b/src/FbTk/XrmDatabaseHelper.hh
index 3388c7b..3273d41 100644
--- a/src/FbTk/XrmDatabaseHelper.hh
+++ b/src/FbTk/XrmDatabaseHelper.hh
@@ -19,20 +19,19 @@
 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 // DEALINGS IN THE SOFTWARE.
 
-// $Id: XrmDatabaseHelper.hh,v 1.2 2003/07/18 15:40:55 rathnor Exp $
+// $Id: XrmDatabaseHelper.hh,v 1.3 2003/12/16 17:06:52 fluxgen Exp $
 
-// This is a helper for XrmDatabase
-// when database goes out of scope
-// the XrmDatabase variable will be destroyed.
 
-#ifndef XRMDATABASEHELPER_HH
-#define XRMDATABASEHELPER_HH
+#ifndef FBTK_XRMDATABASEHELPER_HH
+#define FBTK_XRMDATABASEHELPER_HH
 
 #include <X11/Xlib.h>
 #include <X11/Xresource.h>
 
 /**
-	Helper class for XrmDatabase.
+  This is a helper for XrmDatabase
+  when database goes out of scope
+  the XrmDatabase variable will be destroyed.
 */
 namespace FbTk {
 
@@ -77,5 +76,6 @@ private:
     XrmDatabase m_database;	
 };
 
-}; // namespace FbTk
-#endif //_XRMDATABASEHELPER_HH_
+} // namespace FbTk
+
+#endif // FBTK_XRMDATABASEHELPER_HH
-- 
cgit v0.11.2