public VacationPresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] VacationView view, [NotNull] Vacation vacation) : base(view, "ThisVacation.HeaderString", vacation, applicationPresenter) { _applicationPresenter = applicationPresenter; _thisVacation = vacation; }
public LoadTypePresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] LoadTypeView view, [NotNull] VLoadType loadtype) : base(view, "ThisLoadType.HeaderString", loadtype, applicationPresenter) { _applicationPresenter = applicationPresenter; ThisLoadType = loadtype; _amountForTesting = 1000; TrueFalse.Add(true); TrueFalse.Add(false); RefreshUsedIn(); }
public HouseholdPlanPresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] HouseholdPlanView view, [NotNull] HouseholdPlan householdPlan) : base(view, "ThisHouseholdPlan.HeaderString", householdPlan, applicationPresenter) { SuspendStatistics = true; CalcObjectTypes = new ObservableCollection <CalcObjectType> { CalcObjectType.ModularHousehold }; _householdPlan = householdPlan; foreach (var entry in _householdPlan.Entries) { entry.AllDeviceActions = Sim.DeviceActions.It; } foreach (var dc in Sim.DeviceCategories.MyItems) { dc.RefreshSubDevices(); } _householdPlan.RefreshTagCategories(Sim.Affordances.It); SortByOptions.Add("By Name"); SortByOptions.Add("By Person"); SortByOptions.Add("By Activiations"); SortByOptions.Add("By Desire"); SortByOptions.Add("By Total Time"); SortByOptions.Add("By Category"); SortBy = SortByOptions[1]; Resort(); if (householdPlan.CalcObject != null) { if (householdPlan.CalcObject.GetType() == typeof(ModularHousehold)) { SelectedCalcObjectType = CalcObjectType.ModularHousehold; } else { throw new LPGException("Unknown "); } } else { SelectedCalcObjectType = CalcObjectType.ModularHousehold; } ColorSchemes.Add("By Activations"); ColorSchemes.Add("By Traits"); SelectedColorScheme = ColorSchemes[0]; RefreshPlan(); RefreshAlTraits(); RefreshAlAssignments(); }
public TimeProfilePresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] TimeProfileView view, [NotNull] TimeBasedProfile tp) : base(view, "ThisProfile.HeaderString", tp, applicationPresenter) { _tp = tp; _csvImporter = new CSVImporter(false); _usedIns = new ObservableCollection <UsedIn>(); TimeProfileTypes.Add(TimeProfileType.Relative); TimeProfileTypes.Add(TimeProfileType.Absolute); RefreshUsedIn(); }
public TimeLimitPresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] TimeLimitView view, [NotNull] TimeLimit timeLimit) : base(view, "ThisTimeLimit.HeaderString", timeLimit, applicationPresenter) { _dtv = view; ThisTimeLimit = timeLimit; _previewGeographicLocation = Sim.GeographicLocations.MyItems[0]; _previewTemperatureProfile = Sim.TemperatureProfiles.MyItems[0]; if (Sim.ModularHouseholds.It.Count > 0) { _household = Sim.ModularHouseholds.MyItems[0]; } MakeCalculatingImage(); if (ThisTimeLimit.RootEntry == null) { ThisTimeLimit.AddTimeLimitEntry(null, Sim.DateBasedProfiles.MyItems); } RefreshAllPermissionLines(); view.SetOneRow(ThisTimeLimit.RootEntry); RefreshUsedIn(); }
public DateBasedProfilePresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] DateBasedProfileView view, [NotNull] DateBasedProfile tp) : base(view, "ThisProfile.HeaderString", tp, applicationPresenter) { _dbp = tp; _csvImporter = new CSVImporter(true); }
public HolidayPresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] HolidayView view, [NotNull] Holiday holiday) : base(view, "ThisHoliday.HeaderString", holiday, applicationPresenter) => _thisHoliday = holiday;
public GeographicLocationPresenter([NotNull] ApplicationPresenter applicationPresenter, [NotNull] GeographicLocationView view, [NotNull] GeographicLocation geoloc) : base(view, "ThisGeographicLocation.HeaderString", geoloc, applicationPresenter) => _geoloc = geoloc;