コード例 #1
0
        /// <summary>
        ///   Check whether we can actually display as button
        /// </summary>
        /// <param name="html">Current HTML element</param>
        /// <returns>True if can display as button, else False</returns>
        public static bool CanDisplayAsButton(IExtendedHtmlString html)
        {
            // We can only display hyperlinks and button as buttons
            Type t = html.GetType();

            return(t == typeof(Hyperlink) || t == typeof(Button));
        }