added IsWxReady() and CheckWxReady()
added initialization check at the beginning of each function