mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Tidied up some comments and usage of File::createOutputStream() and createInputStream()
This commit is contained in:
parent
81e206f963
commit
302019dd43
13 changed files with 114 additions and 87 deletions
|
|
@ -335,9 +335,11 @@ private:
|
|||
fileToSave = fileToSave.getChildFile ("JUCE.png");
|
||||
fileToSave.deleteFile();
|
||||
|
||||
std::unique_ptr<OutputStream> outStream (fileToSave.createOutputStream());
|
||||
std::unique_ptr<InputStream> inStream (createAssetInputStream ("juce_icon.png"));
|
||||
outStream->writeFromInputStream (*inStream, -1);
|
||||
FileOutputStream outStream (fileToSave);
|
||||
|
||||
if (outStream.openedOk())
|
||||
if (auto inStream = std::unique_ptr<InputStream> (createAssetInputStream ("juce_icon.png")))
|
||||
outStream.writeFromInputStream (*inStream, -1);
|
||||
}
|
||||
|
||||
fc.reset (new FileChooser ("Choose a file to save...",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue