mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Re-enable input of non-LyX files (e.g., tex, pgf) (#12056)
This amends [a385b7dc2b58/lyxgit] (cherry picked from commit2af8e661a3
) (cherry picked from commit17e4f325f3
)
This commit is contained in:
parent
6226a040d4
commit
5b69d658bb
@ -317,14 +317,17 @@ bool GuiInclude::isValid()
|
|||||||
okPB->setText(qt_("&OK"));
|
okPB->setText(qt_("&OK"));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
// Do we have a LyX filename?
|
|
||||||
if (!isLyXFileName(fromqstr(fname))) {
|
|
||||||
okPB->setText(qt_("&OK"));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
string const bpath = buffer().filePath();
|
string const bpath = buffer().filePath();
|
||||||
// Path might be relative to current Buffer, so make absolute
|
// Path might be relative to current Buffer, so make absolute
|
||||||
FileName const absfname = support::makeAbsPath(fromqstr(fname), bpath);
|
FileName const absfname = support::makeAbsPath(fromqstr(fname), bpath);
|
||||||
|
|
||||||
|
// Do we have a LyX filename?
|
||||||
|
if (!isLyXFileName(fromqstr(fname))) {
|
||||||
|
okPB->setText(qt_("&OK"));
|
||||||
|
return absfname.exists();
|
||||||
|
}
|
||||||
|
|
||||||
// Set OK button text according to whether file already exists
|
// Set OK button text according to whether file already exists
|
||||||
okPB->setText(absfname.exists() ? qt_("&OK") : qt_("&Create"));
|
okPB->setText(absfname.exists() ? qt_("&OK") : qt_("&Create"));
|
||||||
// enable edit button iff file is open in some Buffer
|
// enable edit button iff file is open in some Buffer
|
||||||
|
@ -76,11 +76,13 @@ What's new
|
|||||||
|
|
||||||
* USER INTERFACE
|
* USER INTERFACE
|
||||||
|
|
||||||
- Fix crash when pasting math grid with more rows in source than target
|
- Re-enable input of non-LyX files (e.g., tex, pgf) (bug 12056).
|
||||||
(bug 11897).
|
|
||||||
|
|
||||||
- Fix problem with display of menus on Gnome Wayland (bug 11746).
|
- Fix problem with display of menus on Gnome Wayland (bug 11746).
|
||||||
|
|
||||||
|
- Fix crash when pasting math grid with more rows in source than target
|
||||||
|
(bug 11897).
|
||||||
|
|
||||||
- Fix problem with drawing of auto-opened insets (bug 11870).
|
- Fix problem with drawing of auto-opened insets (bug 11870).
|
||||||
|
|
||||||
- Fix crash when rejecting changes and the cursor is in an inset that will be
|
- Fix crash when rejecting changes and the cursor is in an inset that will be
|
||||||
|
Loading…
Reference in New Issue
Block a user