mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-25 07:56:33 +00:00
When editing a shader, default to the edit base file
* In the case of a munged file with #line directives, we want to edit that file, not the split-out view of the file containing the entry point.
This commit is contained in:
@@ -329,11 +329,12 @@ void ShaderViewer::editShader(ResourceId id, ShaderStage stage, const QString &e
|
||||
w->setProperty("filename", kv.first);
|
||||
w->setProperty("origText", kv.second);
|
||||
|
||||
if(text.contains(entryPoint))
|
||||
if(sel == NULL)
|
||||
{
|
||||
sel = scintilla;
|
||||
|
||||
if(sel == scintilla || title.isEmpty())
|
||||
title = tr(" - %1 - %2()").arg(name).arg(entryPoint);
|
||||
}
|
||||
}
|
||||
|
||||
if(sel != NULL)
|
||||
|
||||
Reference in New Issue
Block a user