2 writes to Owner
PresentationFramework (2)
System\Windows\Controls\Calendar.cs (2)
746_monthControl?.Owner = null; 752_monthControl?.Owner = this;
131 references to Owner
PresentationFramework (131)
System\Windows\Controls\Primitives\CalendarItem.cs (131)
102return (this.Owner != null) ? this.Owner.DisplayMode : CalendarMode.Month; 134return (Owner != null) ? Owner.DisplayDate : DateTime.Today; 196if (this.Owner != null) 198switch (this.Owner.DisplayMode) 253this.Owner.DisplayMode == CalendarMode.Month && 254this.Owner.HoverEnd.HasValue) 256FinishSelection(this.Owner.HoverEnd.Value); 279if (this.Owner != null) 281selectedYear = this.Owner.DisplayYear; 502if (this.Owner != null) 504this.Owner.CurrentDate = selectedDate; 506if (this.Owner.HoverStart.HasValue) 510DateTime.Compare(this.Owner.HoverStart.Value, selectedDate) == 0 && 511(Owner.SelectionMode == CalendarSelectionMode.SingleDate || Owner.SelectionMode == CalendarSelectionMode.MultipleRange)) 514this.Owner.SelectedDates.Toggle(selectedDate); 520this.Owner.SelectedDates.AddRangeInternal(this.Owner.HoverStart.Value, selectedDate); 523Owner.OnDayClick(selectedDate); 532if (this.Owner == null) 537this.Owner.OnDayOrMonthPreviewKeyDown(e); 542if (this.Owner == null) 563switch (this.Owner.SelectionMode) 574this.Owner.SelectedDate = clickedDate; 578this.Owner.SelectedDates.Toggle(clickedDate); 586DateTime? lastDate = this.Owner.CurrentDate; 587this.Owner.SelectedDates.ClearInternal(true /*fireChangeNotification*/); 590this.Owner.SelectedDates.AddRangeInternal(lastDate.Value, clickedDate); 594this.Owner.SelectedDate = clickedDate; 595this.Owner.HoverStart = null; 596this.Owner.HoverEnd = null; 606this.Owner.SelectedDates.ClearInternal(true /*fireChangeNotification*/); 611this.Owner.SelectedDates.AddRangeInternal(this.Owner.CurrentDate, clickedDate); 617this.Owner.SelectedDate = clickedDate; 621this.Owner.SelectedDates.Toggle(clickedDate); 622this.Owner.HoverStart = null; 623this.Owner.HoverEnd = null; 631this.Owner.OnDayClick(clickedDate); 644if (this.Owner == null || !(b.DataContext is DateTime)) 651this.Owner.HoverStart = null; 665switch (this.Owner.SelectionMode) 674this.Owner.DatePickerDisplayDateFlag = true; 677this.Owner.SelectedDate = selectedDate; 681this.Owner.SelectedDates.Toggle(selectedDate); 689this.Owner.SelectedDates.ClearInternal(); 693if (!this.Owner.HoverStart.HasValue) 695this.Owner.HoverStart = this.Owner.HoverEnd = this.Owner.CurrentDate; 700this.Owner.HoverStart = this.Owner.HoverEnd = selectedDate; 710this.Owner.SelectedDates.ClearInternal(); 715if (!this.Owner.HoverStart.HasValue) 717this.Owner.HoverStart = this.Owner.HoverEnd = this.Owner.CurrentDate; 722this.Owner.HoverStart = this.Owner.HoverEnd = selectedDate; 729this.Owner.CurrentDate = selectedDate; 730this.Owner.UpdateCellItems(); 751if (this.Owner == null || !(b.DataContext is DateTime)) 758switch (this.Owner.SelectionMode) 762this.Owner.DatePickerDisplayDateFlag = true; 763this.Owner.HoverStart = this.Owner.HoverEnd = null; 764if (this.Owner.SelectedDates.Count == 0) 766this.Owner.SelectedDates.Add(selectedDate); 770this.Owner.SelectedDates[0] = selectedDate; 777this.Owner.HoverEnd = selectedDate; 778this.Owner.CurrentDate = selectedDate; 779this.Owner.UpdateCellItems(); 792if (this.Owner == null) 799this.Owner.OnDayButtonMouseUp(e); 816if (this.Owner.SelectionMode == CalendarSelectionMode.None || this.Owner.SelectionMode == CalendarSelectionMode.SingleDate) 818this.Owner.OnDayClick(selectedDate); 822if (this.Owner.HoverStart.HasValue) 824switch (this.Owner.SelectionMode) 829this.Owner.SelectedDates.ClearInternal(); 848this.Owner.OnDayClick(selectedDate); 861this.Owner?.OnCalendarButtonPressed(b, false); 868if (b != null && this.Owner != null) 870this.Owner.OnCalendarButtonPressed(b, true); 879if (this._isMonthPressed && this.Owner != null) 881this.Owner.OnCalendarButtonPressed(b, false); 891this.Owner.OnCalendarButtonPressed(b, true); 897if (this.Owner != null) 899if (this.Owner.DisplayMode == CalendarMode.Month) 901this.Owner.SetCurrentValueInternal(Calendar.DisplayModeProperty, CalendarMode.Year); 905Debug.Assert(this.Owner.DisplayMode == CalendarMode.Year); 907this.Owner.SetCurrentValueInternal(Calendar.DisplayModeProperty, CalendarMode.Decade); 916this.Owner?.OnPreviousClick(); 921this.Owner?.OnNextClick(); 942Owner = this.Owner 969Owner = this.Owner 1002if (this.Owner != null) 1004daytitle.DataContext = shortestDayNames[(childIndex + (int)this.Owner.FirstDayOfWeek) % shortestDayNames.Length]; 1051if (this.Owner != null) 1058if (DateTimeHelper.CompareDays(dateToAdd.Value, this.Owner.DisplayDateStartInternal) < 0 || DateTimeHelper.CompareDays(dateToAdd.Value, this.Owner.DisplayDateEndInternal) > 0) 1070this.Owner.BlackoutDates.Contains(dateToAdd.Value)); 1075DateTimeHelper.CompareYearMonth(dateToAdd.Value, this.Owner.DisplayDateInternal) != 0); 1094foreach (DateTime item in this.Owner.SelectedDates) 1116var owner = this.Owner; 1172if (this.Owner != null) 1181if (this.Owner != null && _nextButton != null) 1195_nextButton.IsEnabled = (DateTimeHelper.CompareDays(this.Owner.DisplayDateEndInternal, firstDayOfNextMonth) > -1); 1202if (this.Owner != null && _previousButton != null) 1205_previousButton.IsEnabled = (DateTimeHelper.CompareDays(this.Owner.DisplayDateStartInternal, firstDayOfMonth) < 0); 1231if (this.Owner != null) 1233childButton.HasSelectedDays = (Owner.DisplayDate.Year == year); 1235if (year < this.Owner.DisplayDateStartInternal.Year || year > this.Owner.DisplayDateEndInternal.Year) 1275if (this.Owner != null) 1277childButton.HasSelectedDays = (DateTimeHelper.CompareYearMonth(day, this.Owner.DisplayDateInternal) == 0); 1279if (DateTimeHelper.CompareYearMonth(day, this.Owner.DisplayDateStartInternal) < 0 || DateTimeHelper.CompareYearMonth(day, this.Owner.DisplayDateEndInternal) > 0) 1307if (this.Owner != null && _nextButton != null) 1309_nextButton.IsEnabled = (this.Owner.DisplayDateEndInternal.Year != DisplayDate.Year); 1315if (this.Owner != null && _previousButton != null) 1317_previousButton.IsEnabled = (this.Owner.DisplayDateStartInternal.Year != DisplayDate.Year); 1336if (this.Owner != null && _nextButton != null) 1338_nextButton.IsEnabled = (this.Owner.DisplayDateEndInternal.Year > decadeEnd); 1344if (this.Owner != null && _previousButton != null) 1346_previousButton.IsEnabled = (decade > this.Owner.DisplayDateStartInternal.Year); 1358if (this.Owner != null) 1360i = ((day - this.Owner.FirstDayOfWeek + NUMBER_OF_DAYS_IN_WEEK) % NUMBER_OF_DAYS_IN_WEEK); 1386Source = this.Owner