TextMenuItemToggle.h

Go to the documentation of this file.
00001 #ifndef TEXTMENUITEMTOGGLE_H_
00002 #define TEXTMENUITEMTOGGLE_H_
00003 
00004 #include "TextMenuItem.h"
00005 
00006 #include <gtk/gtkcheckmenuitem.h>
00007 
00008 namespace gtkutil
00009 {
00010 
00013     class TextMenuItemToggle: public TextMenuItemMnemonic
00014     {
00015         public:
00016 
00017             // Constructor
00018             TextMenuItemToggle (const std::string& text) :
00019                 TextMenuItemMnemonic(text)
00020             {
00021             }
00022 
00023             // Operator cast to GtkWidget* for packing into a menu
00024             virtual operator GtkWidget* ()
00025             {
00026                 GtkWidget* menuItem = gtk_check_menu_item_new_with_mnemonic(_label.c_str());
00027                 return menuItem;
00028             }
00029     };
00030 
00031 } // namespace gtkutil
00032 
00033 #endif /*TEXTMENUITEMTOGGLE_H_*/

Generated by  doxygen 1.6.2