// RuntimeForStatic base library | C+- (SysRoutine) | Author: Sergei Y.Kitáev
#include "Precompiled.h"
#include "SharedIncludes.h"
namespace RuntimeForStatic {
//==================================================================================================

void $RuntimeParameters::Reset()
{
   Reset( nullptr );
}

void $RuntimeParameters::Reset(PCSTR crtLocaleString_ALL $optional)
{
   $CLEAR_INSTANCE();
   ThreadSettingsPattern.ReplaceEmptyLocaleValues();
   ThreadSettingsPattern.CRTLocaleStrings.ALL = crtLocaleString_ALL;
}

//--------------------------------------------------------------------------------------------------

void $RuntimeParameters::Prepare($A,PCWSTR moduleName)
{
   Prepare($ci, moduleName, nullptr );
}

void $RuntimeParameters::Prepare($A,PCWSTR moduleName,PCSTR crtLocaleString_ALL $optional)
{
   Prepare($ci, moduleName, crtLocaleString_ALL, false );
}

//--------------------------------------------------------------------------------------------------

void $RuntimeParameters::Prepare($A,PCWSTR moduleName,bool allowDesktopInteraction)
{
   Prepare($ci, moduleName, nullptr, false );
}

void $RuntimeParameters::Prepare($A,PCWSTR moduleName, PCSTR crtLocaleString_ALL $optional,
                                                       bool allowDesktopInteraction )
{
   $$VERIFY_POINTER_ARG( moduleName );
   Reset( crtLocaleString_ALL );
   ModuleParameters.Name = moduleName;
   AllowDesktopInteraction = $BOOL( allowDesktopInteraction );
}

//==================================================================================================
} // RuntimeForStatic
