fdo#74697 Add Bluez 5 support for impress remote.
[LibreOffice.git] / include / dbaccess / dataview.hxx
blob70fcf034af6fdef6386471e98b047d47bb5032b0
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
19 #ifndef DBAUI_DATAVIEW_HXX
20 #define DBAUI_DATAVIEW_HXX
22 #include "dbaccessdllapi.h"
24 #include <com/sun/star/uno/XComponentContext.hpp>
25 #include <svtools/acceleratorexecute.hxx>
26 #include <sal/macros.h>
27 #include <vcl/fixed.hxx>
29 #include <memory>
31 class FixedLine;
32 namespace dbaui
34 class IController;
35 class DBACCESS_DLLPUBLIC ODataView : public Window
37 ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext; // the service factory to work with
39 protected:
40 IController& m_rController; // the controller in where we resides in
41 FixedLine m_aSeparator;
42 ::std::auto_ptr< ::svt::AcceleratorExecute> m_pAccel;
44 public:
45 ODataView( Window* pParent,
46 IController& _rController,
47 const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& ,
48 WinBits nStyle = 0 );
49 virtual ~ODataView();
51 /// late construction
52 virtual void Construct();
53 // initialize will be called when after the controller finished his initialize method
54 virtual void initialize(){}
55 // window overridables
56 virtual long PreNotify( NotifyEvent& rNEvt );
57 virtual void StateChanged( StateChangedType nStateChange );
58 virtual void DataChanged( const DataChangedEvent& rDCEvt );
60 inline IController& getCommandController() const { return m_rController; }
62 /** will be called when the controls need to be resized.
64 virtual void resizeControls(const Size& /*_rDiff*/) { Resize(); }
66 ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > getORB() { return m_xContext;}
68 // the default implementation simply calls resizeAll( GetSizePixel() )
69 virtual void Resize();
71 void attachFrame(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _xFrame);
72 protected:
73 // window overridables
74 virtual void Paint( const Rectangle& _rRect );
76 /// re-arrange all controls, including the toolbox, it's separator, and the "real view"
77 virtual void resizeAll( const Rectangle& _rPlayground );
79 // re-arrange the controls belonging to the document itself
80 virtual void resizeDocumentView( Rectangle& _rPlayground );
83 #endif // DBAUI_DATAVIEW_HXX
85 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */