Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for configurable location of ofxbraitsch folder? #53

Closed
mattfelsen opened this issue Mar 21, 2016 · 3 comments
Closed

Allow for configurable location of ofxbraitsch folder? #53

mattfelsen opened this issue Mar 21, 2016 · 3 comments

Comments

@mattfelsen
Copy link
Contributor

It'd be great to allow for a configurable setting of the ofxbraitsch data folder. Currently in one of my apps, I changed the hard-coded paths in the addon, but it'd be nice to control this from outside the addon.

I started on this by adding static ofxDatGui::setDataDir(const std::string& dir) and ofxDatGui::getDataDir() methods, but then we wind up with circular includes since ofxDatGui.h ends up #includeing ofxDatGuiThemes.h eventually. You can check out what I did on my branch, but maybe you've got a better approach in mind?
mattfelsen@bb3f814

Cheers!

@braitsch
Copy link
Owner

Themes are assigned to guis & components so I'd rather not include a reference to either of them within the ofxDatGuiTheme class. I added a static ofxDatGui convenience method that sets a new ofxDatGuiTheme::AssetPath variable that will allow you to customize the location of the ofxbraitsch assets directory. LMK if this works for what you need.

@mattfelsen
Copy link
Contributor Author

Oh duh, not sure why I was thinking it had to be a static method on ofxDatGui. Perfect! I'll give this a shot later but this should be good for me. Thanks!

@braitsch
Copy link
Owner

Cool, sounds like this works for you. Feel free to reopen if you have any trouble.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants