User: kz Date: 2008-06-25 12:36:53+0000 Modified: dba/dbaccess/source/ui/app/AppDetailPageHelper.hxx
Log: INTEGRATION: CWS dba30d (1.14.30); FILE MERGED 2008/06/10 11:05:19 fs 1.14.30.4: +describeCurrentSelectionForType 2008/06/09 13:45:44 fs 1.14.30.3: #i80943# retrieve the proper selection for the context menu interceptors 2008/06/01 21:02:32 fs 1.14.30.2: #i80943# more preparations for context menu interception, including some re-factoring 2008/05/29 11:33:17 fs 1.14.30.1: in preparation of #i80943#: implement IContextMenuProvider File Changes: Directory: /dba/dbaccess/source/ui/app/ ======================================= File [changed]: AppDetailPageHelper.hxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/app/AppDetailPageHelper.hxx?r1=1.14&r2=1.15 Delta lines: +32 -12 --------------------- --- AppDetailPageHelper.hxx 2008-04-10 13:56:48+0000 1.14 +++ AppDetailPageHelper.hxx 2008-06-25 12:36:50+0000 1.15 @@ -38,6 +38,9 @@ #ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_ #include <com/sun/star/sdbc/XDatabaseMetaData.hpp> #endif +#ifndef _COM_SUN_STAR_SDB_APPLICATION_NAMEDDATABASEOBJECT_HPP_ +#include <com/sun/star/sdb/application/NamedDatabaseObject.hpp> +#endif #ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_ #include <com/sun/star/ucb/XContent.hpp> #endif @@ -65,13 +68,14 @@ #ifndef _GRFMGR_HXX #include <goodies/grfmgr.hxx> #endif +#include "callbacks.hxx" #include <memory> namespace com{ namespace sun { namespace star { namespace awt { class XWindow; } } } } namespace com{ namespace sun { namespace star { namespace frame { class XFrame; } } } } namespace com{ namespace sun { namespace star { namespace io { class XPersist; } } } } -#define CONTROL_COUNT 4 +#define ELEMENT_COUNT size_t(E_ELEMENT_TYPE_COUNT) namespace dbaui { @@ -110,7 +114,7 @@ //================================================================== class OAppDetailPageHelper : public Window { - DBTreeListBox* m_pLists[CONTROL_COUNT]; + DBTreeListBox* m_pLists[ELEMENT_COUNT]; OAppBorderWindow& m_rBorderWin; FixedLine m_aFL; ToolBox m_aTBPreview; @@ -146,8 +150,8 @@ /** fills the names in the listbox @param _xContainer This can either be the queries, forms or report names. - @param _rList - The tree list box to fill + @param _eType + the type of elements which are being filled @param _nImageId the resource id of the image to use for non-container entries @param _nHighContrastImageId @@ -155,11 +159,12 @@ @param _pParent The parent of the entries to be inserted. */ - void fillNames( const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _xContainer - ,DBTreeListBox& _rList - ,USHORT _nImageId - ,USHORT _nHighContrastImageId - ,SvLBoxEntry* _pParent = NULL); + void fillNames( const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _xContainer, + const ElementType _eType, + const USHORT _nImageId, + const USHORT _nHighContrastImageId, + SvLBoxEntry* _pParent ); + /** sets the detail page @param _pWindow The control which should be visible. @@ -206,6 +211,7 @@ inline OAppBorderWindow& getBorderWin() const { return m_rBorderWin; } void ImplInitSettings(); + public: OAppDetailPageHelper(Window* _pParent,OAppBorderWindow& _rBorderWin,PreviewMode _ePreviewMode); virtual ~OAppDetailPageHelper(); @@ -261,6 +267,20 @@ */ void getSelectionElementNames( ::std::vector< ::rtl::OUString>& _rNames ) const; + /** describes the current selection for the given control + */ + void describeCurrentSelectionForControl( + const Control& _rControl, + ::com::sun::star::uno::Sequence< ::com::sun::star::sdb::application::NamedDatabaseObject >& _out_rSelectedObjects + ); + + /** describes the current selection for the given ElementType + */ + void describeCurrentSelectionForType( + const ElementType _eType, + ::com::sun::star::uno::Sequence< ::com::sun::star::sdb::application::NamedDatabaseObject >& _out_rSelectedObjects + ); + /** select all names on the currently selected container. Non existence names where ignored. * * \param _aNames the element names @@ -291,7 +311,7 @@ @return <TRUE/> if the entry is a leaf, otherwise <FALSE/> */ - sal_Bool isLeaf(SvLBoxEntry* _pEntry) const; + bool isLeaf(SvLBoxEntry* _pEntry) const; /** returns if one of the selected entries is a leaf @return --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
