1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 .
21 #include <TableGrantCtrl.hxx>
22 #include "adminpages.hxx"
24 namespace com::sun::star
{
33 class OUserAdmin final
: public OGenericAdministrationPage
35 std::unique_ptr
<weld::MenuButton
> mxActionBar
;
36 std::unique_ptr
<weld::ComboBox
> m_xUSER
;
37 std::unique_ptr
<weld::Container
> m_xTable
;
38 css::uno::Reference
<css::awt::XWindow
> m_xTableCtrlParent
;
39 VclPtr
<OTableGrantControl
> m_xTableCtrl
; // show the grant rights of one user
41 css::uno::Reference
< css::sdbc::XConnection
> m_xConnection
;
42 css::uno::Reference
< css::container::XNameAccess
> m_xUsers
;
47 DECL_LINK(ListDblClickHdl
, weld::ComboBox
&, void);
48 DECL_LINK(MenuSelectHdl
, const OUString
&, void);
53 OUserAdmin(weld::Container
* pPage
, weld::DialogController
* pController
, const SfxItemSet
& _rCoreAttrs
);
54 static std::unique_ptr
<SfxTabPage
> Create(weld::Container
* pPage
, weld::DialogController
* pController
, const SfxItemSet
* rAttrSet
);
55 virtual ~OUserAdmin() override
;
57 OUString
GetUser() const;
59 // subclasses must override this, but it isn't pure virtual
60 virtual void implInitControls(const SfxItemSet
& _rSet
, bool _bSaveValue
) override
;
62 // <method>OGenericAdministrationPage::fillControls</method>
63 virtual void fillControls(std::vector
< std::unique_ptr
<ISaveValueWrapper
> >& _rControlList
) override
;
65 // <method>OGenericAdministrationPage::fillWindows</method>
66 virtual void fillWindows(std::vector
< std::unique_ptr
<ISaveValueWrapper
> >& _rControlList
) override
;
71 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */