]> git.lyx.org Git - lyx.git/blobdiff - src/lyx_gui_misc.C
remove more forms.h cruft
[lyx.git] / src / lyx_gui_misc.C
index e0762cd6a707c7ad49188b6d91d879de6f3f4a29..f6bd2605d5ad8b20e7370e494773e37e7d7463ce 100644 (file)
@@ -1,11 +1,10 @@
-// -*- C++ -*-
 /* This file is part of
  * ====================================================== 
  * 
  *           LyX, The Document Processor
  *        
  *           Copyright 1995 Matthias Ettrich
- *           Copyright 1995-2000 The LyX Team.
+ *           Copyright 1995-2001 The LyX Team.
  *
  * ====================================================== */
 
@@ -29,7 +28,6 @@
 #include "bufferview_funcs.h"
 #include "support/filetools.h"
 #include "lyxrc.h"
-#include "lyxfunc.h"
 
 using std::pair;
 using std::make_pair;
@@ -40,7 +38,6 @@ extern BufferView * current_view;
 extern FD_form_figure * fd_form_figure;
 extern FD_form_sendto * fd_form_sendto;
 extern FD_form_spell_check * fd_form_spell_check;
-extern FD_form_spell_options * fd_form_spell_options;
 
 extern void HideFiguresPopups();
 
@@ -63,10 +60,6 @@ void RedrawAllBufferRelatedDialogs()
            fd_form_spell_check->form_spell_check->visible) {
                fl_redraw_form(fd_form_spell_check->form_spell_check);
        }
-       if (fd_form_spell_options &&
-           fd_form_spell_options->form_spell_options->visible) {
-               fl_redraw_form(fd_form_spell_options->form_spell_options);
-       }
 }
 
 // Prevents LyX from crashing when no buffers available
@@ -139,17 +132,17 @@ char const * flyx_ident_extract(char const * sc)
 //
 void WriteAlert(string const & s1, string const & s2, string const & s3)
 {
-       LyXFunc * lfun = 0;
+       LyXView * lview = 0;
        if (current_view && current_view->owner())
-               lfun = current_view->owner()->getLyXFunc();
-       if (lfun) {
+               lview = current_view->owner();
+       if (lview) {
                /// Write to minibuffer
-               ProhibitInput(current_view);
+               lview->prohibitInput();
                string const msg = s1 + ' ' + s2 + ' ' + s3;
-               lfun->Dispatch(LFUN_MESSAGE, msg);
+               lview->message(msg);
                fl_set_resource("flAlert.dismiss.label", _("Dismiss"));
                fl_show_alert(s1.c_str(), s2.c_str(), s3.c_str(), 0);
-               AllowInput(current_view);
+               lview->allowInput();
        } else {
                /// Write to lyxerr
                lyxerr << "----------------------------------------" << endl