public DailyShedulePageAdapter(Schedule schedule, Schedule.Filter scheduleFilter, bool showEmptyLessons, bool showGroup, bool loading) { this.Schedule = schedule; this.scheduleFilter = scheduleFilter; this.showEmptyLessons = showEmptyLessons; //this.showColoredLessons = showColoredLessons; this.showGroup = showGroup; this.loading = loading; SetCount(schedule); SetFirstPosDate(this.Schedule); this.recyclerAdapters = new PairAdapter[3]; this.views = new View[3]; this.dayBtn = new Button[3]; this.recyclerViews = new RecyclerView[3]; this.currentPositions = new int[3]; accumulators = new int[3]; this.customFormat = CultureInfo.CurrentUICulture; this.customFormat = (CultureInfo)this.customFormat.Clone(); this.customFormat.DateTimeFormat.MonthNames = (from m in this.customFormat.DateTimeFormat.MonthNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); this.customFormat.DateTimeFormat.MonthGenitiveNames = (from m in this.customFormat.DateTimeFormat.MonthGenitiveNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); this.customFormat.DateTimeFormat.DayNames = (from m in this.customFormat.DateTimeFormat.DayNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); }
public DailyShceduleGridAdapter(Schedule schedule, Schedule.Filter scheduleFilter, bool showGroup, Color colorParagraph, Color colorTimeBackground, Color colorTitle, Color colorCurrentTitle) { this.scheduleFilter = scheduleFilter; this.schedule = schedule; this.colorTitle = colorTitle; this.colorCurrentTitle = colorCurrentTitle; this.ShowGroup = showGroup; SetCount(schedule); if (schedule != null) { SetFirstPosDate(schedule); } this.colorParagraph = colorParagraph; this.colorTimeBackground = colorTimeBackground; this.customFormat = CultureInfo.CurrentUICulture; this.customFormat = (CultureInfo)this.customFormat.Clone(); this.customFormat.DateTimeFormat.AbbreviatedMonthNames = (from m in this.customFormat.DateTimeFormat.AbbreviatedMonthNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); this.customFormat.DateTimeFormat.AbbreviatedMonthGenitiveNames = (from m in this.customFormat.DateTimeFormat.AbbreviatedMonthGenitiveNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); this.customFormat.DateTimeFormat.AbbreviatedDayNames = (from m in this.customFormat.DateTimeFormat.AbbreviatedDayNames select m.Length == 0 || m.Length == 1 ? m : char.ToUpper(m[0]) + m.Substring(1)) .ToArray(); }