GLOBALOSGLUPROC WaitForNextTick(void) { label_retry: CheckForSystemEvents(); CheckForSavedTasks(); if (ForceMacOff) { return; } if (CurSpeedStopped) { MyDrawChangesAndClear(); WaitForTheNextEvent(); goto label_retry; } if (ExtraTimeNotOver()) { si5b TimeDiff = GetTimeDiff(); if (TimeDiff < 0) { /* FIXME: Implement this? struct timespec rqt; struct timespec rmt; rqt.tv_sec = 0; rqt.tv_nsec = (- TimeDiff) * 1000; (void) nanosleep(&rqt, &rmt); */ } goto label_retry; } if (CheckDateTime()) { #if MySoundEnabled MySound_SecondNotify(); #endif #if EnableDemoMsg DemoModeSecondNotify(); #endif } CheckMouseState(); OnTrueTime = TrueEmulatedTime; }
CString XMLRestriction::CheckDatatype(XmlDataType p_type,CString p_value) { CString result; // Empty value, nothing to check if(p_value.IsEmpty()) { return result; } try { // Checking only base datatypes // String and CDATA are never checked! switch(p_type & XDT_MaskTypes) { case XDT_AnyURI: result = CheckAnyURI (p_value); break; case XDT_Base64Binary: result = CheckBase64 (p_value); break; case XDT_Boolean: result = CheckBoolean (p_value); break; case XDT_Date: result = CheckDate (p_value); break; case XDT_Integer: result = CheckInteger (p_value); break; case XDT_Decimal: result = CheckDouble (p_value,false); break; case XDT_Double: result = CheckDouble (p_value,true); break; case XDT_DateTime: result = CheckDateTime (p_value,false); break; case XDT_DateTimeStamp: result = CheckDateTime (p_value,true); break; case XDT_Float: result = CheckDouble (p_value,true); break; case XDT_Duration: result = CheckDuration (p_value); break; case XDT_DayTimeDuration: result = CheckDaySecond(p_value); break; case XDT_YearMonthDuration: result = CheckYearMonth(p_value); break; case XDT_GregDay: result = CheckGregDay (p_value); break; case XDT_GregMonth: result = CheckGregMonth(p_value); break; case XDT_GregYear: result = CheckGregYear (p_value); break; case XDT_GregMonthDay: result = CheckGregMD (p_value); break; case XDT_GregYearMonth: result = CheckGregYM (p_value); break; case XDT_HexBinary: result = CheckHexBin (p_value); break; case XDT_Long: result = CheckLong (p_value); break; case XDT_Int: result = CheckLong (p_value); break; case XDT_Short: result = CheckShort (p_value); break; case XDT_NonNegativeInteger:result = CheckNNegInt (p_value); break; case XDT_PositiveInteger: result = CheckPosInt (p_value); break; case XDT_UnsignedLong: result = CheckUnsLong (p_value); break; case XDT_UnsignedInt: result = CheckUnsLong (p_value); break; case XDT_UnsignedShort: result = CheckUnsShort (p_value); break; case XDT_UnsignedByte: result = CheckUnsByte (p_value); break; case XDT_NonPositiveInteger:result = CheckNonPosInt(p_value); break; case XDT_NegativeInteger: result = CheckNegInt (p_value); break; case XDT_Time: result = CheckTime (p_value); break; case XDT_Token: result = CheckToken (p_value); break; case XDT_NMTOKEN: result = CheckNMTOKEN (p_value); break; case XDT_Name: result = CheckName (p_value); break; case XDT_ENTITY: result = CheckName (p_value); break; case XDT_ID: result = CheckName (p_value); break; case XDT_IDREF: result = CheckName (p_value); break; case XDT_QName: result = CheckQName (p_value); break; case XDT_NMTOKENS: result = CheckNMTOKENS (p_value); break; case XDT_ENTITIES: result = CheckNames (p_value); break; case XDT_IDREFS: result = CheckNames (p_value); break; default: break; } } catch(StdException& er) { ReThrowSafeException(er); // Primary datatype conversion went wrong result = er.GetErrorMessage(); } return result; }