]> git.lyx.org Git - lyx.git/blob - src/frontends/controllers/ControlBranch.C
Small clean-up.
[lyx.git] / src / frontends / controllers / ControlBranch.C
1 /**
2  * \file ControlBranch.C
3  * This file is part of LyX, the document processor.
4  * Licence details can be found in the file COPYING.
5  *
6  * \author Angus Leeming
7  * \author Martin Vermeer
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #include <config.h>
13
14 #include "ControlBranch.h"
15 #include "funcrequest.h"
16 #include "insets/insetbranch.h"
17
18 ControlBranch::ControlBranch(Dialog & parent)
19         : Dialog::Controller(parent)
20 {}
21
22
23 bool ControlBranch::initialiseParams(string const & data)
24 {
25         InsetBranchParams params;
26         InsetBranchMailer::string2params(data, params);
27         params_.reset(new InsetBranchParams(params));
28
29         return true;
30 }
31
32
33 void ControlBranch::clearParams()
34 {
35         params_.reset();
36 }
37
38 void ControlBranch::dispatchParams()
39 {
40         string const lfun = InsetBranchMailer::params2string(string("branch"), params());
41         kernel().dispatch(FuncRequest(LFUN_INSET_APPLY, lfun));
42 }
43