LibreOffice Module dbaccess (master) 1
brwview.hxx
Go to the documentation of this file.
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
20#pragma once
21
22#include <vcl/window.hxx>
23
24#include <dbaccess/dataview.hxx>
26#include "dbtreelistbox.hxx"
27
28namespace com::sun::star::awt {
29 class XControl;
30 class XControlContainer;
31 class XControlModel;
32}
33
34class Splitter;
35
36namespace dbaui
37{
38 class SbaGridControl;
39
41 {
42 css::uno::Reference< css::awt::XControl > m_xGrid; // our grid's UNO representation
43 css::uno::Reference< css::awt::XControlContainer > m_xMe; // our own UNO representation
46 mutable VclPtr<SbaGridControl> m_pVclControl; // our grid's VCL representation
47
48 DECL_LINK( SplitHdl, Splitter*, void );
49 // attribute access
50 public:
51 const css::uno::Reference< css::awt::XControl >& getGridControl() const { return m_xGrid; }
53
55 IController& _rController,
56 const css::uno::Reference< css::uno::XComponentContext >& );
57 virtual ~UnoDataBrowserView() override;
58 virtual void dispose() override;
59
61 void Construct(const css::uno::Reference< css::awt::XControlModel >& xModel);
62
66 sal_uInt16 View2ModelPos(sal_uInt16 nPos) const;
68
69 void setSplitter(Splitter* pSplitter);
70 void setTreeView(InterimDBTreeListBox* pTreeView);
71
72 void showStatus( const OUString& _rStatus );
73 void hideStatus();
74
75 const css::uno::Reference< css::awt::XControlContainer >& getContainer() const { return m_xMe; }
76
77 private:
78 virtual bool PreNotify( NotifyEvent& rNEvt ) override;
79 virtual void GetFocus() override;
80 virtual void resizeDocumentView(tools::Rectangle& rRect) override;
81 virtual void _disposing( const css::lang::EventObject& _rSource ) override;
82
84 };
85
87 {
89
90 public:
91 BrowserViewStatusDisplay( UnoDataBrowserView* _pView, const OUString& _rStatus );
93 };
94}
95
96/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
BrowserViewStatusDisplay(UnoDataBrowserView *_pView, const OUString &_rStatus)
Definition: brwview.cxx:318
VclPtr< UnoDataBrowserView > m_pView
Definition: brwview.hxx:88
virtual void Construct()
late construction
Definition: dataview.cxx:49
css::uno::Reference< css::awt::XControlContainer > m_xMe
Definition: brwview.hxx:43
void showStatus(const OUString &_rStatus)
Definition: brwview.cxx:160
css::uno::Reference< css::awt::XControl > m_xGrid
Definition: brwview.hxx:42
SbaGridControl * getVclControl() const
Definition: brwview.cxx:244
virtual void dispose() override
Definition: brwview.cxx:120
VclPtr< InterimDBTreeListBox > m_pTreeView
Definition: brwview.hxx:44
virtual void Construct()
late construction
Definition: dataview.cxx:49
const css::uno::Reference< css::awt::XControl > & getGridControl() const
Definition: brwview.hxx:51
virtual void resizeDocumentView(tools::Rectangle &rRect) override
Definition: brwview.cxx:191
UnoDataBrowserView(vcl::Window *pParent, IController &_rController, const css::uno::Reference< css::uno::XComponentContext > &)
Definition: brwview.cxx:66
virtual ~UnoDataBrowserView() override
Definition: brwview.cxx:115
DECL_LINK(SplitHdl, Splitter *, void)
VclPtr< Splitter > m_pSplitter
Definition: brwview.hxx:45
virtual void _disposing(const css::lang::EventObject &_rSource) override
Definition: brwview.cxx:286
void setSplitter(Splitter *pSplitter)
for the same reason the view column count isn't the same as the model column count
Definition: brwview.cxx:144
const css::uno::Reference< css::awt::XControlContainer > & getContainer() const
Definition: brwview.hxx:75
sal_uInt16 View2ModelPos(sal_uInt16 nPos) const
as columns may be hidden there is a difference between a columns model pos and its view pos so we you...
Definition: brwview.cxx:239
virtual void GetFocus() override
Definition: brwview.cxx:267
virtual bool PreNotify(NotifyEvent &rNEvt) override
Definition: brwview.cxx:292
void setTreeView(InterimDBTreeListBox *pTreeView)
Definition: brwview.cxx:151
VclPtr< SbaGridControl > m_pVclControl
Definition: brwview.hxx:46
Reference< XModel > xModel
the model of the sub component. Might be <NULL>