Rearrange states in the switch in a more logical order
No real changes, just try to organize the code in a more logical order.
This commit is contained in:
parent
0742ae9091
commit
0777fda680
1 changed files with 10 additions and 9 deletions
|
|
@ -68,7 +68,14 @@ public:
|
|||
{
|
||||
switch (evt.GetState())
|
||||
{
|
||||
case wxWebRequest::State_Unauthorized:
|
||||
case wxWebRequest::State_Idle:
|
||||
FAIL("should never get events with State_Idle");
|
||||
break;
|
||||
|
||||
case wxWebRequest::State_Active:
|
||||
CHECK( request.GetNativeHandle() );
|
||||
break;
|
||||
|
||||
case wxWebRequest::State_Completed:
|
||||
if ( request.GetStorage() == wxWebRequest::Storage_File )
|
||||
{
|
||||
|
|
@ -76,18 +83,12 @@ public:
|
|||
CHECK( fn.GetSize() == expectedFileSize );
|
||||
}
|
||||
wxFALLTHROUGH;
|
||||
|
||||
case wxWebRequest::State_Unauthorized:
|
||||
case wxWebRequest::State_Failed:
|
||||
case wxWebRequest::State_Cancelled:
|
||||
loop.Exit();
|
||||
break;
|
||||
|
||||
case wxWebRequest::State_Idle:
|
||||
FAIL("should never get events with State_Idle");
|
||||
break;
|
||||
|
||||
case wxWebRequest::State_Active:
|
||||
CHECK( request.GetNativeHandle() );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue