mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-23 13:31:49 +00:00
Avoid calling prefixIs() if not needed.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29824 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d1ebeea288
commit
7ae4f6ac6f
@ -185,7 +185,7 @@ bool path_prefix_is(string & path, string const & pre, path_case how)
|
||||
if (i + 1 != p2.length())
|
||||
return false;
|
||||
|
||||
if (!prefixIs(path, pre) && how == CASE_ADJUSTED)
|
||||
if (how == CASE_ADJUSTED && !prefixIs(path, pre))
|
||||
path = to_utf8(p2 + p1.substr(i + 1, p1.length() - i + 1));
|
||||
|
||||
return true;
|
||||
|
@ -98,7 +98,7 @@ bool path_prefix_is(string & path, string const & pre, path_case how)
|
||||
if (i + 1 != p2.length())
|
||||
return false;
|
||||
|
||||
if (!prefixIs(path, pre) && how == CASE_ADJUSTED)
|
||||
if (how == CASE_ADJUSTED && !prefixIs(path, pre))
|
||||
path = to_utf8(p2 + p1.substr(i + 1, p1.length() - i + 1));
|
||||
|
||||
return true;
|
||||
|
@ -216,7 +216,7 @@ bool path_prefix_is(string & path, string const & pre, path_case how)
|
||||
if (i + 1 != p2.length())
|
||||
return false;
|
||||
|
||||
if (!prefixIs(path, pre) && how == CASE_ADJUSTED)
|
||||
if (how == CASE_ADJUSTED && !prefixIs(path, pre))
|
||||
path = to_utf8(p2 + p1.substr(i + 1, p1.length() - i + 1));
|
||||
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user