1 /* This file is part of
2 * ======================================================
4 * LyX, The Document Processor
6 * Copyright 2001 The LyX Team.
8 * ======================================================
10 * \file ControlBibtex.C
11 * \author John Levon, moz@compsoc.man.ac.uk
12 * \author Angus Leeming <a.leeming@ic.ac.uk>
18 #pragma implementation
23 #include "ButtonControllerBase.h"
24 #include "ControlBibtex.h"
28 #include "BufferView.h"
32 ControlBibtex::ControlBibtex(LyXView & lv, Dialogs & d)
33 : ControlCommand(lv, d)
35 d_.showBibtex.connect(slot(this, &ControlBibtex::showInset));
38 void ControlBibtex::applyParamsToInset()
40 if (params().getContents() != inset()->params().getContents())
41 lv_.view()->ChangeCitationsIfUnique(inset()->params().getContents(),
42 params().getContents());
44 inset()->setParams(params());
45 lv_.view()->updateInset(inset(), true);
47 // We need to do a redraw because the maximum
48 // InsetBibKey width could have changed
50 lv_.view()->fitCursor(lv_.view()->getLyXText());
54 void ControlBibtex::applyParamsNoInset()