Version 5.2.6.1, tag libreoffice-5.2.6.1
[LibreOffice.git] / dbaccess / source / ui / inc / WNameMatch.hxx
blob4b4a3f3aeefd56f1ad3d42d7669eb7c4f910250d
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 .
19 #ifndef INCLUDED_DBACCESS_SOURCE_UI_INC_WNAMEMATCH_HXX
20 #define INCLUDED_DBACCESS_SOURCE_UI_INC_WNAMEMATCH_HXX
22 #include "WTabPage.hxx"
23 #include "marktree.hxx"
24 #include "DExport.hxx"
25 #include <vcl/fixed.hxx>
26 #include <vcl/button.hxx>
27 #include "WCopyTable.hxx"
29 namespace dbaui
31 // columns are at root only no children
32 class OColumnTreeBox : public OMarkableTreeListBox
34 bool m_bReadOnly;
35 protected:
36 virtual void InitEntry(SvTreeListEntry* pEntry, const OUString& rStr, const Image& rImg1, const Image& rImg2, SvLBoxButtonKind eButtonKind) override;
38 public:
39 OColumnTreeBox( vcl::Window* pParent, WinBits nBits = WB_BORDER );
41 void FillListBox( const ODatabaseExport::TColumnVector& _rList);
42 void SetReadOnly() { m_bReadOnly = true; }
43 virtual bool Select( SvTreeListEntry* pEntry, bool bSelect=true ) override;
45 private:
46 using OMarkableTreeListBox::Select;
49 // Wizard Page: OWizNameMatching
50 // Name matching for data appending
51 class OWizNameMatching : public OWizardPage
53 VclPtr<FixedText> m_pTABLE_LEFT;
54 VclPtr<FixedText> m_pTABLE_RIGHT;
55 VclPtr<OColumnTreeBox> m_pCTRL_LEFT; // left side
56 VclPtr<OColumnTreeBox> m_pCTRL_RIGHT; // right side
57 VclPtr<PushButton> m_pColumn_up;
58 VclPtr<PushButton> m_pColumn_down;
59 VclPtr<PushButton> m_pColumn_up_right;
60 VclPtr<PushButton> m_pColumn_down_right;
61 VclPtr<PushButton> m_pAll;
62 VclPtr<PushButton> m_pNone;
63 OUString m_sSourceText;
64 OUString m_sDestText;
65 Image m_aImgUp;
66 Image m_aImgDown;
68 DECL_LINK_TYPED( ButtonClickHdl, Button *, void );
69 DECL_LINK_TYPED( RightButtonClickHdl, Button *, void );
70 DECL_LINK_TYPED( AllNoneClickHdl, Button *, void );
71 DECL_LINK_TYPED( TableListClickHdl, SvTreeListBox*, void );
72 DECL_LINK_TYPED( TableListRightSelectHdl, SvTreeListBox*, void );
74 public:
75 virtual void Reset ( ) override;
76 virtual void ActivatePage() override;
77 virtual bool LeavePage() override;
78 virtual OUString GetTitle() const override ;
80 OWizNameMatching(vcl::Window* pParent);
81 virtual ~OWizNameMatching();
82 virtual void dispose() override;
85 #endif // INCLUDED_DBACCESS_SOURCE_UI_INC_WNAMEMATCH_HXX
87 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */