Version 6.4.0.0.beta1, tag libreoffice-6.4.0.0.beta1
[LibreOffice.git] / chart2 / source / controller / inc / dlg_DataEditor.hxx
blobf4682ab4321218513b2ad41cb2019a014f919cc7
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 .
20 #ifndef INCLUDED_CHART2_SOURCE_CONTROLLER_INC_DLG_DATAEDITOR_HXX
21 #define INCLUDED_CHART2_SOURCE_CONTROLLER_INC_DLG_DATAEDITOR_HXX
23 #include <vcl/weld.hxx>
25 namespace com { namespace sun { namespace star { namespace uno { class XComponentContext; } } } }
26 namespace comphelper { template <class Tp, class Arg> class mem_fun1_t; }
28 namespace com { namespace sun { namespace star {
29 namespace chart2 {
30 class XChartDocument;
32 }}}
34 namespace chart
37 class DataBrowser;
39 class DataEditor : public weld::GenericDialogController
41 public:
42 DataEditor(weld::Window* pParent,
43 const css::uno::Reference<css::chart2::XChartDocument> & xChartDoc,
44 const css::uno::Reference<css::uno::XComponentContext> & xContext);
45 virtual ~DataEditor() override;
47 DECL_LINK(CloseHdl, weld::Button&, void);
49 void SetReadOnly( bool bReadOnly );
50 bool ApplyChangesToModel();
52 private:
53 bool m_bReadOnly;
55 css::uno::Reference<css::chart2::XChartDocument> m_xChartDoc;
56 css::uno::Reference<css::uno::XComponentContext> m_xContext;
58 std::unique_ptr<weld::Toolbar> m_xTbxData;
59 std::unique_ptr<weld::Button> m_xCloseBtn;
60 std::unique_ptr<weld::Container> m_xTable;
61 std::unique_ptr<weld::Container> m_xColumns;
62 std::unique_ptr<weld::Container> m_xColors;
63 css::uno::Reference<css::awt::XWindow> m_xTableCtrlParent;
64 VclPtr<DataBrowser> m_xBrwData;
66 /// handles actions of the toolbox
67 DECL_LINK( ToolboxHdl, const OString&, void );
68 /// is called, if the cursor of the table has moved
69 DECL_LINK( BrowserCursorMovedHdl, DataBrowser*, void);
72 } // namespace chart
74 #endif // INCLUDED_CHART2_SOURCE_CONTROLLER_INC_DLG_DATAEDITOR_HXX
76 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */