1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
29 #ifndef DBAUI_TOOLBOXHELPER_HXX
30 #define DBAUI_TOOLBOXHELPER_HXX
32 #include <sal/types.h>
33 #include <tools/link.hxx>
34 #include <tools/gen.hxx>
35 #include <vcl/image.hxx>
36 #include "dbaccessdllapi.h"
44 class DBACCESS_DLLPUBLIC OToolBoxHelper
46 sal_Int16 m_nSymbolsSize
; // shows the toolbox large or small bitmaps
47 ToolBox
* m_pToolBox
; // our toolbox (may be NULL)
50 virtual ~OToolBoxHelper();
52 /** will be called when the controls need to be resized.
54 Contains the difference of the old and new toolbox size.
56 virtual void resizeControls(const Size
& _rDiff
) = 0;
58 /** will be called when the image list is needed.
62 <TRUE/> when in high contrast mode.
64 virtual ImageList
getImageList(sal_Int16 _eSymbolsSize
) const = 0;
66 /** only the member will be set, derived classes can overload this function and do what need to be done.
70 Must be called after a FreeResource() call.
72 virtual void setToolBox(ToolBox
* _pTB
);
74 inline ToolBox
* getToolBox() const { return m_pToolBox
; }
76 /** checks if the toolbox needs a new imagelist.
78 void checkImageList();
81 DECL_LINK(ConfigOptionsChanged
, SvtMiscOptions
*);
82 DECL_LINK(SettingsChanged
, VclWindowEvent
* );
85 #endif // DBAUI_TOOLBOXHELPER_HXX
87 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */