コード例 #1
0
        public async Task <bool> ConnectNetworkAsync()
        {
            Debug.WriteLine("Connect start!");

            return(await WorkAsync(
                       x => _worker.ConnectNetworkAsync(x, _workingTimeoutDuration),
                       x => Profiles.Contains(x) && x.IsConnected));
        }
コード例 #2
0
ファイル: MainController.cs プロジェクト: whidbey/Wifinian
        public Task <bool> ConnectNetworkAsync(ProfileItem targetProfile, bool isManual = true)
        {
            Debug.WriteLine("Connect start!");

            if (isManual)
            {
                EngagesPriority.Value = false;
            }

            return(WorkAsync(targetProfile, x => _worker.ConnectNetworkAsync(x, _connectTimeout)));
        }