private bool CreateBackgroundResource(BackgroundImageDescriptor descr) { //resourceLoading.Reset(); fileStatus = FileSaveStatus.Abort; string otherResourceId; ClientResourceCRUD.CreateSource(descr, out otherResourceId); //createSourceThread = new Thread(new ThreadStart(new MethodInvoker(() => //{ // string otherResourceId; // ClientResourceCRUD.CreateSource(descr, out otherResourceId); //}))); //createSourceThread.IsBackground = true; //createSourceThread.SetApartmentState(ApartmentState.STA); //createSourceThread.Start(); //resourceLoading.WaitOne(); return fileStatus == FileSaveStatus.Ok; }
void clientResourceCRUD_OnComplete(object sender, OperationStatusEventArgs<ResourceDescriptor> e) { CloseSplash(); fileStatus = e.Status; //resourceLoading.Set(); }