Compile with clang and add cotire

* Add cotire cmake module to speedup compilation https://github.com/sakra/cotire
* Fix clang error and warnings
* Rename Font to BitmapFont to fix conflict with Xlib.g Font typedef
* Remove legacy PCH support
* Improve Position hash
This commit is contained in:
Eduardo Bart
2012-06-16 20:19:43 -03:00
parent 4813b7eb4b
commit 10b33c6124
24 changed files with 2835 additions and 373 deletions

View File

@@ -335,16 +335,15 @@ void UIManager::importStyleFromOTML(const OTMLNodePtr& styleNode)
styleNode->writeAt("__unique", true);
}
// TODO: styles must be searched by widget scopes, in that way this warning could be fixed
// this warning is disabled because many ppl was complening about it
/*
auto it = m_styles.find(name);
if(it != m_styles.end())
g_logger.warning("style '%s' is being redefined", name);
*/
// Warn about redefined styles
if(!g_app->isRunning() && !unique) {
auto it = m_styles.find(name);
if(it != m_styles.end())
g_logger.warning(stdext::format("style '%s' is being redefined", name));
}
OTMLNodePtr oldStyle = m_styles[name];
if(!oldStyle || oldStyle->valueAt("__unique", false) || unique) {
if(!oldStyle || !oldStyle->valueAt("__unique", false) || unique) {
OTMLNodePtr originalStyle = getStyle(base);
if(!originalStyle)
stdext::throw_exception(stdext::format("base style '%s', is not defined", base));