diff options
author | davilla <davilla@svn> | 2010-08-08 00:11:15 +0000 |
---|---|---|
committer | davilla <davilla@svn> | 2010-08-08 00:11:15 +0000 |
commit | fc4349d85b426e31682571afd715c56c3865c62f (patch) | |
tree | 6119473bb7a32191353221e379987f0fc04a2c09 /guilib | |
parent | d8a1b2349e8e77de3fe878e3fc74295e0fbdbe16 (diff) |
changed, there's no reason to be timing skin loads unless under debug
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@32596 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
Diffstat (limited to 'guilib')
-rw-r--r-- | guilib/GUIWindow.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/guilib/GUIWindow.cpp b/guilib/GUIWindow.cpp index 48818f5fca..afdedccd31 100644 --- a/guilib/GUIWindow.cpp +++ b/guilib/GUIWindow.cpp @@ -80,9 +80,10 @@ bool CGUIWindow::Load(const CStdString& strFileName, bool bContainsPath) if (m_windowLoaded) return true; // no point loading if it's already there +#ifdef _DEBUG int64_t start; start = CurrentHostCounter(); - +#endif RESOLUTION resToUse = RES_INVALID; CLog::Log(LOGINFO, "Loading skin file: %s", strFileName.c_str()); @@ -103,11 +104,12 @@ bool CGUIWindow::Load(const CStdString& strFileName, bool bContainsPath) bool ret = LoadXML(strPath.c_str(), strLowerPath.c_str()); +#ifdef _DEBUG int64_t end, freq; end = CurrentHostCounter(); freq = CurrentHostFrequency(); CLog::Log(LOGDEBUG,"Load %s: %.2fms", GetProperty("xmlfile").c_str(), 1000.f * (end - start) / freq); - +#endif return ret; } @@ -591,9 +593,10 @@ void CGUIWindow::AllocResources(bool forceLoad /*= FALSE */) { CSingleLock lock(g_graphicsContext); +#ifdef _DEBUG int64_t start; start = CurrentHostCounter(); - +#endif // load skin xml fil CStdString xmlFile = GetProperty("xmlfile"); bool bHasPath=false; @@ -608,11 +611,12 @@ void CGUIWindow::AllocResources(bool forceLoad /*= FALSE */) // and now allocate resources CGUIControlGroup::AllocResources(); +#ifdef _DEBUG int64_t end, freq; end = CurrentHostCounter(); freq = CurrentHostFrequency(); CLog::Log(LOGDEBUG,"Alloc resources: %.2fms (%.2f ms skin load)", 1000.f * (end - start) / freq, 1000.f * (slend - start) / freq); - +#endif m_bAllocated = true; } |