[confirm] GUI Settings -> Skip step configuration not localized (1 Viewer)

pilehave

Community Skin Designer
  • Premium Supporter
  • April 2, 2008
    2,566
    521
    Hornslet
    Home Country
    Denmark Denmark
    Current SVN;

    GUISettingsSkipSteps.cs is using hardcoded labels, even though localized versions are defined in english (and other languages):

    Code:
        private string verifySkipStep(string newStep)
        {
          int step;
          //int multiplyer = 1;
          //if (newStep.IndexOf('s') == (newStep.Length - 1) || newStep.IndexOf('S') == (newStep.Length - 1))
          //{
          //  newStep = newStep.Substring(0, newStep.Length - 1);
          //}
          //else if (newStep.IndexOf('m') == (newStep.Length - 1) || newStep.IndexOf('M') == (newStep.Length - 1))
          //{
          //  newStep = newStep.Substring(0, newStep.Length - 1);
          //  multiplyer = 60;
          //}
          //else if (newStep.IndexOf('m') == (newStep.Length - 1) || newStep.IndexOf('M') == (newStep.Length - 1))
          //{
          //  newStep = newStep.Substring(0, newStep.Length - 1);
          //  multiplyer = 3600;
          //} -- This doesn't really help the user a lot, so it's not worth the trouble
          try
          {
            step = Convert.ToInt16(newStep);
          }
          catch (Exception)
          {
            return "Not a valid integer";
          }
          //step *= multiplyer;
          if (step < 0)
          {
            return "Postive values only!";
          }
          else if (step == 0)
          {
            return "Zero skip is not allowed!";
          }
          else if (step > 10800)
          {
            return "3 hour skip is maximum!";
          }
          else
          {
            // Check that whole minutes are entered
            if (step > 60 && (step % 60) != 0)
            {
              return "Enter whole minutes only!";
            }
          }
          if (CheckExists(step))
          {
            return "Skip step already defined";
          }
          return null;
        }
     

    Users who are viewing this thread

    Top Bottom