LibreOffice Module cui (master) 1
connpooloptions.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 <sfx2/tabdlg.hxx>
23
24#include "connpoolsettings.hxx"
25
26namespace offapp
27{
29 {
30 OUString m_sYes;
31 OUString m_sNo;
34
35 std::unique_ptr<weld::CheckButton> m_xEnablePooling;
36 std::unique_ptr<weld::Label> m_xDriversLabel;
37 std::unique_ptr<weld::TreeView> m_xDriverList;
38 std::unique_ptr<weld::Label> m_xDriverLabel;
39 std::unique_ptr<weld::Label> m_xDriver;
40 std::unique_ptr<weld::CheckButton> m_xDriverPoolingEnabled;
41 std::unique_ptr<weld::Label> m_xTimeoutLabel;
42 std::unique_ptr<weld::SpinButton> m_xTimeout;
43
44 public:
45 ConnectionPoolOptionsPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& _rAttrSet);
46 virtual ~ConnectionPoolOptionsPage() override;
47 static std::unique_ptr<SfxTabPage> Create(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* _rAttrSet);
48
49 private:
50 virtual bool FillItemSet(SfxItemSet* _rSet) override;
51 virtual void Reset(const SfxItemSet* _rSet) override;
52 virtual void ActivatePage( const SfxItemSet& _rSet) override;
53
54 void updateRow(size_t nRow);
55 void updateCurrentRow();
56 void UpdateDriverList(const DriverPoolingSettings& _rSettings);
57 bool isModifiedDriverList() const;
59
60 DECL_LINK(OnEnabledDisabled, weld::Toggleable&, void);
61 DECL_LINK(OnSpinValueChanged, weld::SpinButton&, void);
62 DECL_LINK(OnDriverRowChanged, weld::TreeView&, void);
63
64 void implInitControls(const SfxItemSet& _rSet);
65
66 void commitTimeoutField();
67 };
68
69} // namespace offapp
70
71/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
DECL_LINK(OnDriverRowChanged, weld::TreeView &, void)
std::unique_ptr< weld::TreeView > m_xDriverList
void implInitControls(const SfxItemSet &_rSet)
std::unique_ptr< weld::SpinButton > m_xTimeout
virtual void Reset(const SfxItemSet *_rSet) override
virtual void ActivatePage(const SfxItemSet &_rSet) override
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *_rAttrSet)
void UpdateDriverList(const DriverPoolingSettings &_rSettings)
std::unique_ptr< weld::Label > m_xDriverLabel
virtual ~ConnectionPoolOptionsPage() override
std::unique_ptr< weld::CheckButton > m_xDriverPoolingEnabled
DECL_LINK(OnEnabledDisabled, weld::Toggleable &, void)
std::unique_ptr< weld::Label > m_xTimeoutLabel
ConnectionPoolOptionsPage(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &_rAttrSet)
virtual bool FillItemSet(SfxItemSet *_rSet) override
DriverPoolingSettings m_aSavedSettings
std::unique_ptr< weld::CheckButton > m_xEnablePooling
std::unique_ptr< weld::Label > m_xDriver
std::unique_ptr< weld::Label > m_xDriversLabel
DECL_LINK(OnSpinValueChanged, weld::SpinButton &, void)