]> git.lyx.org Git - lyx.git/blob - src/frontends/controllers/ControlInclude.h
Fixed bugs in getStringFromVector, getVectorFromString
[lyx.git] / src / frontends / controllers / ControlInclude.h
1 /**
2  * \file ControlInclude.h
3  * Copyright 2001 the LyX Team
4  * See the file COPYING
5  *
6  * \author Alejandro Aguilar Sierra
7  * \author John Levon, moz@compsoc.man.ac.uk
8  * \author Angus Leeming, a.leeming@.ac.uk
9  */
10
11 #ifndef CONTROLINCLUDE_H
12 #define CONTROLINCLUDE_H
13
14 #ifdef __GNUG__
15 #pragma interface
16 #endif
17
18 #include "ControlInset.h"
19 #include "insets/insetinclude.h" // InsetIncludeParams
20
21 /** A controller for the Include file dialog.
22  */
23 class ControlInclude
24         : public ControlInset<InsetInclude, InsetInclude::Params>
25 {
26 public:
27         ///
28         enum Type {
29                 ///
30                 INPUT,
31                 ///
32                 VERBATIM,
33                 ///
34                 INCLUDE
35         };
36         ///
37         ControlInclude(LyXView &, Dialogs &);
38
39         /// Browse for a file
40         string const Browse(string const &, Type);
41
42 private:
43         /// Dispatch the changed parameters to the kernel.
44         virtual void applyParamsToInset();
45         /// Should be used but currently isn't
46         virtual void applyParamsNoInset() {}
47         /// get the parameters from the string passed to createInset.
48         virtual InsetInclude::Params const getParams(string const &)
49                 { return InsetInclude::Params(); }
50         /// get the parameters from the inset passed to showInset.
51         virtual InsetInclude::Params const getParams(InsetInclude const & inset)
52                 { return inset.params(); }
53 };
54 #endif // CONTROLINCLUDE_H