Ejemplo n.º 1
0
        // Token: 0x06001F8B RID: 8075 RVA: 0x000B5938 File Offset: 0x000B3B38
        private void RenderConversationPartRow(TextWriter writer, Folder contextFolder, Folder dataFolder, ExDateTime?lastDeliveryTime, int maximumIndentLevel)
        {
            IConversationTreeNode currentNode = this.ConversationPartsDataSource.GetCurrentNode();

            if (!ConversationUtilities.ShouldRenderItem(currentNode, (MailboxSession)dataFolder.Session))
            {
                return;
            }
            StoreObjectId itemProperty = this.DataSource.GetItemProperty <StoreObjectId>(StoreObjectSchema.ParentItemId);
            bool          flag         = (bool)this.DataSource.GetItemProperty <object>(MessageItemSchema.IsRead);
            bool          flag2        = !ConversationUtilities.IsLocalNode(currentNode);
            bool          flag3        = Utilities.IsDefaultFolderId((MailboxSession)dataFolder.Session, itemProperty, DefaultFolderType.DeletedItems);

            writer.Write("<div id=\"");
            writer.Write("ver");
            writer.Write("\" class=\"");
            writer.Write(flag2 ? "df " : string.Empty);
            writer.Write(flag ? string.Empty : "ur");
            writer.Write((this.DataSource.CurrentItem == this.DataSource.EndRange) ? " eclr" : string.Empty);
            writer.Write("\">");
            writer.Write("<div class=cData");
            ItemList2.RenderRowId(writer, this.DataSource.GetItemId());
            this.RenderConversationPartMetaDataExpandos(writer, currentNode, dataFolder, itemProperty, lastDeliveryTime);
            writer.Write(">");
            writer.Write("</div>");
            int num2;

            if (this.ConversationPartsDataSource.SortOrder == ConversationTreeSortOrder.DeepTraversalAscending || this.ConversationPartsDataSource.SortOrder == ConversationTreeSortOrder.DeepTraversalDescending)
            {
                IConversationTreeNode conversationTreeNode = currentNode;
                int num = 0;
                while (conversationTreeNode != null && num < maximumIndentLevel)
                {
                    num++;
                    conversationTreeNode = conversationTreeNode.ParentNode;
                }
                num2 = num * 4 + 18;
            }
            else
            {
                num2 = 22;
            }
            writer.Write("<div class=expc2 style=\"");
            writer.Write(base.UserContext.IsRtl ? "right:" : "left:");
            writer.Write(num2);
            writer.Write("px;width:");
            writer.Write(20);
            writer.Write("px;\">");
            base.RenderMessageIcon(writer);
            writer.Write("</div>");
            writer.Write("<div class=expc3 style=\"");
            writer.Write(base.UserContext.IsRtl ? "right:" : "left:");
            writer.Write(num2 + 20);
            writer.Write("px;\">");
            if (flag3)
            {
                writer.Write("<strike>");
            }
            base.RenderColumn(writer, ColumnId.From);
            if (flag3)
            {
                writer.Write("</strike>");
            }
            writer.Write("</div>");
            if (flag2)
            {
                base.UserContext.ClearFolderNameCache();
                writer.Write("<div class=\"expc4 df\">");
                base.RenderVLVAnchorOpen(writer);
                writer.Write(Utilities.HtmlEncode(base.UserContext.GetCachedFolderName(itemProperty, (MailboxSession)dataFolder.Session)));
                base.RenderVLVAnchorClose(writer);
                writer.Write("</div>");
            }
            else
            {
                writer.Write("<div class=\"expc4 r\">");
                base.RenderColumn(writer, ColumnId.DeliveryTime);
                writer.Write("</div>");
            }
            FlagStatus itemProperty2 = this.DataSource.GetItemProperty <FlagStatus>(ItemSchema.FlagStatus, FlagStatus.NotFlagged);

            writer.Write("<div class=\"c7");
            if (itemProperty2 != FlagStatus.NotFlagged)
            {
                writer.Write(" stky");
            }
            writer.Write("\" id=");
            writer.Write("divFlg");
            writer.Write(">");
            base.RenderColumn(writer, ColumnId.FlagDueDate);
            writer.Write("</div>");
            string[] itemProperty3 = this.DataSource.GetItemProperty <string[]>(ItemSchema.Categories, null);
            writer.Write("<div class=\"r c6");
            if (itemProperty3 != null && itemProperty3.Length > 0)
            {
                writer.Write(" stky");
            }
            writer.Write("\" id=");
            writer.Write("divCat");
            writer.Write(">");
            base.RenderColumn(writer, ColumnId.Categories);
            writer.Write("</div>");
            writer.Write("<div class=c5 style=\"text-decoration:none;\">");
            bool flag4 = base.RenderColumn(writer, ColumnId.Importance, false);

            base.RenderColumn(writer, ColumnId.HasAttachment, !flag4);
            writer.Write("</div>");
            base.RenderSelectionImage(writer);
            writer.Write("</div>");
        }