Bloom.Browser._browser_Navigating C# (CSharp) Method

_browser_Navigating() protected method

protected _browser_Navigating ( object sender, GeckoNavigatingEventArgs e ) : void
sender object
e GeckoNavigatingEventArgs
return void
        void _browser_Navigating(object sender, GeckoNavigatingEventArgs e)
        {
            Debug.Assert(!InvokeRequired);
            string url = e.Uri.OriginalString.ToLowerInvariant();

            if ((!url.StartsWith(Bloom.Api.ServerBase.ServerUrlWithBloomPrefixEndingInSlash)) && (url.StartsWith("http")))
            {
                e.Cancel = true;
                Process.Start(e.Uri.OriginalString); //open in the system browser instead
                Debug.WriteLine("Navigating " + e.Uri);
            }
        }