summaryrefslogtreecommitdiff
path: root/cppe/test/Common/TestCommon.cpp
diff options
context:
space:
mode:
authorMatthew Newhook <matthew@zeroc.com>2005-07-18 15:47:45 +0000
committerMatthew Newhook <matthew@zeroc.com>2005-07-18 15:47:45 +0000
commit3e21b4035b9570ae3b0711876e2053de04f7f080 (patch)
treed5591341c10c1659669c172323f4599cbc5732eb /cppe/test/Common/TestCommon.cpp
parentFixed ICEE_HAS_ROUTER build (diff)
downloadice-3e21b4035b9570ae3b0711876e2053de04f7f080.tar.bz2
ice-3e21b4035b9570ae3b0711876e2053de04f7f080.tar.xz
ice-3e21b4035b9570ae3b0711876e2053de04f7f080.zip
fix UUID test under CE.
Diffstat (limited to 'cppe/test/Common/TestCommon.cpp')
-rwxr-xr-xcppe/test/Common/TestCommon.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/cppe/test/Common/TestCommon.cpp b/cppe/test/Common/TestCommon.cpp
index 6a7df72e55c..032c2d80093 100755
--- a/cppe/test/Common/TestCommon.cpp
+++ b/cppe/test/Common/TestCommon.cpp
@@ -71,6 +71,8 @@ public:
}
};
+static IceUtil::StaticMutex terminatedMutex = ICEE_STATIC_MUTEX_INITIALIZER;
+static bool appTerminated= false;
#ifdef _WIN32_WCE
@@ -211,12 +213,19 @@ WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
break;
case WM_CLOSE:
+ {
DestroyWindow(hWnd);
break;
-
+ }
+
+ case WM_QUIT:
case WM_DESTROY:
+ {
PostQuitMessage(0);
+ IceUtil::StaticMutex::Lock sync(terminatedMutex);
+ appTerminated = true;
break;
+ }
default:
return DefWindowProc(hWnd, msg, wParam, lParam);
@@ -434,6 +443,14 @@ TestApplication::communicator()
return _communicator;
}
+
+bool
+TestApplication::terminated() const
+{
+ IceUtil::StaticMutex::Lock sync(terminatedMutex);
+ return appTerminated;
+}
+
void
testFailed(const char* expr, const char* file, unsigned int line)
{