// Checks whether the system is able to use the app. void DetectSystem() { GraphicsAdapter graphicsAdapter = DetectGraphicsAdapter(); supportLevel = graphicsAdapter.SupportLevel; if (graphicsAdapter.SupportLevel != SupportLevel.Full) { forceModeCheckBox.Visibility = Visibility.Visible; } // Has graphics adapter but not app (probably driver update needed). if (graphicsAdapter.SupportLevel != SupportLevel.None && !DetectApp()) { MessageBox.Show("I was unable to locate 'C:/Program Files/NVIDIA Corporation/NVIDIA NvDLISR/nvdlisrwrapper.exe'. Without this app, I cannot do what I am supposed to do.\n\nIt is very likely that your Display Adapter Driver needs updating.", "Prerequisites Missing", MessageBoxButton.OK, MessageBoxImage.Error); } // Has neither the graphics adapter nor the app (probably not NVIDIA). else if (graphicsAdapter.SupportLevel == SupportLevel.None && !DetectApp()) { MessageBox.Show("An NVIDIA GeForce GTX or RTX display adapter is required and neither could not be found.", "Prerequisites Missing", MessageBoxButton.OK, MessageBoxImage.Error); } // Has the app but not the graphics adapter (probably used to have NVIDIA but not anymore; could also be the app not recognising the graphics adapter properly). else if (graphicsAdapter.SupportLevel == SupportLevel.None && DetectApp()) { MessageBox.Show("An NVIDIA GeForce GTX or RTX display adapter is required and neither could not be found.\n\nIf you feel like this is a mistake, enable 'Force Mode'.", "Prerequisites Missing", MessageBoxButton.OK, MessageBoxImage.Error); } UpdateOptions(); systemCheckComplete = true; }
public TicketEntity(int number, SupportLevel difficulty, Dictionary <SupportLevel, int> difficultyToSolveDurationMin, int createAtTicks) { Number = number; Difficulty = difficulty; DifficultyToSolveDurationMin = difficultyToSolveDurationMin; this.createAtTicks = createAtTicks; }
public Protocol(string scheme, SupportLevel username, SupportLevel password, SupportLevel userAndPass) { this.Scheme = scheme; this.Username = username; this.Password = password; this.UserAndPassword = userAndPass; }
public EmployeeType(string name, SupportLevel level, int hourlyWage, decimal successRate, decimal durationFactor) { Name = name; Level = level; HourlyWage = hourlyWage; SuccessRate = successRate; DurationFactor = durationFactor; }
public void EscalateTo(SupportLevel supportLevel, TicketEntity entity) { if (Enum.GetValues(typeof(SupportLevel)).Cast <SupportLevel>().Any(t => t == (supportLevel))) { supportLevelToTicketQueue[supportLevel].Enqueue(entity); return; } throw new ArgumentException("Invalid support level!"); }
public void StopSolving(int ticks, SupportLevel solvedByLevel) { if (solvedByLevel >= Difficulty) { if (stopTicks == null || stopTicks < ticks) { stopTicks = ticks; } } }
public TicketEntity Dequeue(SupportLevel supportLevel, out bool lowerLevel) { lock (supportLevelToTicketQueue) { lowerLevel = false; for (SupportLevel startLevel = supportLevel; startLevel >= SupportLevel.Level1st; startLevel--) { if (supportLevelToTicketQueue[startLevel].TryDequeue(out var rv)) { return(rv); } lowerLevel = true; } return(null); } }
public int TicksToSolve(SupportLevel sp) { return(DifficultyToSolveDurationMin[sp]); }
public bool MoreDifficultyThen(SupportLevel sp) { return(sp < Difficulty); }
public void Enqueue(SupportLevel supportLevel, TicketEntity entity) { supportLevelToTicketQueue[supportLevel].Enqueue(entity); }
public int Count(SupportLevel supportLevel) { return(supportLevelToTicketQueue[supportLevel].Count); }
public bool Available(SupportLevel supportLevel) { return(supportLevelToTicketQueue[supportLevel].Count != 0); }
/// <summary> /// Initializes a new instance of the <see cref="SupportPriority"/> class. /// </summary> /// <param name="pLevel">The level.</param> /// <param name="pSubPriority">The sub priority.</param> public SupportPriority(SupportLevel pLevel, int pSubPriority) { this.Level = pLevel; this.SubPriority = pSubPriority; }