diff options
author | Ken Martin <ken.martin@kitware.com> | 2002-09-26 19:14:20 (GMT) |
---|---|---|
committer | Ken Martin <ken.martin@kitware.com> | 2002-09-26 19:14:20 (GMT) |
commit | c751d2ebff5b95b0f00c09ef6203d70f323c8144 (patch) | |
tree | d52b04bd774d9d6d4ba27ec633249f52c7253f52 /Source/cmake.cxx | |
parent | 85896b3460f3e1276dec6ad67d63df26e65d16e2 (diff) | |
download | CMake-c751d2ebff5b95b0f00c09ef6203d70f323c8144.zip CMake-c751d2ebff5b95b0f00c09ef6203d70f323c8144.tar.gz CMake-c751d2ebff5b95b0f00c09ef6203d70f323c8144.tar.bz2 |
added progress
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r-- | Source/cmake.cxx | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx index da5eef9..684116a 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -41,6 +41,9 @@ cmake::cmake() m_InTryCompile = false; m_CacheManager = new cmCacheManager; m_GlobalGenerator = 0; + m_ProgressCallback = 0; + m_ProgressCallbackClientData = 0; + this->AddDefaultCommands(); } @@ -907,3 +910,17 @@ int cmake::LoadCache() return 0; } +void cmake::SetProgressCallback(ProgressCallback f, void *cd) +{ + m_ProgressCallback = f; + m_ProgressCallbackClientData = cd; +} + +void cmake::UpdateProgress(const char *msg, float prog) +{ + if(m_ProgressCallback && !m_InTryCompile) + { + (*m_ProgressCallback)(msg, prog, m_ProgressCallbackClientData); + return; + } +} |