]> git.lyx.org Git - lyx.git/blobdiff - src/LyX.cpp
PrefShortcuts: Roughly finish the shortcut configuration panel
[lyx.git] / src / LyX.cpp
index 3c2dd305d889fdc70663413ad869f376b419cbca..85abc0f1d7d079908383a3d030ce91dc9d4a8c46 100644 (file)
@@ -89,9 +89,7 @@ using support::addName;
 using support::addPath;
 using support::bformat;
 using support::changeExtension;
-using support::createDirectory;
 using support::createLyXTmpDir;
-using support::destroyDir;
 using support::FileName;
 using support::fileSearch;
 using support::getEnv;
@@ -439,7 +437,7 @@ int LyX::exec(int & argc, char * argv[])
                bool final_success = false;
                for (BufferList::iterator I = begin; I != pimpl_->buffer_list_.end(); ++I) {
                        Buffer * buf = *I;
-                       if (buf != buf->getMasterBuffer())
+                       if (buf != buf->masterBuffer())
                                continue;
                        bool success = false;
                        buf->dispatch(batch_command, &success);
@@ -505,7 +503,7 @@ void LyX::prepareExit()
                LYXERR(Debug::INFO) << "Deleting tmp dir "
                                    << package().temp_dir().absFilename() << endl;
 
-               if (!destroyDir(package().temp_dir())) {
+               if (!package().temp_dir().destroyDirectory()) {
                        docstring const msg =
                                bformat(_("Unable to remove the temporary directory %1$s"),
                                from_utf8(package().temp_dir().absFilename()));
@@ -684,7 +682,7 @@ void LyX::restoreGuiSession()
        BufferList::iterator end = pimpl_->buffer_list_.end();
        for (; I != end; ++I) {
                Buffer * buf = *I;
-               if (buf != buf->getMasterBuffer())
+               if (buf != buf->masterBuffer())
                        continue;
                updateLabels(*buf);
        }
@@ -967,6 +965,8 @@ bool LyX::init()
        pimpl_->toplevel_keymap_.reset(new KeyMap);
        defaultKeyBindings(pimpl_->toplevel_keymap_.get());
        pimpl_->toplevel_keymap_->read(lyxrc.bind_file);
+       // load user bind file user.bind
+       pimpl_->toplevel_keymap_->read("user");
 
        pimpl_->lyxfunc_.initKeySequences(pimpl_->toplevel_keymap_.get());
 
@@ -1165,7 +1165,7 @@ bool LyX::queryUserLyXDir(bool explicit_userdir)
        lyxerr << to_utf8(bformat(_("LyX: Creating directory %1$s"),
                          from_utf8(sup.absFilename()))) << endl;
 
-       if (!createDirectory(sup, 0755)) {
+       if (!sup.createDirectory(0755)) {
                // Failed, so let's exit.
                lyxerr << to_utf8(_("Failed to create directory. Exiting."))
                       << endl;