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 :
20 : #ifndef INCLUDED_DBACCESS_SOURCE_UI_APP_IAPPLICATIONCONTROLLER_HXX
21 : #define INCLUDED_DBACCESS_SOURCE_UI_APP_IAPPLICATIONCONTROLLER_HXX
22 :
23 : #include <dbaccess/IController.hxx>
24 : #include "AppElementType.hxx"
25 : #include "callbacks.hxx"
26 :
27 : class SvTreeListBox;
28 :
29 : namespace dbaui
30 : {
31 :
32 8 : class SAL_NO_VTABLE IApplicationController :public IController
33 : ,public IControlActionListener
34 : ,public IContextMenuProvider
35 : {
36 : public:
37 : /** called when an entry in a tree list box has been double-clicked
38 : @param _rTree
39 : The tree list box.
40 : @return
41 : <TRUE/> if the double click event has been handled by the called, and should not
42 : be processed further.
43 : */
44 : virtual bool onEntryDoubleClick( SvTreeListBox& _rTree ) = 0;
45 :
46 : /** called when a container (category) in the application view has been selected
47 : @param _pTree
48 : The tree list box.
49 : @return
50 : <TRUE/> if the cotainer could be changed otherwise <FALSE/>
51 : */
52 : virtual bool onContainerSelect(ElementType _eType) = 0;
53 :
54 : /** called when an entry in a tree view has been selected
55 : @param _pEntry
56 : the selected entry
57 : */
58 : virtual void onSelectionChanged() = 0;
59 :
60 : /** called when a "Cut" command is executed in a tree view
61 : */
62 : virtual void onCutEntry() = 0;
63 :
64 : /** called when a "Copy" command is executed in a tree view
65 : */
66 : virtual void onCopyEntry() = 0;
67 :
68 : /** called when a "Paste" command is executed in a tree view
69 : */
70 : virtual void onPasteEntry() = 0;
71 :
72 : /** called when a "Delete" command is executed in a tree view
73 : */
74 : virtual void onDeleteEntry() = 0;
75 :
76 : /// called when the preview mode was changed
77 : virtual void previewChanged( sal_Int32 _nMode ) = 0;
78 :
79 : /// called when an object container of any kind was found during enumerating tree view elements
80 : virtual void containerFound( const ::com::sun::star::uno::Reference< ::com::sun::star::container::XContainer >& _xContainer) = 0;
81 :
82 : protected:
83 6 : ~IApplicationController() {}
84 : };
85 :
86 : } // namespace dbaui
87 :
88 : #endif // INCLUDED_DBACCESS_SOURCE_UI_APP_IAPPLICATIONCONTROLLER_HXX
89 :
90 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|