Example #1
0
        /// <summary>
        /// 为WebBrowser所开线程的启动入口函数,相当于Winform里面的Main()
        /// </summary>
        /// <param name="_wp"></param>
        private static void StaRun(object _wp)
        {
            WebPreview wp = (WebPreview)_wp;

            try
            {
                WebPreviewBase wpb = new WebPreviewBase(wp._uri, wp._width, wp._height, wp._fullPage);
                wp._bitmap = wpb.GetWebPreview();
            }
            catch (Exception ex)
            {
                wp._ex = ex;
            }
        }
Example #2
0
        public static Bitmap GetWebPreview(Uri uri, int timeout, int width, int height, bool fullPage)
        {
            WebPreview wp = new WebPreview(uri, timeout, width, height, fullPage);

            return(wp.GetWebPreview());
        }
Example #3
0
        public static Bitmap GetWebPreview(Uri uri)
        {
            WebPreview wp = new WebPreview(uri);

            return(wp.GetWebPreview());
        }