- wxNode *node = wxDDEServerObjects.First();
- wxDDEConnection *found = NULL;
- while (node && !found)
- {
- wxDDEServer *object = (wxDDEServer *)node->Data();
- found = object->FindConnection((WXHCONV) hConv);
- node = node->Next();
- }
- if (found)
- return found;
-
- node = wxDDEClientObjects.First();
- while (node && !found)
- {
- wxDDEClient *object = (wxDDEClient *)node->Data();
- found = object->FindConnection((WXHCONV) hConv);
- node = node->Next();
- }
- return found;
+ wxDDEServerList::Node *serverNode = wxDDEServerObjects.GetFirst();
+ wxDDEConnection *found = NULL;
+ while (serverNode && !found)
+ {
+ wxDDEServer *object = serverNode->GetData();
+ found = object->FindConnection((WXHCONV) hConv);
+ serverNode = serverNode->GetNext();
+ }
+
+ if (found)
+ {
+ return found;
+ }
+
+ wxDDEClientList::Node *clientNode = wxDDEClientObjects.GetFirst();
+ while (clientNode && !found)
+ {
+ wxDDEClient *object = clientNode->GetData();
+ found = object->FindConnection((WXHCONV) hConv);
+ clientNode = clientNode->GetNext();
+ }
+ return found;