00001 /* AbiSource Program Utilities 00002 * Copyright (C) 1998 AbiSource, Inc. 00003 * 00004 * This program is free software; you can redistribute it and/or 00005 * modify it under the terms of the GNU General Public License 00006 * as published by the Free Software Foundation; either version 2 00007 * of the License, or (at your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 00017 * 02110-1301 USA. 00018 */ 00019 00020 #ifndef EV_TOOLBAR_H 00021 #define EV_TOOLBAR_H 00022 00023 /*****************************************************************/ 00024 /*****************************************************************/ 00025 /*****************************************************************/ 00026 /*****************************************************************/ 00027 00028 #include "ut_types.h" 00029 00030 class EV_EditMethodContainer; 00031 class EV_EditMethod; 00032 class EV_Toolbar_Layout; 00033 class EV_Toolbar_LabelSet; 00034 class AV_View; 00035 00036 class ABI_EXPORT EV_Toolbar 00037 { 00038 public: 00039 EV_Toolbar(EV_EditMethodContainer * pEMC, 00040 const char * szMenuLayoutName, 00041 const char * szMenuLanguageName); 00042 virtual ~EV_Toolbar(void); 00043 00044 const EV_Toolbar_Layout * getToolbarLayout(void) const; 00045 const EV_Toolbar_LabelSet * getToolbarLabelSet(void) const; 00046 00047 bool invokeToolbarMethod(AV_View * pView, 00048 EV_EditMethod * pEM, 00049 const UT_UCS4Char * pData, 00050 UT_uint32 dataLength); 00051 00052 virtual bool synthesize(void) { return (false); } // Abstract 00053 virtual void show(void) { m_bHidden = false; } // It must be abstract, but I don't want to screw 00054 virtual void hide(void) { m_bHidden = true; } // the platforms that don't implement show/hide 00055 virtual bool repopulateStyles(void) {return false;} 00056 // tells if the toolbar is hidden 00057 bool isHidden(void) const { return m_bHidden; }; 00058 protected: 00059 EV_EditMethodContainer * m_pEMC; 00060 EV_Toolbar_Layout * m_pToolbarLayout; 00061 EV_Toolbar_LabelSet * m_pToolbarLabelSet; 00062 private: 00063 bool m_bHidden; 00064 }; 00065 00066 #endif /* EV_TOOLBAR_H */