]> git.lyx.org Git - features.git/commitdiff
Remove bug work around due to bad event loop startup process in 1.5.
authorAbdelrazak Younes <younes@lyx.org>
Mon, 2 Jun 2008 14:19:39 +0000 (14:19 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Mon, 2 Jun 2008 14:19:39 +0000 (14:19 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25071 a592a061-630c-0410-9148-cb99ea01b6c8

src/LyX.cpp
src/LyX.h
src/frontends/qt4/GuiApplication.cpp

index c41d16579a561f329df155573e14ad54ddd6b3b1..ed841793462149ca012a6525d5dac75b64106863 100644 (file)
@@ -524,17 +524,6 @@ int LyX::init(int & argc, char * argv[])
 }
 
 
-void LyX::addFileToLoad(string const & fname)
-{
-       vector<string>::const_iterator cit = find(
-               pimpl_->files_to_load_.begin(), pimpl_->files_to_load_.end(),
-               fname);
-
-       if (cit == pimpl_->files_to_load_.end())
-               pimpl_->files_to_load_.push_back(fname);
-}
-
-
 bool LyX::loadFiles()
 {
        LASSERT(!use_gui, /**/);
index cee66fa102a9c06cf1c89f5df75399372fb36ab8..1ec91435710f3fb75b20d776556cc6e6cbd94141 100644 (file)
--- a/src/LyX.h
+++ b/src/LyX.h
@@ -99,9 +99,6 @@ public:
        /// Execute batch commands if available.
        void execBatchCommands();
 
-       ///
-       void addFileToLoad(std::string const &);
-
 private:
        /// noncopyable
        LyX(LyX const &);
index 104f69a0b352a9f7f695e5b1f427a65b386b3121..732d25ff67290cd0abe38ca010355677b1b03033 100644 (file)
@@ -865,17 +865,8 @@ bool GuiApplication::event(QEvent * e)
        case QEvent::FileOpen: {
                // Open a file; this happens only on Mac OS X for now
                QFileOpenEvent * foe = static_cast<QFileOpenEvent *>(e);
-
-               if (!current_view_ || !current_view_->view())
-                       // The application is not properly initialized yet.
-                       // So we acknowledge the event and delay the file opening
-                       // until LyX is ready.
-                       // FIXME UNICODE: FileName accept an utf8 encoded string.
-                       LyX::ref().addFileToLoad(fromqstr(foe->file()));
-               else
-                       lyx::dispatch(FuncRequest(LFUN_FILE_OPEN,
-                               qstring_to_ucs4(foe->file())));
-
+               lyx::dispatch(FuncRequest(LFUN_FILE_OPEN,
+                       qstring_to_ucs4(foe->file())));
                e->accept();
                return true;
        }