bump product version to 5.0.4.1
[LibreOffice.git] / extensions / source / abpilot / typeselectionpage.hxx
blobb5d4dad096cbbd7a9c5a49ad0c3c87c4bd071253
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 .
20 #ifndef INCLUDED_EXTENSIONS_SOURCE_ABPILOT_TYPESELECTIONPAGE_HXX
21 #define INCLUDED_EXTENSIONS_SOURCE_ABPILOT_TYPESELECTIONPAGE_HXX
23 #include "abspage.hxx"
24 #include "addresssettings.hxx"
25 #include <vcl/edit.hxx>
26 #include <vcl/vclptr.hxx>
29 namespace abp
32 class TypeSelectionPage : public AddressBookSourcePage
34 protected:
35 VclPtr<RadioButton> m_pEvolution;
36 VclPtr<RadioButton> m_pEvolutionGroupwise;
37 VclPtr<RadioButton> m_pEvolutionLdap;
38 VclPtr<RadioButton> m_pMORK;
39 VclPtr<RadioButton> m_pThunderbird;
40 VclPtr<RadioButton> m_pKab;
41 VclPtr<RadioButton> m_pMacab;
42 VclPtr<RadioButton> m_pLDAP;
43 VclPtr<RadioButton> m_pOutlook;
44 VclPtr<RadioButton> m_pOE;
45 VclPtr<RadioButton> m_pOther;
47 struct ButtonItem {
48 VclPtr<RadioButton> m_pItem;
49 AddressSourceType m_eType;
50 bool m_bVisible;
52 ButtonItem( RadioButton *pItem,
53 AddressSourceType eType,
54 bool bVisible ) :
55 m_pItem( pItem ),
56 m_eType( eType ),
57 m_bVisible( bVisible )
61 ::std::vector< ButtonItem > m_aAllTypes;
63 public:
64 TypeSelectionPage( OAddessBookSourcePilot* _pParent );
65 virtual ~TypeSelectionPage();
66 virtual void dispose() SAL_OVERRIDE;
68 // retrieves the currently selected type
69 AddressSourceType getSelectedType() const;
71 protected:
72 // OWizardPage overridables
73 virtual void initializePage() SAL_OVERRIDE;
74 virtual bool commitPage( ::svt::WizardTypes::CommitPageReason _eReason ) SAL_OVERRIDE;
76 // TabDialog overridables
77 virtual void ActivatePage() SAL_OVERRIDE;
78 virtual void DeactivatePage() SAL_OVERRIDE;
80 // OImportPage overridables
81 virtual bool canAdvance() const SAL_OVERRIDE;
83 private:
84 DECL_LINK( OnTypeSelected, void* );
86 void selectType( AddressSourceType _eType );
90 } // namespace abp
93 #endif // INCLUDED_EXTENSIONS_SOURCE_ABPILOT_TYPESELECTIONPAGE_HXX
95 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */