mirror of
https://github.com/gbdev/rgbds.git
synced 2026-10-03 10:45:37 +00:00
Move File-opening of PNG image into Png constructor (#2161)
Also rename `File::c_str` to `display_name` for clarity
This commit is contained in:
1 parent
ac7d7edf4d
commit
c0a16e4bad
6 files changed
+37
-22
No files matched your search
+1
-1
@@ -47,7 +47,7 @@ public:
|
||||
}
|
||||
std::streambuf *operator->() { return &**this; }
|
||||
|
||||
char const *c_str(std::string const &path) const {
|
||||
char const *display_name(std::string const &path) const {
|
||||
return std::holds_alternative<std::filebuf>(_file) ? path.c_str()
|
||||
: std::get<std::streambuf *>(_file) == std::cin.rdbuf() ? "<stdin>"
|
||||
: "<stdout>";
|
||||
|
||||
Reference in new issue
Block a user