/// <summary>
        /// Call this to initialize the Cortana card with new content. This can be called multiple times, and will clear the previous content.
        /// </summary>
        /// <param name="content"></param>
        /// <returns></returns>
        public ParseResult InitializeFromOneNotification(XmlDocument content)
        {
            ParseResult result = _parser.ParseNotification(content.GetXml());

            if (result.IsOkForRender())
            {
                InitializeContent(result.Notification);
            }

            return(result);
        }
예제 #2
0
        /// <summary>
        /// Updates the tile with the notification. If the tile payload has an error, the tile will not be updated. The first error, or multiple warnings, will be reported via the returned ParseResult.
        /// </summary>
        /// <param name="notification"></param>
        /// <returns></returns>
        public ParseResult UpdateFromOneNotification(XmlDocument content)
        {
            ParseResult result = _parser.ParseNotification(content.GetXml());

            if (result.IsOkForRender())
            {
                _previewTile.Show(result.Notification, true);
            }

            return(result);
        }