Beispiel #1
0
        bool StartListining(string prefix)
        {
            webListener = new HttpListener
            {
                IgnoreWriteExceptions = true,
                Prefixes = { prefix }
            };

            try
            {
                webListener.Start();
            }
            catch
            {
                VgcApis.Misc.Utils.RunInBackground(
                    () => MessageBox.Show(I18N.StartPacServFail));
                return(false);
            }

            webResponser =
                new Libs.Sys.CancelableTask(
                    WebResponseWorker);
            webResponser.Start();
            return(true);
        }
Beispiel #2
0
        bool StartListining(string prefix)
        {
            webListener = new HttpListener
            {
                IgnoreWriteExceptions = true,
                Prefixes = { prefix }
            };

            try
            {
                webListener.Start();
            }
            catch
            {
                VgcApis.Misc.UI.MsgBoxAsync(I18N.StartPacServFail);
                return(false);
            }

            webResponser =
                new Libs.Sys.CancelableTask(
                    WebResponseWorker);
            webResponser.Start();
            return(true);
        }