public void LazyLoad(Action done, params string[] e)
        {
            int stage = 1;

            try
            {
                stage = 2;
                var w = new WorkPool();
                stage = 3;
                foreach (var v0 in e)
                {
                    var v1 = v0;

                    w.Add(
                        delegate
                        {
                            this.AddWorker().Name = v1;
                        }
                    );
                }
                stage = 4;
                w.Add(
                     delegate
                     {
                         this.UpdateActualPercentages();

                         done();
                     }
                );
                stage = 5;
            }
            catch (Exception exc)
            {
                throw new Exception("LazyLoad failed: {" + exc.Message + "}; stage: " + stage);
                
            }
        }
Ejemplo n.º 2
0
        public static WorkPool FlashAndFadeOut(IHTMLElement e, int interval)
        {

            WorkPool p = new WorkPool(interval);

            p += delegate { e.Hide(); };
            p += delegate { e.Show(); };
            p += delegate { e.Hide(); };
            p += delegate { e.Show(); };

            e.style.zIndex = 1000;

            return p;
        }