1*2503e1a5SAriel Constenla-Haile /************************************************************** 2*2503e1a5SAriel Constenla-Haile * 3*2503e1a5SAriel Constenla-Haile * Licensed to the Apache Software Foundation (ASF) under one 4*2503e1a5SAriel Constenla-Haile * or more contributor license agreements. See the NOTICE file 5*2503e1a5SAriel Constenla-Haile * distributed with this work for additional information 6*2503e1a5SAriel Constenla-Haile * regarding copyright ownership. The ASF licenses this file 7*2503e1a5SAriel Constenla-Haile * to you under the Apache License, Version 2.0 (the 8*2503e1a5SAriel Constenla-Haile * "License"); you may not use this file except in compliance 9*2503e1a5SAriel Constenla-Haile * with the License. You may obtain a copy of the License at 10*2503e1a5SAriel Constenla-Haile * 11*2503e1a5SAriel Constenla-Haile * http://www.apache.org/licenses/LICENSE-2.0 12*2503e1a5SAriel Constenla-Haile * 13*2503e1a5SAriel Constenla-Haile * Unless required by applicable law or agreed to in writing, 14*2503e1a5SAriel Constenla-Haile * software distributed under the License is distributed on an 15*2503e1a5SAriel Constenla-Haile * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*2503e1a5SAriel Constenla-Haile * KIND, either express or implied. See the License for the 17*2503e1a5SAriel Constenla-Haile * specific language governing permissions and limitations 18*2503e1a5SAriel Constenla-Haile * under the License. 19*2503e1a5SAriel Constenla-Haile * 20*2503e1a5SAriel Constenla-Haile *************************************************************/ 21*2503e1a5SAriel Constenla-Haile 22*2503e1a5SAriel Constenla-Haile #ifndef __FRAMEWORK_UIELEMENT_STATUSBARITEM_HXX_ 23*2503e1a5SAriel Constenla-Haile #define __FRAMEWORK_UIELEMENT_STATUSBARITEM_HXX_ 24*2503e1a5SAriel Constenla-Haile 25*2503e1a5SAriel Constenla-Haile #include <com/sun/star/ui/XStatusbarItem.hpp> 26*2503e1a5SAriel Constenla-Haile #include <cppuhelper/compbase1.hxx> 27*2503e1a5SAriel Constenla-Haile #include <cppuhelper/basemutex.hxx> 28*2503e1a5SAriel Constenla-Haile 29*2503e1a5SAriel Constenla-Haile class StatusBar; 30*2503e1a5SAriel Constenla-Haile 31*2503e1a5SAriel Constenla-Haile namespace framework 32*2503e1a5SAriel Constenla-Haile { 33*2503e1a5SAriel Constenla-Haile 34*2503e1a5SAriel Constenla-Haile struct AddonStatusbarItemData; 35*2503e1a5SAriel Constenla-Haile 36*2503e1a5SAriel Constenla-Haile typedef cppu::WeakComponentImplHelper1< com::sun::star::ui::XStatusbarItem > StatusbarItem_Base; 37*2503e1a5SAriel Constenla-Haile 38*2503e1a5SAriel Constenla-Haile class StatusbarItem : protected cppu::BaseMutex, 39*2503e1a5SAriel Constenla-Haile public StatusbarItem_Base 40*2503e1a5SAriel Constenla-Haile { 41*2503e1a5SAriel Constenla-Haile public: 42*2503e1a5SAriel Constenla-Haile explicit StatusbarItem( 43*2503e1a5SAriel Constenla-Haile StatusBar *pStatusBar, 44*2503e1a5SAriel Constenla-Haile AddonStatusbarItemData *pItemData, 45*2503e1a5SAriel Constenla-Haile sal_uInt16 nId, 46*2503e1a5SAriel Constenla-Haile const rtl::OUString& aCommand ); 47*2503e1a5SAriel Constenla-Haile ~StatusbarItem(); 48*2503e1a5SAriel Constenla-Haile 49*2503e1a5SAriel Constenla-Haile void SAL_CALL disposing(); 50*2503e1a5SAriel Constenla-Haile 51*2503e1a5SAriel Constenla-Haile // com::sun::star::ui::XStatusbarItem Attributes 52*2503e1a5SAriel Constenla-Haile virtual ::rtl::OUString SAL_CALL getCommand() throw (::com::sun::star::uno::RuntimeException); 53*2503e1a5SAriel Constenla-Haile virtual ::sal_uInt16 SAL_CALL getItemId() throw (::com::sun::star::uno::RuntimeException); 54*2503e1a5SAriel Constenla-Haile virtual ::sal_uInt32 SAL_CALL getWidth() throw (::com::sun::star::uno::RuntimeException); 55*2503e1a5SAriel Constenla-Haile virtual ::sal_uInt16 SAL_CALL getStyle() throw (::com::sun::star::uno::RuntimeException); 56*2503e1a5SAriel Constenla-Haile virtual ::sal_Int32 SAL_CALL getOffset() throw (::com::sun::star::uno::RuntimeException); 57*2503e1a5SAriel Constenla-Haile virtual ::com::sun::star::awt::Rectangle SAL_CALL getItemRect() throw (::com::sun::star::uno::RuntimeException); 58*2503e1a5SAriel Constenla-Haile virtual ::rtl::OUString SAL_CALL getText() throw (::com::sun::star::uno::RuntimeException); 59*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL setText( const rtl::OUString& rText ) throw (::com::sun::star::uno::RuntimeException); 60*2503e1a5SAriel Constenla-Haile virtual ::rtl::OUString SAL_CALL getHelpText() throw (::com::sun::star::uno::RuntimeException); 61*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL setHelpText( const rtl::OUString& rHelpText ) throw (::com::sun::star::uno::RuntimeException); 62*2503e1a5SAriel Constenla-Haile virtual ::rtl::OUString SAL_CALL getQuickHelpText() throw (::com::sun::star::uno::RuntimeException); 63*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL setQuickHelpText( const rtl::OUString& rQuickHelpText ) throw (::com::sun::star::uno::RuntimeException); 64*2503e1a5SAriel Constenla-Haile virtual ::rtl::OUString SAL_CALL getAccessibleName() throw (::com::sun::star::uno::RuntimeException); 65*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL setAccessibleName( const rtl::OUString& rAccessibleName ) throw (::com::sun::star::uno::RuntimeException); 66*2503e1a5SAriel Constenla-Haile virtual ::sal_Bool SAL_CALL getVisible() throw (::com::sun::star::uno::RuntimeException); 67*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL setVisible( sal_Bool bVisible ) throw (::com::sun::star::uno::RuntimeException); 68*2503e1a5SAriel Constenla-Haile 69*2503e1a5SAriel Constenla-Haile // com::sun::star::ui::XStatusbarItem Methods 70*2503e1a5SAriel Constenla-Haile virtual void SAL_CALL repaint( ) throw (::com::sun::star::uno::RuntimeException); 71*2503e1a5SAriel Constenla-Haile 72*2503e1a5SAriel Constenla-Haile private: 73*2503e1a5SAriel Constenla-Haile StatusBar *m_pStatusBar; 74*2503e1a5SAriel Constenla-Haile AddonStatusbarItemData *m_pItemData; 75*2503e1a5SAriel Constenla-Haile sal_uInt16 m_nId; 76*2503e1a5SAriel Constenla-Haile sal_uInt16 m_nStyle; 77*2503e1a5SAriel Constenla-Haile rtl::OUString m_aCommand; 78*2503e1a5SAriel Constenla-Haile 79*2503e1a5SAriel Constenla-Haile }; 80*2503e1a5SAriel Constenla-Haile 81*2503e1a5SAriel Constenla-Haile } 82*2503e1a5SAriel Constenla-Haile 83*2503e1a5SAriel Constenla-Haile #endif 84