]> git.lyx.org Git - lyx.git/blob - src/frontends/controllers/ControlSendto.h
fix crash due to invalidated iterator
[lyx.git] / src / frontends / controllers / ControlSendto.h
1 // -*- C++ -*-
2 /**
3  * \file ControlSendto.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Angus Leeming
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef CONTROLSENDTO_H
13 #define CONTROLSENDTO_H
14
15 #include "Dialog.h"
16 #include <vector>
17
18 class Format;
19
20 namespace lyx {
21 namespace frontend {
22
23 /** A controller for the Custom Export dialogs.
24  */
25 class ControlSendto : public Dialog::Controller {
26 public:
27         ///
28         ControlSendto(Dialog &);
29         ///
30         virtual bool initialiseParams(std::string const & data);
31         ///
32         virtual void clearParams() {}
33         ///
34         virtual void dispatchParams();
35         ///
36         virtual bool isBufferDependent() const { return true; }
37         ///
38         virtual kb_action getLfun() const { return LFUN_EXPORT_CUSTOM; }
39
40         /// Return a vector of those formats that can be exported from "lyx".
41         std::vector<Format const *> const allFormats() const;
42
43         /// The format to export to
44         Format const * getFormat() { return format_; }
45         void setFormat(Format const *);
46
47         /// The command to be executed
48         std::string const getCommand() const { return command_; };
49         void setCommand(std::string const &);
50 private:
51         ///
52         Format const * format_;
53         ///
54         std::string command_;
55 };
56
57 } // namespace frontend
58 } // namespace lyx
59
60 #endif // CONTROLSENDTO_H