]> git.lyx.org Git - lyx.git/blob - src/frontends/xforms/FormInset.h
change some __GNUG_ to __GNUG__
[lyx.git] / src / frontends / xforms / FormInset.h
1 // -*- C++ -*-
2 /**
3  * \file FormInset.h
4  * Copyright 2000-2001 the LyX Team
5  * Read the file COPYING
6  *
7  * \author Angus Leeming, a.leeming@ic.ac.uk
8  */
9
10 /* A base class for dialogs connected to insets. This class is temporary in that
11  * it has been superceeded by the controller-view split.
12  */
13
14 #ifndef FORMCOMMAND_H
15 #define FORMCOMMAND_H
16
17 #include "FormBaseDeprecated.h"
18 #include "insets/insetcommand.h"
19
20 #ifdef __GNUG__
21 #pragma interface
22 #endif
23
24
25 /** This class is an XForms GUI base class to insets
26  */
27 class FormInset : public FormBaseBD {
28 protected:
29         /// Constructor
30         FormInset(LyXView *, Dialogs *, string const &);
31
32         /// Connect signals. Also perform any necessary initialisation.
33         virtual void connect();
34         /// Disconnect signals. Also perform any necessary housekeeping.
35         virtual void disconnect();
36
37         /// bool indicates if a buffer switch took place
38         virtual void updateSlot(bool);
39
40         /// inset::hide connection.
41         SigC::Connection ih_;
42 };
43
44
45 /** This class is an XForms GUI base class to insets derived from
46     InsetCommand
47  */
48 class FormCommand : public FormInset {
49 protected:
50         /// Constructor
51         FormCommand(LyXView *, Dialogs *, string const &);
52
53         /// Disconnect signals. Also perform any necessary housekeeping.
54         virtual void disconnect();
55
56         /// Slot launching dialog to (possibly) create a new inset
57         void createInset(string const &);
58         /// Slot launching dialog to an existing inset
59         void showInset(InsetCommand *);
60
61         /// pointer to the inset passed through showInset
62         InsetCommand * inset_;
63         /// the nitty-griity. What is modified and passed back
64         InsetCommandParams params;
65 };
66
67 #endif