mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-02-04 03:40:07 +00:00
Introjucer: cleaned up some binarydata code.
This commit is contained in:
parent
fd90a9d449
commit
0358e95dc9
6 changed files with 33 additions and 20 deletions
|
|
@ -251,9 +251,9 @@ bool ResourceFile::writeCpp (MemoryOutputStream& cpp, const File& headerFile, in
|
|||
return true;
|
||||
}
|
||||
|
||||
bool ResourceFile::write (const File& cppFile, Array<File>& filesCreated)
|
||||
bool ResourceFile::write (Array<File>& filesCreated)
|
||||
{
|
||||
const File headerFile (cppFile.withFileExtension (".h"));
|
||||
const File headerFile (project.getBinaryDataHeaderFile());
|
||||
|
||||
{
|
||||
MemoryOutputStream mo;
|
||||
|
|
@ -268,11 +268,7 @@ bool ResourceFile::write (const File& cppFile, Array<File>& filesCreated)
|
|||
|
||||
for (;;)
|
||||
{
|
||||
File cpp (cppFile);
|
||||
|
||||
if (fileIndex > 0)
|
||||
cpp = cpp.getSiblingFile (cppFile.getFileNameWithoutExtension() + String (fileIndex + 1))
|
||||
.withFileExtension (cppFile.getFileExtension());
|
||||
File cpp (project.getBinaryDataCppFile (fileIndex));
|
||||
|
||||
MemoryOutputStream mo;
|
||||
if (! (writeCpp (mo, headerFile, i) && FileHelpers::overwriteFileWithNewDataIfDifferent (cpp, mo)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue