Line data Source code
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 : #ifndef _SWRENAMEXNAMEDDLG_HXX
20 : #define _SWRENAMEXNAMEDDLG_HXX
21 :
22 :
23 : #include <vcl/dialog.hxx>
24 : #include <vcl/fixed.hxx>
25 : #include <vcl/edit.hxx>
26 : #include <vcl/button.hxx>
27 : #include <actctrl.hxx>
28 : #include <com/sun/star/frame/XController.hpp>
29 : #include <com/sun/star/text/XTextCursor.hpp>
30 : #include <com/sun/star/container/XNameAccess.hpp>
31 : #include <com/sun/star/awt/XControl.hpp>
32 : #include <com/sun/star/container/XNamed.hpp>
33 :
34 0 : class SwRenameXNamedDlg : public ModalDialog
35 : {
36 : FixedLine aNameFL;
37 : FixedText aNewNameFT;
38 : NoSpaceEdit aNewNameED;
39 : OKButton aOk;
40 : CancelButton aCancel;
41 : HelpButton aHelp;
42 :
43 : String sRemoveWarning;
44 :
45 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed > & xNamed;
46 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > & xNameAccess;
47 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > xSecondAccess;
48 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > xThirdAccess;
49 :
50 : DECL_LINK(OkHdl, void *);
51 : DECL_LINK(ModifyHdl, NoSpaceEdit*);
52 :
53 : public:
54 : SwRenameXNamedDlg( Window* pParent,
55 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed > & xNamed,
56 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > & xNameAccess );
57 :
58 0 : void SetForbiddenChars( const String& rSet )
59 0 : { aNewNameED.SetForbiddenChars( rSet ); }
60 :
61 0 : void SetAlternativeAccess(
62 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > & xSecond,
63 : ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > & xThird )
64 : {
65 0 : xSecondAccess = xSecond;
66 0 : xThirdAccess = xThird;
67 0 : }
68 : };
69 :
70 : #endif
71 :
72 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|