Try to clean up asset folders for sample apps. (#128)

* Try to clean up asset folders for sample apps.

This removes the build step where we copy a subset of assets, and makes
it so that FilamentApp hands out a "root path" for assets. For now this
is determined based on the location of the executable. This allows
developers to launch samples from any CWD.

Closes #11

* Restore asset copy to build.
This commit is contained in:
Philip Rideout
2018-08-23 12:46:45 -07:00
committed by GitHub
parent 7fff7d715f
commit 099738e545
10 changed files with 56 additions and 19 deletions

View File

@@ -131,6 +131,14 @@ Path Path::getParent() const {
return getCanonicalPath(result);
}
Path Path::getAncestor(int n) const {
Path result = getParent();
while (n--) {
result = result.getParent();
}
return result;
}
std::string Path::getName() const {
if (isEmpty()) return "";