예제 #1
0
        public static String getName(String titleName, String platform)
        {
            String platformName = PlatformModel.GetPlatformName(platform);
            String ViewName     = null;

            switch (IniModel.GetGameView())
            {
            case GameViewModel.DEFAULT:
                ViewName = titleName + " - " + platformName;
                break;

            case GameViewModel.PLATFORM_SHORTCUT:
                ViewName = titleName + " - " + platform;
                break;

            case GameViewModel.GAME_NAME_ONLY:
                ViewName = titleName;
                break;

            default:
                ViewName = titleName + " - " + platformName;
                break;
            }
            return(ViewName);
        }
예제 #2
0
파일: IniModel.cs 프로젝트: eai04191/OnPS
        /* GetPSNPlatform */

        public static String GetPSNPlatform()
        {
            if (!Program.iniFile.KeyExists(PLATFORM, PSN) || PlatformModel.GetPlatformName(Program.iniFile.Read(PLATFORM, PSN)) == null)
            {
                Program.iniFile.Write(PLATFORM, PlatformModel.PS4, PSN);
            }
            return(Program.iniFile.Read(PLATFORM, PSN));
        }
예제 #3
0
파일: IniModel.cs 프로젝트: eai04191/OnPS
 public static void SetPSNPlatform(String value)
 {
     if (PlatformModel.GetPlatformName(value) == null)
     {
         Program.iniFile.Write(PLATFORM, PlatformModel.PS4, PSN);
     }
     else
     {
         Program.iniFile.Write(PLATFORM, value, PSN);
     }
 }
예제 #4
0
        public static ArrayList GetAvailablePlatforms(String onlineId)
        {
            String Path = Program.SavePath + @"\profiles\" + onlineId;

            if (!Directory.Exists(Path))
            {
                Directory.CreateDirectory(Path);
            }
            ArrayList availablePlatformList = new ArrayList();
            var       directories           = Directory.GetDirectories(Path);

            foreach (var directory in directories)
            {
                String[] arr      = directory.Split('\\');
                String   platform = arr[arr.Length - 1];
                if (PlatformModel.GetPlatformName(platform) != null)
                {
                    availablePlatformList.Add(platform);
                }
            }
            return(availablePlatformList);
        }