LibreOffice Module sc (master)  1
linkarea.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 #ifndef INCLUDED_SC_SOURCE_UI_INC_LINKAREA_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_LINKAREA_HXX
22 
23 #include <sfx2/objsh.hxx>
24 #include <tools/solar.h>
25 #include <vcl/weld.hxx>
26 
27 namespace sfx2 { class DocumentInserter; }
28 namespace sfx2 { class FileDialogHelper; }
29 
30 class ScDocShell;
31 class SvtURLBox;
32 
34 {
35 private:
37  std::unique_ptr<sfx2::DocumentInserter> m_xDocInserter;
39 
40  std::unique_ptr<SvtURLBox> m_xCbUrl;
41  std::unique_ptr<weld::Button> m_xBtnBrowse;
42  std::unique_ptr<weld::TreeView> m_xLbRanges;
43  std::unique_ptr<weld::CheckButton> m_xBtnReload;
44  std::unique_ptr<weld::SpinButton> m_xNfDelay;
45  std::unique_ptr<weld::Label> m_xFtSeconds;
46  std::unique_ptr<weld::Button> m_xBtnOk;
47 
48  DECL_LINK(FileHdl, weld::ComboBox&, bool);
49  DECL_LINK(BrowseHdl, weld::Button&, void);
50  DECL_LINK(RangeHdl, weld::TreeView&, void);
51  DECL_LINK(ReloadHdl, weld::Button&, void);
52  DECL_LINK(DialogClosedHdl, sfx2::FileDialogHelper*, void);
53 
54  void UpdateSourceRanges();
55  void UpdateEnable();
56  void LoadDocument( const OUString& rFile, const OUString& rFilter,
57  const OUString& rOptions );
58 
59 public:
60  ScLinkedAreaDlg(weld::Window* pParent);
61  virtual ~ScLinkedAreaDlg() override;
62 
63  void InitFromOldLink( const OUString& rFile, const OUString& rFilter,
64  const OUString& rOptions, const OUString& rSource,
65  sal_uLong nRefresh );
66 
67  OUString GetURL() const;
68  OUString GetFilter() const; // may be empty
69  OUString GetOptions() const; // filter options
70  OUString GetSource() const; // separated by ";"
71  sal_uLong GetRefresh() const; // 0 if disabled
72 };
73 
74 #endif
75 
76 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
OUString GetFilter() const
Definition: linkarea.cxx:291
sal_uLong GetRefresh() const
Definition: linkarea.cxx:324
virtual ~ScLinkedAreaDlg() override
Definition: linkarea.cxx:60
std::unique_ptr< weld::TreeView > m_xLbRanges
Definition: linkarea.hxx:42
sal_uIntPtr sal_uLong
std::unique_ptr< sfx2::DocumentInserter > m_xDocInserter
Definition: linkarea.hxx:37
std::unique_ptr< weld::SpinButton > m_xNfDelay
Definition: linkarea.hxx:44
std::unique_ptr< weld::Button > m_xBtnBrowse
Definition: linkarea.hxx:41
void UpdateSourceRanges()
Definition: linkarea.cxx:239
std::unique_ptr< weld::Label > m_xFtSeconds
Definition: linkarea.hxx:45
void LoadDocument(const OUString &rFile, const OUString &rFilter, const OUString &rOptions)
Definition: linkarea.cxx:105
void InitFromOldLink(const OUString &rFile, const OUString &rFilter, const OUString &rOptions, const OUString &rSource, sal_uLong nRefresh)
Definition: linkarea.cxx:138
ScDocShell * m_pSourceShell
Definition: linkarea.hxx:36
OUString GetOptions() const
Definition: linkarea.cxx:301
std::unique_ptr< weld::Button > m_xBtnOk
Definition: linkarea.hxx:46
SfxObjectShellRef aSourceRef
Definition: linkarea.hxx:38
ScLinkedAreaDlg(weld::Window *pParent)
Definition: linkarea.cxx:38
DECL_LINK(FileHdl, weld::ComboBox &, bool)
OUString GetSource() const
Definition: linkarea.cxx:311
std::unique_ptr< weld::CheckButton > m_xBtnReload
Definition: linkarea.hxx:43
OUString GetURL() const
Definition: linkarea.cxx:281
void UpdateEnable()
Definition: linkarea.cxx:271
std::unique_ptr< SvtURLBox > m_xCbUrl
Definition: linkarea.hxx:40