Version 6.4.0.0.beta1, tag libreoffice-6.4.0.0.beta1
[LibreOffice.git] / extensions / source / bibliography / bibview.hxx
blob5ac24ae9bc0324e7498f917dcb020d6a0b19ce02
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 INCLUDED_EXTENSIONS_SOURCE_BIBLIOGRAPHY_BIBVIEW_HXX
20 #define INCLUDED_EXTENSIONS_SOURCE_BIBLIOGRAPHY_BIBVIEW_HXX
22 #include <com/sun/star/beans/XPropertySet.hpp>
23 #include <com/sun/star/awt/XControlContainer.hpp>
24 #include "formcontrolcontainer.hxx"
25 #include "bibshortcuthandler.hxx"
27 class BibGeneralPage;
28 class BibDataManager;
30 namespace com{ namespace sun{ namespace star{ namespace awt{ class XFocusListener;}}}}
33 namespace bib
37 class BibView;
38 class BibViewFormControlContainer : public FormControlContainer
40 private:
41 VclPtr<BibView> mpBibView;
42 protected:
43 // FormControlContainer
44 virtual css::uno::Reference< css::awt::XControlContainer >
45 getControlContainer() override;
46 // XLoadListener equivalents
47 virtual void _loaded( const css::lang::EventObject& _rEvent ) override;
48 virtual void _reloaded( const css::lang::EventObject& _rEvent ) override;
49 public:
50 using FormControlContainer::connectForm;
51 using FormControlContainer::disconnectForm;
52 using FormControlContainer::isFormConnected;
53 explicit BibViewFormControlContainer(BibView *pBibView);
56 class BibView : public BibWindow
58 private:
59 BibDataManager* m_pDatMan;
60 css::uno::Reference< css::form::XLoadable> m_xDatMan;
61 VclPtr<BibGeneralPage> m_pGeneralPage;
62 BibViewFormControlContainer m_aFormControlContainer;
64 private:
65 DECL_LINK(CallMappingHdl, void*, void);
67 public:
68 // Window overridables
69 virtual void Resize() override;
71 public:
72 BibView( vcl::Window* _pParent, BibDataManager* _pDatMan, WinBits nStyle );
73 virtual ~BibView() override;
74 virtual void dispose() override;
76 void UpdatePages();
77 css::uno::Reference< css::awt::XControlContainer > getControlContainer() const;
79 virtual void GetFocus() override;
81 virtual bool HandleShortCutKey( const KeyEvent& rKeyEvent ) override; // returns true, if key was handled
85 } // namespace bib
88 #endif
91 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */