LibreOffice Module cui (master)  1
dbregister.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 <rtl/ustring.hxx>
23 #include <sfx2/basedlgs.hxx>
24 #include <sfx2/tabdlg.hxx>
25 
26 namespace svx
27 {
28 
30  {
31  private:
34 
35  std::unique_ptr<weld::Button> m_xNew;
36  std::unique_ptr<weld::Button> m_xEdit;
37  std::unique_ptr<weld::Button> m_xDelete;
38  std::unique_ptr<weld::TreeView> m_xPathBox;
39  std::unique_ptr<weld::TreeIter> m_xIter;
40 
41  DECL_LINK( NewHdl, weld::Button&, void );
42  DECL_LINK( EditHdl, weld::Button&, void );
43  DECL_LINK( DeleteHdl, weld::Button&, void );
44  DECL_LINK( PathBoxDoubleClickHdl, weld::TreeView&, bool);
45 
46  DECL_LINK( PathSelect_Impl, weld::TreeView&, void);
47 
48  DECL_LINK( HeaderSelect_Impl, int, void );
49  DECL_LINK( NameValidator, const OUString&, bool);
50 
57  void insertNewEntry( const OUString& _sName,const OUString& _sLocation, const bool bReadOnly );
58 
67  void openLinkDialog(const OUString& sOldName, const OUString& sOldLocation, int nEntry = -1);
68 
69  public:
71  virtual ~DbRegistrationOptionsPage() override;
72 
73  static std::unique_ptr<SfxTabPage> Create( weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rSet );
74 
75  virtual bool FillItemSet( SfxItemSet* rSet ) override;
76  virtual void Reset( const SfxItemSet* rSet ) override;
77  virtual void FillUserData() override;
78  };
79 
86  {
87  private:
89 
90  protected:
91  RegistrationItemSetHolder( const SfxItemSet& _rMasterSet );
93 
94  protected:
96  };
97 
100  {
101  public:
102  DatabaseRegistrationDialog(weld::Window* pParent, const SfxItemSet& rAttr);
103 
104  virtual short run() override;
105  };
106 }
107 
108 
109 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual short run() override
Definition: dbregister.cxx:68
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *rSet)
Definition: dbregister.cxx:119
void openLinkDialog(const OUString &sOldName, const OUString &sOldLocation, int nEntry=-1)
opens the LinkDialog to create a register pair
Definition: dbregister.cxx:267
sal_uIntPtr sal_uLong
std::unique_ptr< weld::Button > m_xNew
Definition: dbregister.hxx:35
std::unique_ptr< weld::TreeView > m_xPathBox
Definition: dbregister.hxx:38
virtual ~DbRegistrationOptionsPage() override
Definition: dbregister.cxx:113
void insertNewEntry(const OUString &_sName, const OUString &_sLocation, const bool bReadOnly)
inserts a new entry in the tablistbox
Definition: dbregister.cxx:256
virtual bool FillItemSet(SfxItemSet *rSet) override
Definition: dbregister.cxx:125
helper for DatabaseRegistrationDialog
Definition: dbregister.hxx:85
RegistrationItemSetHolder(const SfxItemSet &_rMasterSet)
Definition: dbregister.cxx:48
std::unique_ptr< weld::Button > m_xDelete
Definition: dbregister.hxx:37
std::unique_ptr< weld::Button > m_xEdit
Definition: dbregister.hxx:36
DatabaseRegistrationDialog(weld::Window *pParent, const SfxItemSet &rAttr)
Definition: dbregister.cxx:60
std::unique_ptr< weld::TreeIter > m_xIter
Definition: dbregister.hxx:39
virtual void Reset(const SfxItemSet *rSet) override
Definition: dbregister.cxx:150
DbRegistrationOptionsPage(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &rSet)
Definition: dbregister.cxx:82
DECL_LINK(NewHdl, weld::Button &, void)
virtual void FillUserData() override
Definition: dbregister.cxx:182
const SfxItemSet & getRegistrationItems() const
Definition: dbregister.hxx:95