Пример #1
0
        /// <summary>
        /// Initialize script, styles and colors
        /// </summary>
        public Popup()
        {
            // {0} = E5EDFA - popupBackground
              // {1} = 455690 - popupBorderDark
              // {2} = A6B4CF - popupBorderLight
              // {3} = 728EB8 - cntBorderDark
              // {4} = B9C9EF - cntBorderLight
              // {5} = E9EFF9 - cntBackground
              // {6} = E0E9F8 - gradientStart
              // {7} = FFFFFF - gradientEnd
              // {8} = 1F336B - textColor
              // {9} = 6A87B2 - xButton
              // {10}= 45638F - xButtonOver

              divDesign=@"background:#{0}; border-right:1px solid #{1}; border-bottom:1px solid #{1};
                  border-left:1px solid #{2}; border-top:1px solid #{2}; position:absolute;
                  z-index:9999; ";

              cntStyle=@"border-left:1px solid #{3}; border-top:1px solid #{3};
                 border-bottom:1px solid #{4}; border-right:1px solid #{4};
                 background:#{5}; padding:2px; overflow:hidden; text-align:center;
                 filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,
                 StartColorStr='#FF{6}', EndColorStr='#FF{7}');";
              cntStyleI=@"position:absolute; left:2px; width:{0}px; top:20px; height:{1}px;";
              cntStyleN=@"position:absolute; left:2px; width:{0}px; top:20px; height:{1}px;";

              aStyle=@"font:12px arial,sans-serif; color:#{8}; text-decoration:none;";
              aCommands=@"onmouseover=""style.textDecoration='underline';""
                  onmouseout=""style.textDecoration='none';""
                  href=""[cmd]""";

              hdrStyle=@"position:absolute; left:2px; width:[wid]px; top:2px; height:14px;
                 filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,
                 StartColorStr='#FF{6}', EndColorStr='#FF{7}');";

              title="Title here";
              msg="Message to show in popup";
              fullmsg="Text to display in new window.";

              closeHtml=@"<span style=""position:absolute; right:0px; top:0px; cursor:pointer; color:#{9}; font:bold 12px arial,sans-serif;
                  position:absolute; right:3px;""
                  onclick=""[id]espopup_Close()""
                  onmousedown=""event.cancelBubble=true;""
                  onmouseover=""style.color='#{10}';""
                  onmouseout=""style.color='#{9}';"">X</span>";

              sPopup="<head><title>{1}</title><style type=\\\"text/css\\\">{2}</style></head>"+
            "<body><h1>{1}</h1><p>{0}</p></body>";

              spopStyle="body {"+
            "    background:#[gs]; padding:5px;"+
            "    filter:progid:DXImageTransform.Microsoft.Gradient("+
            "     GradientType=0,StartColorStr='#FF[gs]', EndColorStr='#FF[ge]');"+
            "  }"+
            "  h1 {"+
            "    font:bold 16px arial,sans-serif; color:#[clr]; "+
            "    text-align:center; margin:0px;"+
            "  }"+
            "  p {"+
            "    font:14px arial,sans-serif; color:#[clr];"+
            "  }";

              ColorStyle=PopupColorStyle.Blue;
              xOffset=yOffset=15; popDock=PopupDocking.BottomRight;
              iHide=5000; winSize=new Size(400,250);
              Width=new Unit("200px");
              Height=new Unit("100px");
              startTime=1000;
              popAction=PopupAction.MessageWindow;
        }
Пример #2
0
        /// <summary>
        /// Initialize script, styles and colors
        /// </summary>
        public PopupWin()
        {
            // {0} = E5EDFA - popupBackground
            // {1} = 455690 - popupBorderDark
            // {2} = A6B4CF - popupBorderLight
            // {3} = 728EB8 - cntBorderDark
            // {4} = B9C9EF - cntBorderLight
            // {5} = E9EFF9 - cntBackground
            // {6} = E0E9F8 - gradientStart
            // {7} = FFFFFF - gradientEnd
            // {8} = 1F336B - textColor
            // {9} = 6A87B2 - xButton
            // {10}= 45638F - xButtonOver

            divDesign = @"background:#{0}; border-right:1px solid #{1}; border-bottom:1px solid #{1};
                  border-left:1px solid #{2}; border-top:1px solid #{2}; position:absolute;
                  z-index:9999; ";

            cntStyle  = @"border-left:1px solid #{3}; border-top:1px solid #{3};
                 border-bottom:1px solid #{4}; border-right:1px solid #{4};
                 background:#{5}; padding:2px; overflow:hidden; text-align:center;
                 filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,
                 StartColorStr='#FF{6}', EndColorStr='#FF{7}');";
            cntStyleI = @"position:absolute; left:2px; width:{0}px; top:20px; height:{1}px;";
            cntStyleN = @"position:absolute; left:2px; width:{0}px; top:20px; height:{1}px;";

            aStyle    = @"font:12px arial,sans-serif; color:#{8}; text-decoration:none;";
            aCommands = @"onmouseover=""style.textDecoration='underline';""
                  onmouseout=""style.textDecoration='none';""
                  href=""[cmd]""";

            hdrStyle = @"position:absolute; left:2px; width:[wid]px; top:2px; height:14px;
                 filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,
                 StartColorStr='#FF{6}', EndColorStr='#FF{7}');";

            title   = "Title here";
            msg     = "Message to show in popup";
            fullmsg = "Text to display in new window.";

            closeHtml = @"<span style=""position:absolute; right:0px; top:0px; cursor:pointer; color:#{9}; font:bold 12px arial,sans-serif; 
                  position:absolute; right:3px;""
                  onclick=""[id]espopup_Close()""
                  onmousedown=""event.cancelBubble=true;""
                  onmouseover=""style.color='#{10}';""
                  onmouseout=""style.color='#{9}';"">X</span>";

            sPopup = "<head><title>{1}</title><style type=\\\"text/css\\\">{2}</style></head>" +
                     "<body><h1>{1}</h1><p>{0}</p></body>";

            spopStyle = "body {" +
                        "    background:#[gs]; padding:5px;" +
                        "    filter:progid:DXImageTransform.Microsoft.Gradient(" +
                        "     GradientType=0,StartColorStr='#FF[gs]', EndColorStr='#FF[ge]');" +
                        "  }" +
                        "  h1 {" +
                        "    font:bold 16px arial,sans-serif; color:#[clr]; " +
                        "    text-align:center; margin:0px;" +
                        "  }" +
                        "  p {" +
                        "    font:14px arial,sans-serif; color:#[clr];" +
                        "  }";

            ColorStyle = PopupColorStyle.Blue;
            xOffset    = yOffset = 15; popDock = PopupDocking.BottomRight;
            iHide      = 5000; winSize = new Size(400, 250);
            Width      = new Unit("200px");
            Height     = new Unit("100px");
            startTime  = 1000;
            popAction  = PopupAction.MessageWindow;
        }