public void OnDailyTabPicClick(PicItem item) { MenuScreen.PaintStartSource = PaintStartSource.DailyOldPic; DailyEventInfo dailyDate = this.pageController.Daily.GetDailyDate(item.Id); AnalyticsManager.DailyTabPicClick(item.Id, dailyDate.row, dailyDate.day, dailyDate.month, dailyDate.year); this.ProcessPicItem(item); }
public DailyEventInfo GetDailyDate(int id) { DailyEventInfo result = default(DailyEventInfo); if (this.dailyPic != null && this.dailyPic.PicItem != null && this.dailyPic.PicItem.PictureData != null && this.dailyPic.PicItem.Id == id) { if (this.dailyContent != null && this.dailyContent.Count > 0) { result.day = this.dailyContent[0].pics.Count + 1; result.month = this.dailyContent[0].monthIndex; result.year = this.dailyContent[0].year; result.row = 0; } else { result.year = -1; result.month = -1; result.year = -1; result.row = -1; } return(result); } if (this.dailyContent != null) { for (int i = 0; i < this.dailyContent.Count; i++) { for (int j = 0; j < this.dailyContent[i].pics.Count; j++) { if (this.dailyContent[i].pics[j].Id == id) { result.day = this.dailyContent[i].pics.Count - j; result.month = this.dailyContent[i].monthIndex; result.year = this.dailyContent[i].year; result.row = this.GetItemRow(id, false); return(result); } } } } return(result); }