public static NuTask[] GetNewTasks(Task[] localTasks) #endif { #if Win8 await #endif Login(); if (loggedUser != null) { NuTask[] remoteTasks = null; #if Win8 remoteTasks = await wsdl.GetTasksAsync(clientAccount, loggedUser); #else #if WINDOWS_PHONE wsdl.GetTasksCompleted += wsdl_GetTasksCompleted; wsdl.GetTasksAsync(clientAccount, loggedUser, localTasks); #else remoteTasks = wsdl.GetTasks(clientAccount, loggedUser); #endif #endif if (remoteTasks != null) // <- for Windows_Phone done in wsdl_GetTasksCompleted { return(DoTasksComparison(localTasks, remoteTasks)); } } return(new NuTask[] { }); }