LCOV - code coverage report
Current view: top level - reportdesign/source/ui/inc - ReportController.hxx (source / functions) Hit Total Coverage
Test: commit 0e63ca4fde4e446f346e35849c756a30ca294aab Lines: 1 9 11.1 %
Date: 2014-04-11 Functions: 1 8 12.5 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : #ifndef RPTUI_REPORTCONTROLLER_HXX
      20             : #define RPTUI_REPORTCONTROLLER_HXX
      21             : 
      22             : #include "DesignView.hxx"
      23             : #include "ModuleHelper.hxx"
      24             : #include "ReportControllerObserver.hxx"
      25             : #include "RptDef.hxx"
      26             : 
      27             : #include <com/sun/star/beans/PropertyValue.hpp>
      28             : #include <com/sun/star/beans/XPropertyChangeListener.hpp>
      29             : #include <com/sun/star/beans/XPropertySet.hpp>
      30             : #include <com/sun/star/embed/XVisualObject.hpp>
      31             : #include <com/sun/star/frame/XDesktop2.hpp>
      32             : #include <com/sun/star/frame/XFrame.hpp>
      33             : #include <com/sun/star/io/XObjectInputStream.hpp>
      34             : #include <com/sun/star/io/XObjectOutputStream.hpp>
      35             : #include <com/sun/star/report/XReportControlModel.hpp>
      36             : #include <com/sun/star/report/XReportDefinition.hpp>
      37             : #include <com/sun/star/report/XReportEngine.hpp>
      38             : #include <com/sun/star/report/XSection.hpp>
      39             : #include <com/sun/star/sdbc/XConnection.hpp>
      40             : #include <com/sun/star/sdbc/XRowSet.hpp>
      41             : #include <com/sun/star/uno/Sequence.hxx>
      42             : #include <com/sun/star/uno/XComponentContext.hpp>
      43             : #include <com/sun/star/util/XModeSelector.hpp>
      44             : #include <com/sun/star/util/XNumberFormatter.hpp>
      45             : #include <com/sun/star/view/XSelectionSupplier.hpp>
      46             : 
      47             : #include <comphelper/implementationreference.hxx>
      48             : #include <comphelper/proparrhlp.hxx>
      49             : #include <comphelper/propertystatecontainer.hxx>
      50             : #include <comphelper/uno3.hxx>
      51             : #include <cppuhelper/implbase5.hxx>
      52             : #include <dbaccess/dbsubcomponentcontroller.hxx>
      53             : #include <svl/lstner.hxx>
      54             : #include <svtools/transfer.hxx>
      55             : #include <svx/svdedtv.hxx>
      56             : #include <sfx2/zoomitem.hxx>
      57             : 
      58             : #include <boost/noncopyable.hpp>
      59             : #include <boost/shared_ptr.hpp>
      60             : #include <functional>
      61             : 
      62             : class TransferableClipboardListener;
      63             : class VclWindowEvent;
      64             : class SfxUndoManager;
      65             : namespace rptui
      66             : {
      67             :     class OGroupsSortingDialog;
      68             :     class OReportModel;
      69             :     class OSectionView;
      70             :     class OAddFieldWindow;
      71             :     class OSectionWindow;
      72             : 
      73             :     typedef ::dbaui::DBSubComponentController   OReportController_BASE;
      74             :     typedef ::cppu::ImplHelper5 <   ::com::sun::star::container::XContainerListener
      75             :                                 ,   ::com::sun::star::beans::XPropertyChangeListener
      76             :                                 ,   ::com::sun::star::view::XSelectionSupplier
      77             :                                 ,   ::com::sun::star::util::XModeSelector
      78             :                                 ,   ::com::sun::star::embed::XVisualObject
      79             :                                 >   OReportController_Listener;
      80             : 
      81             :     class OReportController :    public OReportController_BASE
      82             :                                 ,public OReportController_Listener
      83             :                                 ,public SfxListener
      84             :                                 ,public ::comphelper::OPropertyStateContainer
      85             :                                 ,public ::comphelper::OPropertyArrayUsageHelper < OReportController_BASE >
      86             :                                 ,public ::boost::noncopyable
      87             :     {
      88             :     private:
      89             :         OModuleClient           m_aModuleClient;
      90             :         ::cppu::OInterfaceContainerHelper
      91             :                                 m_aSelectionListeners;
      92             :         ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>
      93             :                                 m_aCollapsedSections;
      94             :         TransferableDataHelper  m_aSystemClipboard;     // content of the clipboard
      95             :         TransferableClipboardListener*
      96             :                                 m_pClipbordNotifier;    /// notifier for changes in the clipboard
      97             :         OGroupsSortingDialog*   m_pGroupsFloater;
      98             : 
      99             :         OXReportControllerObserver* m_pReportControllerObserver;
     100             : 
     101           1 :         ODesignView*  getDesignView() const   { return static_cast< ODesignView* >( getView() ); }
     102             : 
     103             :         ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportDefinition >         m_xReportDefinition;
     104             :         ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportEngine >             m_xReportEngine;
     105             :         ::com::sun::star::uno::Reference< ::com::sun::star::frame::XDesktop2 >                  m_xFrameLoader;
     106             :         ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowSet >                     m_xRowSet;
     107             :         ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >    m_xRowSetMediator;
     108             :         ::com::sun::star::uno::Reference< ::com::sun::star::util::XNumberFormatter >            m_xFormatter;   // a number formatter working with the report's NumberFormatsSupplier
     109             :         mutable ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >          m_xHoldAlive;
     110             :         mutable ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >    m_xColumns;
     111             :         ::com::sun::star::awt::Size                                                             m_aVisualAreaSize;
     112             : 
     113             :         ::boost::shared_ptr<rptui::OReportModel>
     114             :                                 m_aReportModel;
     115             :         OUString         m_sName;                /// name for the report definition
     116             :         OUString         m_sLastActivePage;      /// last active property browser page
     117             :         OUString         m_sMode;                /// the current mode of the controller
     118             :         sal_Int32               m_nSplitPos;            /// the position of the splitter
     119             :         sal_Int32               m_nPageNum;             /// the page number from the restoreView call
     120             :         sal_Int32               m_nSelectionCount;
     121             :         ::sal_Int64             m_nAspect;
     122             :         sal_Int16               m_nZoomValue;
     123             :         SvxZoomType             m_eZoomType;
     124             :         sal_Bool                m_bShowRuler;
     125             :         sal_Bool                m_bGridVisible;
     126             :         sal_Bool                m_bGridUse;
     127             :         sal_Bool                m_bShowProperties;
     128             :         sal_Bool                m_bGroupFloaterWasVisible;
     129             :         sal_Bool                m_bHelplinesMove;
     130             :         bool                    m_bChartEnabled;
     131             :         bool                    m_bChartEnabledAsked;
     132             :         bool                    m_bInGeneratePreview;
     133             : 
     134             :         /** creates a formatted field in the given section with the given formula as data field
     135             :         *
     136             :         * \param _aArgs
     137             :         * \param _xSection the section where to create the formatted field
     138             :         * \param _sFunction the function which will be set at the data field.
     139             :         */
     140             :         void createControl(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _aArgs,const ::com::sun::star::uno::Reference< ::com::sun::star::report::XSection>& _xSection,const OUString& _sFunction ,sal_uInt16 _nObjectId = OBJ_DLG_FORMATTEDFIELD);
     141             :         /** switch the report header/footer sectionon off with undo or without depending on the given id.
     142             :         *
     143             :         * \param _nId   Can either be SID_REPORTHEADER_WITHOUT_UNDO or SID_REPORTFOOTER_WITHOUT_UNDO or SID_REPORTHEADERFOOTER.
     144             :         */
     145             :         void switchReportSection(const sal_Int16 _nId);
     146             : 
     147             :         /** switch the report header/footer sectionon off with undo or without depending on the given id.
     148             :         *
     149             :         * \param _nId   Can either be SID_PAGEHEADER_WITHOUT_UNDO or SID_PAGEFOOTER_WITHOUT_UNDO or SID_PAGEHEADERFOOTER.
     150             :         */
     151             :         void switchPageSection(const sal_Int16 _nId);
     152             : 
     153             :         /** append a new group or remove it with undo.
     154             :         *
     155             :         * \param _bAppend
     156             :         * \param _aArgs The args which contains a element named PROPERTY_GROUP of type report::XGroup.
     157             :         */
     158             :         void modifyGroup(const bool _bAppend, const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _aArgs);
     159             : 
     160             :         /** creates a group section.
     161             :         *
     162             :         * \param _bUndo true when undo action should be created
     163             :         * \param _bHeader true when it is a header otherwise it is a footer
     164             :         * \param _aArgs The args which contains a element named PROPERTY_GROUP of type report::XGroup.
     165             :         */
     166             :         void createGroupSection(const bool _bUndo,const bool _bHeader,const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >&_aArgs);
     167             : 
     168             :         /** add or remove me as listener at the report definition
     169             :         *
     170             :         * \param _bAdd
     171             :         */
     172             :         void listen(const bool _bAdd);
     173             : 
     174             :         /** opens the common page dialog
     175             :         */
     176             :         void openPageDialog(const ::com::sun::star::uno::Reference< ::com::sun::star::report::XSection>& _xSection);
     177             : 
     178             :         /** opens or hides the sorting and grouping dialog
     179             :         */
     180             :         void openSortingAndGroupingDialog();
     181             : 
     182             :         /** opens the zoom dialog
     183             :         */
     184             :         void openZoomDialog();
     185             : 
     186             :         /** returns the position of the group inside the groups collection
     187             :         */
     188             :         sal_Int32 getGroupPosition(const ::com::sun::star::uno::Reference< ::com::sun::star::report::XGroup >& _xGroup);
     189             : 
     190             :         /** calls propertyChanged when the header or footer is really turned on.
     191             :             @param  _rEvent the group
     192             :             @param  _bShow  when <TRUE/> the header and footer will be shown otherwise not
     193             :         */
     194             :         void notifyGroupSections(const ::com::sun::star::container::ContainerEvent& _rEvent
     195             :                                 ,bool _bShow);
     196             : 
     197             :         /** change the sections for a group
     198             :             @param  _sPropName  the header or footer
     199             :             @param  _xGroup the group
     200             :             @param  _nGroupPos  the position of the group inside the groups collection or the previous index when it was removed
     201             :             @param  _bShow  when <TRUE/> the header and footer will be shown otherwise not
     202             :         */
     203             :         void groupChange( const ::com::sun::star::uno::Reference< ::com::sun::star::report::XGroup>& _xGroup
     204             :                          ,const OUString& _sPropName
     205             :                          ,sal_Int32 _nGroupPos
     206             :                          ,bool _bShow);
     207             : 
     208             :         void executeMethodWithUndo(sal_uInt16 _nUndoStrId,const ::std::mem_fun_t<void,ODesignView>& _pMemfun);
     209             :         void alignControlsWithUndo(sal_uInt16 _nUndoStrId,sal_Int32 _nControlModification,bool _bAlignAtSection = false);
     210             : 
     211             :         // open the help agent of report designer at start time
     212             :         void doOpenHelpAgent();
     213             : 
     214             :         ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > getXFrame();
     215             : 
     216             :         /** shrink a section
     217             :         @param _nUndoStrId the string id of the string which is shown in undo menu
     218             :         @param _nShrinkId  ID of what you would like to shrink.
     219             :         */
     220             :         void shrinkSectionBottom(::com::sun::star::uno::Reference< ::com::sun::star::report::XSection > _xSection);
     221             :         void shrinkSectionTop(::com::sun::star::uno::Reference< ::com::sun::star::report::XSection > _xSection);
     222             : 
     223             :     public:
     224             :         void shrinkSection(sal_uInt16 _nUndoStrId, ::com::sun::star::uno::Reference< ::com::sun::star::report::XSection > _xSection, sal_Int32 _nShrinkId);
     225             : 
     226             :         /** opens the file open dialog to allow the user to select a image which will be
     227             :         * bound to a newly created image button.
     228             :         */
     229             :         void insertGraphic();
     230             : 
     231             :         /** resets the floater
     232             :         */
     233             :         void updateFloater();
     234             : 
     235             :         /** creates a new function in the given value context
     236             :         *
     237             :         * \param _aValue contains a XNameContainer
     238             :         */
     239             :         void createNewFunction(const ::com::sun::star::uno::Any& _aValue);
     240             : 
     241             :         /** inserts a label - field pair into the current selected section
     242             :         *
     243             :         * \param aArgs
     244             :         */
     245             :         void addPairControls(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aArgs);
     246             : 
     247             :         /** inserts a label - field combination to show the page number and/or page count
     248             :         *
     249             :         * \param _aArgs
     250             :         */
     251             :         void createPageNumber(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _aArgs);
     252             : 
     253             :         /** creates a formatted filed with TODAY() function and if set also an NOW() function
     254             :         *
     255             :         * \param _aArgs
     256             :         */
     257             :         void createDateTime(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _aArgs);
     258             : 
     259             :         /** gets the current section (SdrView)
     260             :         *
     261             :         * \return the currently selected section or <NULL/> if noone is selected
     262             :         */
     263             :         OSectionView* getCurrentSectionView() const;
     264             : 
     265             :         /**change the ZOrder of a current select object.
     266             :         *
     267             :         * \param _nId The command ID about what to do.
     268             :         */
     269             :         void changeZOrder(sal_Int32 _nId);
     270             : 
     271             :         /** marks the next or previous section, when the first/last section was already selected then the report will be selected.
     272             :         *
     273             :         * \param _bNext
     274             :         */
     275             :         void markSection(const bool _bNext);
     276             : 
     277             :         /** collapse or expand the currently selected section.
     278             :         *
     279             :         * \param _bCollapse collapse if sal_True otherwise expand
     280             :         */
     281             :         void collapseSection(const bool _bCollapse);
     282             : 
     283             :         /** fills the member that chart is enabled or not
     284             :         *
     285             :         */
     286             :         void checkChartEnabled();
     287             : 
     288             :         /** set the zoom factor at the design view
     289             :         */
     290             :         void impl_zoom_nothrow();
     291             : 
     292             :         virtual void impl_onModifyChanged() SAL_OVERRIDE;
     293             : 
     294             :         virtual void onLoadedMenu( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManager >& _xLayoutManager ) SAL_OVERRIDE;
     295             :         virtual void impl_initialize( ) SAL_OVERRIDE;
     296             :         bool isUiVisible() const;
     297             : 
     298             :         /** creates a new default control for the currently set type when the modifier KEY_MOD1 was pressed
     299             :         * \param _aArgs must contain a properyvalue with name "KeyModifier" and value KEY_MOD1 when control should be created.
     300             :         */
     301             :         void createDefaultControl(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& _aArgs);
     302             : 
     303             :         /** fills the state for the feture request.
     304             :             @param  _sProperty  the property which should be filled in the value
     305             :             @param  _rState     the state to fill
     306             :         */
     307             :         void impl_fillState_nothrow(const OUString& _sProperty,dbaui::FeatureState& _rState) const;
     308             :         void impl_fillCustomShapeState_nothrow(const char* _pCustomShapeType,dbaui::FeatureState& _rState) const;
     309             : 
     310             :         /** set the property at all selected controls.
     311             :             @return <TRUE/> when the selection is not empty
     312             :         */
     313             :         bool impl_setPropertyAtControls_throw(const sal_uInt16 _nUndoResId
     314             :             ,const OUString& _sProperty
     315             :             ,const ::com::sun::star::uno::Any& _aValue
     316             :             ,const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _aArgs);
     317             : 
     318             :         void OnInvalidateClipboard();
     319             :         DECL_LINK( OnClipboardChanged, void* );
     320             :         DECL_LINK( OnExecuteReport, void* );
     321             :         DECL_LINK( OnOpenHelpAgent, void* );
     322             :         short saveModified();
     323             :         // all the features which should be handled by this class
     324             :         virtual void            describeSupportedFeatures() SAL_OVERRIDE;
     325             :         // state of a feature. 'feature' may be the handle of a ::com::sun::star::util::URL somebody requested a dispatch interface for OR a toolbar slot.
     326             :         virtual dbaui::FeatureState GetState(sal_uInt16 nId) const SAL_OVERRIDE;
     327             :         // execute a feature
     328             :         virtual void Execute(sal_uInt16 nId, const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& aArgs) SAL_OVERRIDE;
     329             : 
     330             :         virtual void getPropertyDefaultByHandle( sal_Int32 _nHandle, ::com::sun::star::uno::Any& _rDefault ) const SAL_OVERRIDE;
     331             :         virtual void SAL_CALL setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const ::com::sun::star::uno::Any& rValue) throw (::com::sun::star::uno::Exception, std::exception) SAL_OVERRIDE;
     332             : 
     333             :     private:
     334             :         virtual ~OReportController();
     335             : 
     336             :     public:
     337             :         OReportController(::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > const & the_context);
     338             : 
     339             :         DECL_LINK( EventLstHdl, VclWindowEvent* );
     340             :         DECL_LINK( OnCreateHdl, OAddFieldWindow*);
     341             : 
     342             :         DECLARE_XINTERFACE( )
     343             :         DECLARE_XTYPEPROVIDER( )
     344             : 
     345             :         // SfxListener
     346             :         virtual void Notify(SfxBroadcaster & rBc, SfxHint const & rHint) SAL_OVERRIDE;
     347             : 
     348             :         /** returns <TRUE/> when the command is enbaled
     349             :             @param  _nCommand   the command id
     350             :             @param  _xControlFormat the report control format
     351             :         */
     352             :         sal_Bool                            isFormatCommandEnabled(sal_uInt16 _nCommand
     353             :                                                 ,const ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportControlFormat>& _xControlFormat) const;
     354             : 
     355             :         virtual bool                        Construct(Window* pParent) SAL_OVERRIDE;
     356             :         // XEventListener
     357             :         virtual void SAL_CALL               disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     358             : 
     359             :         // ::com::sun::star::frame::XController
     360             :         virtual sal_Bool SAL_CALL           suspend(sal_Bool bSuspend) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     361             : 
     362             :         // ::com::sun::star::lang::XComponent
     363             :         virtual void        SAL_CALL disposing() SAL_OVERRIDE;
     364             : 
     365             :         // XServiceInfo
     366             :         virtual OUString SAL_CALL getImplementationName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     367             :         virtual ::com::sun::star::uno::Sequence< OUString> SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     368             :         // need by registration
     369             :         static OUString getImplementationName_Static() throw( ::com::sun::star::uno::RuntimeException );
     370             :         static ::com::sun::star::uno::Sequence< OUString > getSupportedServiceNames_Static(void) throw( ::com::sun::star::uno::RuntimeException );
     371             :         static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > SAL_CALL
     372             :             create(::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > const & xContext);
     373             : 
     374             :         // ::com::sun::star::container::XContainerListener
     375             :         virtual void SAL_CALL elementInserted(const ::com::sun::star::container::ContainerEvent& Event) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     376             :         virtual void SAL_CALL elementRemoved(const ::com::sun::star::container::ContainerEvent& Event) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     377             :         virtual void SAL_CALL elementReplaced(const ::com::sun::star::container::ContainerEvent& Event) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     378             : 
     379             :         // XPropertyChangeListener
     380             :         virtual void SAL_CALL propertyChange( const ::com::sun::star::beans::PropertyChangeEvent& evt ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     381             : 
     382             :         // XSelectionSupplier
     383             :         virtual sal_Bool SAL_CALL select( const ::com::sun::star::uno::Any& xSelection ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     384             :         virtual ::com::sun::star::uno::Any SAL_CALL getSelection(  ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     385             :         virtual void SAL_CALL addSelectionChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::view::XSelectionChangeListener >& xListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     386             :         virtual void SAL_CALL removeSelectionChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::view::XSelectionChangeListener >& xListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     387             : 
     388             :         // ::com::sun::star::frame::XController
     389             :         virtual sal_Bool SAL_CALL attachModel(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > & xModel) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     390             :         virtual ::com::sun::star::uno::Any SAL_CALL getViewData(void) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     391             :         virtual void SAL_CALL restoreViewData(const ::com::sun::star::uno::Any& Data) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     392             : 
     393             :         /** gives access to the report definition
     394             :         * \return the report definition object, may be <NULL/>
     395             :         */
     396           0 :         inline ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportDefinition> getReportDefinition() const { return m_xReportDefinition; }
     397             : 
     398             :         // ::com::sun::star::frame::XController
     399             :         virtual ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel >  SAL_CALL getModel(void) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
     400             : 
     401             :         // XTitle
     402             :         virtual OUString SAL_CALL getTitle(  ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     403             : 
     404             :         // XModeSelector
     405             :         virtual void SAL_CALL setMode( const OUString& aMode ) throw (::com::sun::star::lang::NoSupportException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE ;
     406             :         virtual OUString SAL_CALL getMode(  ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE ;
     407             :         virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedModes(  ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE ;
     408             :         virtual sal_Bool SAL_CALL supportsMode( const OUString& aMode ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE ;
     409             : 
     410             :         // XVisualObject
     411             :         virtual void SAL_CALL setVisualAreaSize( ::sal_Int64 nAspect, const ::com::sun::star::awt::Size& aSize ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     412             :         virtual ::com::sun::star::awt::Size SAL_CALL getVisualAreaSize( ::sal_Int64 nAspect ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     413             :         virtual ::com::sun::star::embed::VisualRepresentation SAL_CALL getPreferredVisualRepresentation( ::sal_Int64 nAspect ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     414             :         virtual ::sal_Int32 SAL_CALL getMapUnit( ::sal_Int64 nAspect ) throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     415             : 
     416             : 
     417             :         /** returns the current position of the splitter
     418             :         *
     419             :         * \return
     420             :         */
     421           0 :         inline sal_Int32    getSplitPos() const { return m_nSplitPos;}
     422           0 :         inline void         setSplitPos(sal_Int32 _nSplitPos)       { m_nSplitPos = _nSplitPos;}
     423             : 
     424             :         /** creates a new report from the report definition.
     425             :          *
     426             :          * \return The model or <NULL/> if the model could not be created.
     427             :          */
     428             :         ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel> executeReport();
     429             : 
     430             :         /** returns the RowSet which reflects the current settings of the report definition
     431             : 
     432             :             The caller is allowed to hold a reference to the RowSet - it is kept alive as long
     433             :             as the controller lives, and it's settings will follow the report definition's settings.
     434             :         */
     435             :         ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowSet > getRowSet();
     436             : 
     437             :         /** returns the number formatter
     438             :         */
     439             :         ::com::sun::star::uno::Reference< ::com::sun::star::util::XNumberFormatter >    getReportNumberFormatter() const;
     440             : 
     441             :         /** return the SdrModel of the real model
     442             :         *
     443             :         * \return
     444             :         */
     445             :         ::boost::shared_ptr<rptui::OReportModel> getSdrModel() const;
     446             : 
     447           0 :         inline ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >  getContext() const { return m_xContext; }
     448           0 :         inline sal_Int16   getZoomValue() const     { return m_nZoomValue; }
     449           0 :         inline void         resetZoomType()         { m_eZoomType = SVX_ZOOM_PERCENT; }
     450             : 
     451             :         // com::sun::star::beans::XPropertySet
     452           0 :         virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo(  ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE
     453             :         {
     454           0 :             return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper());
     455             :         }
     456             :         // comphelper::OPropertyArrayUsageHelper
     457             :         virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const SAL_OVERRIDE;
     458             : 
     459             :     // cppu::OPropertySetHelper
     460             :         virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
     461             : 
     462             :         ::boost::shared_ptr<OSectionWindow> getSectionWindow(const ::com::sun::star::uno::Reference< ::com::sun::star::report::XSection>& _xSection) const;
     463             : 
     464             :         ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > getColumns() const;
     465             :         OUString getColumnLabel_throw(const OUString& i_sColumnName) const;
     466             : 
     467             :         SfxUndoManager& getUndoManager() const;
     468             :         void            clearUndoManager() const;
     469             :         void            addUndoAction( SfxUndoAction* i_pAction );
     470             :     };
     471             : }
     472             : #endif // RPTUI_REPORTCONTROLLER_HXX
     473             : 
     474             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10