LibreOffice Module cui (master) 1
optaboutconfig.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
10#pragma once
11
12#include <com/sun/star/container/XNameAccess.hpp>
13
15#include <vcl/weld.hxx>
16
17#include <vector>
18
21struct Prop_Impl;
22struct UserData;
23
25{
26 OUString sProp;
27 OUString sStatus;
28 OUString sType;
29 OUString sValue;
31};
32
34{
35private:
36 std::unique_ptr<weld::Button> m_xResetBtn;
37 std::unique_ptr<weld::Button> m_xEditBtn;
38 std::unique_ptr<weld::Button> m_xSearchBtn;
39 std::unique_ptr<weld::Entry> m_xSearchEdit;
40 std::unique_ptr<weld::TreeView> m_xPrefBox;
41 std::unique_ptr<weld::TreeIter> m_xScratchIter;
42
43 std::vector < std::unique_ptr<UserData> > m_vectorUserData;
44
45 std::vector<prefBoxEntry> m_modifiedPrefBoxEntries;
46 std::vector< std::shared_ptr< Prop_Impl > > m_vectorOfModified;
47
48 //for search
50 std::vector<prefBoxEntry> m_prefBoxEntries;
51
53
54 void AddToModifiedVector( const std::shared_ptr< Prop_Impl >& rProp );
55 static std::vector< OUString > commaStringToSequence( std::u16string_view rCommaSepString );
56 void InsertEntry(const prefBoxEntry& rEntry);
57
58 DECL_LINK(StandardHdl_Impl, weld::Button&, void);
59 DECL_LINK(DoubleClickHdl_Impl, weld::TreeView&, bool);
60 DECL_LINK(ResetBtnHdl_Impl, weld::Button&, void);
61 DECL_LINK(SearchHdl_Impl, weld::Button&, void);
62 DECL_LINK(ExpandingHdl_Impl, const weld::TreeIter&, bool);
63 DECL_LINK(HeaderBarClick, int, void);
64
65public:
66 explicit CuiAboutConfigTabPage(weld::Window* pParent);
67 virtual ~CuiAboutConfigTabPage() override;
68 void InsertEntry(const OUString &rPropertyPath, const OUString& rProp, const OUString& rStatus, const OUString& rType, const OUString& rValue,
69 const weld::TreeIter* pParentEntry, bool bInsertToPrefBox);
70 void Reset();
71 void FillItems(const css::uno::Reference<css::container::XNameAccess>& xNameAccess,
72 const weld::TreeIter* pParentEntry = nullptr, int lineage = 0, bool bLoadAll = false);
73 static css::uno::Reference< css::container::XNameAccess > getConfigAccess( const OUString& sNodePath, bool bUpdate );
74 void FillItemSet();
75};
76
78{
79private:
81 std::unique_ptr<weld::Entry> m_xEDValue;
82
83 DECL_LINK(KeyInputHdl, const KeyEvent&, bool);
84
85public:
86 CuiAboutConfigValueDialog(weld::Window* pWindow, const OUString& rValue , int limit);
87 virtual ~CuiAboutConfigValueDialog() override;
88
89 OUString getValue() const
90 {
91 return m_xEDValue->get_text();
92 }
93};
94
95/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::unique_ptr< weld::Entry > m_xSearchEdit
std::vector< prefBoxEntry > m_modifiedPrefBoxEntries
DECL_LINK(DoubleClickHdl_Impl, weld::TreeView &, bool)
DECL_LINK(HeaderBarClick, int, void)
std::vector< std::unique_ptr< UserData > > m_vectorUserData
void FillItems(const css::uno::Reference< css::container::XNameAccess > &xNameAccess, const weld::TreeIter *pParentEntry=nullptr, int lineage=0, bool bLoadAll=false)
DECL_LINK(SearchHdl_Impl, weld::Button &, void)
CuiAboutConfigTabPage(weld::Window *pParent)
void InsertEntry(const prefBoxEntry &rEntry)
std::vector< prefBoxEntry > m_prefBoxEntries
void AddToModifiedVector(const std::shared_ptr< Prop_Impl > &rProp)
std::vector< std::shared_ptr< Prop_Impl > > m_vectorOfModified
DECL_LINK(StandardHdl_Impl, weld::Button &, void)
DECL_LINK(ExpandingHdl_Impl, const weld::TreeIter &, bool)
std::unique_ptr< weld::TreeView > m_xPrefBox
virtual ~CuiAboutConfigTabPage() override
static std::vector< OUString > commaStringToSequence(std::u16string_view rCommaSepString)
static css::uno::Reference< css::container::XNameAccess > getConfigAccess(const OUString &sNodePath, bool bUpdate)
std::unique_ptr< weld::Button > m_xSearchBtn
i18nutil::SearchOptions2 m_options
std::unique_ptr< weld::Button > m_xEditBtn
std::unique_ptr< weld::Button > m_xResetBtn
DECL_LINK(ResetBtnHdl_Impl, weld::Button &, void)
std::unique_ptr< weld::TreeIter > m_xScratchIter
virtual ~CuiAboutConfigValueDialog() override
std::unique_ptr< weld::Entry > m_xEDValue
DECL_LINK(KeyInputHdl, const KeyEvent &, bool)
CuiAboutConfigValueDialog(weld::Window *pWindow, const OUString &rValue, int limit)
OUString sStatus
UserData * pUserData