LibreOffice Module cui (master)  1
pastedlg.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_CUI_SOURCE_INC_PASTEDLG_HXX
21 #define INCLUDED_CUI_SOURCE_INC_PASTEDLG_HXX
22 
23 #include <map>
24 #include <sot/formats.hxx>
25 #include <tools/globname.hxx>
26 #include <vcl/transfer.hxx>
27 #include <vcl/weld.hxx>
28 
31 
33 {
34  std::map< SotClipboardFormatId, OUString > aSupplementMap;
35  // Additional UNO command to be displayed along the supported paste formats
36  std::pair<OUString, OUString> aExtraCommand;
38  OUString aObjName;
39 
40  std::unique_ptr<weld::Label> m_xFtObjectSource;
41  std::unique_ptr<weld::TreeView> m_xLbInsertList;
42  std::unique_ptr<weld::Button> m_xOKButton;
43 
45 
46  void SelectObject();
47  DECL_LINK(SelectHdl, weld::TreeView&, void);
48  DECL_LINK(DoubleClickHdl, weld::TreeView&, bool);
49 
50 public:
52 
53  void Insert( SotClipboardFormatId nFormat, const OUString & rFormatName );
54  void InsertUno( const OUString& sUnoCmd, const OUString& sLabel);
55  void SetObjName( const SvGlobalName & rClass, const OUString & rObjName );
60  void PreGetFormat( const TransferableDataHelper& aHelper);
72 };
73 
74 #endif // INCLUDED_CUI_SOURCE_INC_PASTEDLG_HXX
75 
76 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
void Insert(SotClipboardFormatId nFormat, const OUString &rFormatName)
Definition: pastedlg.cxx:70
weld::TreeView & ObjectLB()
Definition: pastedlg.hxx:44
void SetObjName(const SvGlobalName &rClass, const OUString &rObjName)
Definition: pastedlg.cxx:333
std::unique_ptr< weld::Button > m_xOKButton
Definition: pastedlg.hxx:42
void InsertUno(const OUString &sUnoCmd, const OUString &sLabel)
Definition: pastedlg.cxx:75
std::map< SotClipboardFormatId, OUString > aSupplementMap
Definition: pastedlg.hxx:34
DECL_LINK(SelectHdl, weld::TreeView &, void)
SvPasteObjectDialog(weld::Window *pParent)
Definition: pastedlg.cxx:32
SotClipboardFormatId GetFormat(const TransferableDataHelper &aHelper)
GetFormat Prepares and runs the dialog, and returns a SotClipboardFormatId depending on the RET_OK re...
Definition: pastedlg.cxx:201
SotClipboardFormatId
std::pair< OUString, OUString > aExtraCommand
Definition: pastedlg.hxx:36
SvGlobalName aObjClassName
Definition: pastedlg.hxx:37
void PreGetFormat(const TransferableDataHelper &aHelper)
PreGetFormat Prepares the dialog for running to get format of paste as a SotClipboardFormatId value b...
Definition: pastedlg.cxx:82
std::unique_ptr< weld::TreeView > m_xLbInsertList
Definition: pastedlg.hxx:41
SotClipboardFormatId GetFormatOnly()
GetFormatOnly Returns a SotClipboardFormatId value.
Definition: pastedlg.cxx:196
std::unique_ptr< weld::Label > m_xFtObjectSource
Definition: pastedlg.hxx:40