bump product version to 5.0.4.1
[LibreOffice.git] / cui / source / options / optinet2.hxx
blobc23dc7be8c87c76f82eb1d39f5e2a7bdf9e2337e
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_CUI_SOURCE_OPTIONS_OPTINET2_HXX
20 #define INCLUDED_CUI_SOURCE_OPTIONS_OPTINET2_HXX
22 #include <com/sun/star/lang/XMultiServiceFactory.hpp>
23 #include <vcl/field.hxx>
24 #include <vcl/group.hxx>
25 #include <vcl/layout.hxx>
26 #include <vcl/lstbox.hxx>
27 #include <svtools/stdctrl.hxx>
28 #include <svtools/svtabbx.hxx>
29 #include <sfx2/tabdlg.hxx>
30 #include <unotools/configitem.hxx>
32 #include <svtools/headbar.hxx>
34 namespace svx {
35 class SecurityOptionsDialog;
39 // class SvxNoSpaceEdit --------------------------------------------------
41 class SvxNoSpaceEdit : public Edit
43 private:
44 bool bOnlyNumeric;
45 public:
46 SvxNoSpaceEdit(vcl::Window* pParent, WinBits nStyle)
47 : Edit(pParent, nStyle)
48 , bOnlyNumeric(false)
50 virtual void KeyInput(const KeyEvent& rKEvent) SAL_OVERRIDE;
51 virtual void Modify() SAL_OVERRIDE;
52 virtual bool set_property(const OString &rKey, const OString &rValue) SAL_OVERRIDE;
55 // class SvxProxyTabPage -------------------------------------------------
57 class SvxProxyTabPage : public SfxTabPage
59 private:
61 VclPtr<ListBox> m_pProxyModeLB;
63 VclPtr<FixedText> m_pHttpProxyFT;
64 VclPtr<SvxNoSpaceEdit> m_pHttpProxyED;
65 VclPtr<FixedText> m_pHttpPortFT;
66 VclPtr<SvxNoSpaceEdit> m_pHttpPortED;
68 VclPtr<FixedText> m_pHttpsProxyFT;
69 VclPtr<SvxNoSpaceEdit> m_pHttpsProxyED;
70 VclPtr<FixedText> m_pHttpsPortFT;
71 VclPtr<SvxNoSpaceEdit> m_pHttpsPortED;
73 VclPtr<FixedText> m_pFtpProxyFT;
74 VclPtr<SvxNoSpaceEdit> m_pFtpProxyED;
75 VclPtr<FixedText> m_pFtpPortFT;
76 VclPtr<SvxNoSpaceEdit> m_pFtpPortED;
78 VclPtr<FixedText> m_pNoProxyForFT;
79 VclPtr<Edit> m_pNoProxyForED;
80 VclPtr<FixedText> m_pNoProxyDescFT;
82 const OUString aProxyModePN;
83 const OUString aHttpProxyPN;
84 const OUString aHttpPortPN;
85 const OUString aHttpsProxyPN;
86 const OUString aHttpsPortPN;
87 const OUString aFtpProxyPN;
88 const OUString aFtpPortPN;
89 const OUString aNoProxyDescPN;
91 css::uno::Reference< css::uno::XInterface > m_xConfigurationUpdateAccess;
93 void EnableControls_Impl(bool bEnable);
94 void ReadConfigData_Impl();
95 void ReadConfigDefaults_Impl();
96 void RestoreConfigDefaults_Impl();
98 DECL_LINK( ProxyHdl_Impl, ListBox * );
99 DECL_STATIC_LINK( SvxProxyTabPage, LoseFocusHdl_Impl, Edit * );
101 public:
102 SvxProxyTabPage( vcl::Window* pParent, const SfxItemSet& rSet );
103 virtual ~SvxProxyTabPage();
104 virtual void dispose() SAL_OVERRIDE;
105 static VclPtr<SfxTabPage> Create( vcl::Window* pParent, const SfxItemSet* rAttrSet );
106 virtual bool FillItemSet( SfxItemSet* rSet ) SAL_OVERRIDE;
107 virtual void Reset( const SfxItemSet* rSet ) SAL_OVERRIDE;
110 // #98647# class SvxScriptExecListBox ------------------------------------
111 class SvxScriptExecListBox : public ListBox
112 { // for adding tooltips to ListBox
113 public:
114 SvxScriptExecListBox( vcl::Window* pParent, WinBits nStyle = WB_BORDER )
115 :ListBox(pParent, nStyle) {}
116 SvxScriptExecListBox( vcl::Window* pParent, const ResId& rResId )
117 :ListBox(pParent, rResId) {}
119 protected:
120 virtual void RequestHelp( const HelpEvent& rHEvt ) SAL_OVERRIDE;
123 // class SvxSecurityTabPage ---------------------------------------------
125 class SvtSecurityOptions;
126 class CertPathDialog;
127 class SvxSecurityTabPage : public SfxTabPage
129 using TabPage::ActivatePage;
130 using TabPage::DeactivatePage;
131 friend class VclPtr<SvxSecurityTabPage>;
132 private:
133 VclPtr<PushButton> m_pSecurityOptionsPB;
135 VclPtr<CheckBox> m_pSavePasswordsCB;
136 VclPtr<PushButton> m_pShowConnectionsPB;
138 VclPtr<CheckBox> m_pMasterPasswordCB;
139 VclPtr<FixedText> m_pMasterPasswordFT;
140 VclPtr<PushButton> m_pMasterPasswordPB;
142 VclPtr<VclContainer> m_pMacroSecFrame;
143 VclPtr<PushButton> m_pMacroSecPB;
145 VclPtr<VclContainer> m_pCertFrame;
146 VclPtr<PushButton> m_pCertPathPB;
148 VclPtr<VclContainer> m_pTSAURLsFrame;
149 VclPtr<PushButton> m_pTSAURLsPB;
151 SvtSecurityOptions* mpSecOptions;
152 VclPtr<svx::SecurityOptionsDialog> mpSecOptDlg;
154 VclPtr<CertPathDialog> mpCertPathDlg;
156 OUString m_sPasswordStoringDeactivateStr;
158 DECL_LINK(SecurityOptionsHdl, void *);
159 DECL_LINK(SavePasswordHdl, void* );
160 DECL_STATIC_LINK(SvxSecurityTabPage, MasterPasswordHdl, void *);
161 DECL_LINK(MasterPasswordCBHdl, void* );
162 DECL_LINK(ShowPasswordsHdl, void *);
163 DECL_STATIC_LINK(SvxSecurityTabPage, MacroSecPBHdl, void* );
164 DECL_LINK(CertPathPBHdl, void* );
165 DECL_LINK(TSAURLsPBHdl, void* );
167 void InitControls();
169 SvxSecurityTabPage( vcl::Window* pParent, const SfxItemSet& rSet );
170 virtual ~SvxSecurityTabPage();
171 virtual void dispose() SAL_OVERRIDE;
173 protected:
174 virtual void ActivatePage( const SfxItemSet& rSet ) SAL_OVERRIDE;
175 virtual sfxpg DeactivatePage( SfxItemSet* pSet = 0 ) SAL_OVERRIDE;
177 public:
178 static VclPtr<SfxTabPage> Create( vcl::Window* pParent, const SfxItemSet* rAttrSet );
179 virtual bool FillItemSet( SfxItemSet* rSet ) SAL_OVERRIDE;
180 virtual void Reset( const SfxItemSet* rSet ) SAL_OVERRIDE;
183 struct SvxEMailTabPage_Impl;
184 class SvxEMailTabPage : public SfxTabPage
186 VclPtr<VclContainer> m_pMailContainer;
187 VclPtr<FixedImage> m_pMailerURLFI;
188 VclPtr<Edit> m_pMailerURLED;
189 VclPtr<PushButton> m_pMailerURLPB;
190 VclPtr<VclContainer> m_pSuppressHiddenContainer;
191 VclPtr<FixedImage> m_pSuppressHiddenFI;
192 VclPtr<CheckBox> m_pSuppressHidden;
194 OUString m_sDefaultFilterName;
196 SvxEMailTabPage_Impl* pImpl;
198 DECL_LINK( FileDialogHdl_Impl, PushButton* ) ;
200 public:
201 SvxEMailTabPage( vcl::Window* pParent, const SfxItemSet& rSet );
202 virtual ~SvxEMailTabPage();
203 virtual void dispose() SAL_OVERRIDE;
205 static VclPtr<SfxTabPage> Create( vcl::Window* pParent, const SfxItemSet* rAttrSet );
207 virtual bool FillItemSet( SfxItemSet* rSet ) SAL_OVERRIDE;
208 virtual void Reset( const SfxItemSet* rSet ) SAL_OVERRIDE;
211 #endif // INCLUDED_CUI_SOURCE_OPTIONS_OPTINET2_HXX
214 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */