]> git.lyx.org Git - features.git/blob - src/frontends/gnome/GUIRunTime_pimpl.C
47f615855b8b728b0f6657005e531452b827b3ae
[features.git] / src / frontends / gnome / GUIRunTime_pimpl.C
1 /* This file is part of
2  * ======================================================
3  * 
4  *           LyX, The Document Processor
5  *       
6  *           Copyright (C) 2000 The LyX Team.
7  *
8  *           @author Jürgen Vigna
9  *
10  *======================================================*/
11
12 #include <config.h>
13
14 #ifdef __GNUG__
15 #pragma implementation
16 #endif
17
18 #include FORMS_H_LOCATION
19
20 #include "GUIRunTime_pimpl.h"
21 #include "debug.h"
22
23 #include <gnome--/main.h>
24
25 using std::endl;
26
27 extern bool finished;
28
29 void GUIRunTime::Pimpl::processEvents() 
30 {
31     while(Gnome::Main::instance()->events_pending())
32         Gnome::Main::instance()->iteration(FALSE);
33 }
34
35
36 void GUIRunTime::Pimpl::runTime()
37 {
38         XEvent ev;
39         while (!finished) {
40                 Pimpl::processEvents();
41                 if (fl_check_forms() == FL_EVENT) {
42                         lyxerr << "LyX: This shouldn't happen..." << endl;
43                         fl_XNextEvent(&ev);
44                 }
45         }
46 }