Commit 4d5ddf77 authored by Dimitri van Heesch's avatar Dimitri van Heesch

Bug 720092 - USE_MDFILE_AS_MAINPAGE doesn't work if full path is specified.

parent c5ae1978
...@@ -2292,9 +2292,13 @@ void MarkdownFileParser::parseInput(const char *fileName, ...@@ -2292,9 +2292,13 @@ void MarkdownFileParser::parseInput(const char *fileName,
QCString titleFn = QFileInfo(fileName).baseName().utf8(); QCString titleFn = QFileInfo(fileName).baseName().utf8();
QCString fn = QFileInfo(fileName).fileName().utf8(); QCString fn = QFileInfo(fileName).fileName().utf8();
static QCString mdfileAsMainPage = Config_getString("USE_MDFILE_AS_MAINPAGE"); static QCString mdfileAsMainPage = Config_getString("USE_MDFILE_AS_MAINPAGE");
if (id.isEmpty()) id = markdownFileNameToId(fileName); if (id.isEmpty()) id = markdownFileNameToId(fileName);
if (title.isEmpty()) title = titleFn; if (title.isEmpty()) title = titleFn;
if (fn==mdfileAsMainPage) if (!mdfileAsMainPage.isEmpty() &&
(fn==mdfileAsMainPage || // name reference
QFileInfo(fileName).absFilePath()==
QFileInfo(mdfileAsMainPage).absFilePath()) // file reference with path
)
{ {
docs.prepend("@mainpage\n"); docs.prepend("@mainpage\n");
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment