@@ -148,7 +148,7 @@ void Start()
148148//Properties.Settings.Default.projectPaths = null;
149149//Properties.Settings.Default.Save();
150150
151- projectsSource = GetProjects . Scan ( getGitBranch : ( bool ) chkShowGitBranchColumn . IsChecked , getPlasticBranch : ( bool ) chkCheckPlasticBranch . IsChecked , getArguments : ( bool ) chkShowLauncherArgumentsColumn . IsChecked , showMissingFolders : ( bool ) chkShowMissingFolderProjects . IsChecked , showTargetPlatform : ( bool ) chkShowPlatform . IsChecked , AllProjectPaths : Properties . Settings . Default . projectPaths , searchGitbranchRecursivly : ( bool ) chkGetGitBranchRecursively . IsChecked ) ;
151+ projectsSource = GetProjects . Scan ( getGitBranch : ( bool ) chkShowGitBranchColumn . IsChecked , getPlasticBranch : ( bool ) chkCheckPlasticBranch . IsChecked , getArguments : ( bool ) chkShowLauncherArgumentsColumn . IsChecked , showMissingFolders : ( bool ) chkShowMissingFolderProjects . IsChecked , showTargetPlatform : ( bool ) chkShowPlatform . IsChecked , AllProjectPaths : Properties . Settings . Default . projectPaths , searchGitbranchRecursivly : ( bool ) chkGetGitBranchRecursively . IsChecked , showSRP : ( bool ) chkCheckSRP . IsChecked ) ;
152152
153153//Console.WriteLine("projectsSource.Count: " + projectsSource.Count);
154154
@@ -453,6 +453,7 @@ void LoadSettings()
453453chkEnableProjectRename . IsChecked = Settings . Default . enableProjectRename ;
454454chkStreamerMode . IsChecked = Settings . Default . streamerMode ;
455455chkShowPlatform . IsChecked = Settings . Default . showTargetPlatform ;
456+ chkCheckSRP . IsChecked = Settings . Default . checkSRP ;
456457chkUseCustomTheme . IsChecked = Settings . Default . useCustomTheme ;
457458txtRootFolderForNewProjects . Text = Settings . Default . newProjectsRoot ;
458459txtWebglRelativePath . Text = Settings . Default . webglBuildPath ;
@@ -467,6 +468,7 @@ void LoadSettings()
467468gridRecent . Columns [ 4 ] . Visibility = ( bool ) chkShowLauncherArgumentsColumn . IsChecked ? Visibility . Visible : Visibility . Collapsed ;
468469gridRecent . Columns [ 5 ] . Visibility = ( bool ) chkShowGitBranchColumn . IsChecked ? Visibility . Visible : Visibility . Collapsed ;
469470gridRecent . Columns [ 6 ] . Visibility = ( bool ) chkShowPlatform . IsChecked ? Visibility . Visible : Visibility . Collapsed ;
471+ gridRecent . Columns [ 7 ] . Visibility = ( bool ) chkCheckSRP . IsChecked ? Visibility . Visible : Visibility . Collapsed ;
470472
471473// update installations folder listbox
472474lstRootFolders . Items . Clear ( ) ;
@@ -654,9 +656,9 @@ private void SaveSettingsOnExit()
654656List < int > gridWidths ;
655657
656658// if we dont have any settings yet
657- if ( Properties . Settings . Default . gridColumnWidths != null )
659+ if ( Settings . Default . gridColumnWidths != null )
658660{
659- gridWidths = new List < int > ( Properties . Settings . Default . gridColumnWidths ) ;
661+ gridWidths = new List < int > ( Settings . Default . gridColumnWidths ) ;
660662}
661663else
662664{
@@ -667,7 +669,7 @@ private void SaveSettingsOnExit()
667669var column = gridRecent . Columns [ 0 ] ;
668670for ( int i = 0 ; i < gridRecent . Columns . Count ; ++ i )
669671{
670- if ( Properties . Settings . Default . gridColumnWidths != null && Properties . Settings . Default . gridColumnWidths . Length > i )
672+ if ( Settings . Default . gridColumnWidths != null && Settings . Default . gridColumnWidths . Length > i )
671673{
672674gridWidths [ i ] = ( int ) gridRecent . Columns [ i ] . Width . Value ;
673675}
@@ -676,17 +678,17 @@ private void SaveSettingsOnExit()
676678gridWidths . Add ( ( int ) gridRecent . Columns [ i ] . Width . Value ) ;
677679}
678680}
679- Properties . Settings . Default . gridColumnWidths = gridWidths . ToArray ( ) ;
680- Properties . Settings . Default . Save ( ) ;
681+ Settings . Default . gridColumnWidths = gridWidths . ToArray ( ) ;
682+ Settings . Default . Save ( ) ;
681683
682684
683685// save buildrepot column widths
684686gridWidths . Clear ( ) ;
685687
686688// if we dont have any settings yet
687- if ( Properties . Settings . Default . gridColumnWidthsBuildReport != null )
689+ if ( Settings . Default . gridColumnWidthsBuildReport != null )
688690{
689- gridWidths = new List < int > ( Properties . Settings . Default . gridColumnWidthsBuildReport ) ;
691+ gridWidths = new List < int > ( Settings . Default . gridColumnWidthsBuildReport ) ;
690692}
691693else
692694{
@@ -697,7 +699,7 @@ private void SaveSettingsOnExit()
697699column = gridBuildReport . Columns [ 0 ] ;
698700for ( int i = 0 ; i < gridBuildReport . Columns . Count ; ++ i )
699701{
700- if ( Properties . Settings . Default . gridColumnWidthsBuildReport != null && Properties . Settings . Default . gridColumnWidthsBuildReport . Length > i )
702+ if ( Settings . Default . gridColumnWidthsBuildReport != null && Settings . Default . gridColumnWidthsBuildReport . Length > i )
701703{
702704gridWidths [ i ] = ( int ) gridBuildReport . Columns [ i ] . Width . Value ;
703705}
@@ -706,9 +708,9 @@ private void SaveSettingsOnExit()
706708gridWidths . Add ( ( int ) gridBuildReport . Columns [ i ] . Width . Value ) ;
707709}
708710}
709- Properties . Settings . Default . gridColumnWidthsBuildReport = gridWidths . ToArray ( ) ;
710- Properties . Settings . Default . projectName = projectNameSetting ;
711- Properties . Settings . Default . Save ( ) ;
711+ Settings . Default . gridColumnWidthsBuildReport = gridWidths . ToArray ( ) ;
712+ Settings . Default . projectName = projectNameSetting ;
713+ Settings . Default . Save ( ) ;
712714
713715// make backup
714716var config = ConfigurationManager . OpenExeConfiguration ( ConfigurationUserLevel . PerUserRoamingAndLocal ) ;
@@ -813,7 +815,7 @@ public void RefreshRecentProjects()
813815// take currently selected project row
814816lastSelectedProjectIndex = gridRecent . SelectedIndex ;
815817// rescan recent projects
816- projectsSource = GetProjects . Scan ( getGitBranch : ( bool ) chkShowGitBranchColumn . IsChecked , getPlasticBranch : ( bool ) chkCheckPlasticBranch . IsChecked , getArguments : ( bool ) chkShowLauncherArgumentsColumn . IsChecked , showMissingFolders : ( bool ) chkShowMissingFolderProjects . IsChecked , showTargetPlatform : ( bool ) chkShowPlatform . IsChecked , AllProjectPaths : Settings . Default . projectPaths , searchGitbranchRecursivly : ( bool ) chkGetGitBranchRecursively . IsChecked ) ;
818+ projectsSource = GetProjects . Scan ( getGitBranch : ( bool ) chkShowGitBranchColumn . IsChecked , getPlasticBranch : ( bool ) chkCheckPlasticBranch . IsChecked , getArguments : ( bool ) chkShowLauncherArgumentsColumn . IsChecked , showMissingFolders : ( bool ) chkShowMissingFolderProjects . IsChecked , showTargetPlatform : ( bool ) chkShowPlatform . IsChecked , AllProjectPaths : Settings . Default . projectPaths , searchGitbranchRecursivly : ( bool ) chkGetGitBranchRecursively . IsChecked , showSRP : ( bool ) chkCheckSRP . IsChecked ) ;
817819gridRecent . ItemsSource = projectsSource ;
818820
819821// fix sorting on refresh
@@ -3332,6 +3334,12 @@ public int Compare(Object a, Object b)
33323334if ( ( ( Project ) a ) . TargetPlatform == null ) return direction == ListSortDirection . Ascending ? - 1 : 1 ;
33333335if ( ( ( Project ) b ) . TargetPlatform == null ) return direction == ListSortDirection . Ascending ? 1 : - 1 ;
33343336return direction == ListSortDirection . Ascending ? ( ( Project ) a ) . TargetPlatform . CompareTo ( ( ( Project ) b ) . TargetPlatform ) : ( ( Project ) b ) . TargetPlatform . CompareTo ( ( ( Project ) a ) . TargetPlatform ) ;
3337+ case "SRP" :
3338+ // handle null values
3339+ if ( ( ( Project ) a ) . SRP == null && ( ( Project ) b ) . SRP == null ) return 0 ;
3340+ if ( ( ( Project ) a ) . SRP == null ) return direction == ListSortDirection . Ascending ? - 1 : 1 ;
3341+ if ( ( ( Project ) b ) . SRP == null ) return direction == ListSortDirection . Ascending ? 1 : - 1 ;
3342+ return direction == ListSortDirection . Ascending ? ( ( Project ) a ) . SRP . CompareTo ( ( ( Project ) b ) . SRP ) : ( ( Project ) b ) . SRP . CompareTo ( ( ( Project ) a ) . SRP ) ;
33353343default :
33363344return 0 ;
33373345}
@@ -3798,6 +3806,17 @@ private void CheckCustomIcon()
37983806//Debug.WriteLine("Custom icon not found. Using default.");
37993807}
38003808}
3809+
3810+ private void chkCheckSRP_Checked ( object sender , RoutedEventArgs e )
3811+ {
3812+ if ( this . IsActive == false ) return ; // dont run code on window init
3813+
3814+ gridRecent . Columns [ 7 ] . Visibility = ( bool ) chkCheckSRP . IsChecked ? Visibility . Visible : Visibility . Collapsed ;
3815+
3816+ Settings . Default . checkSRP = ( bool ) chkCheckSRP . IsChecked ;
3817+ Settings . Default . Save ( ) ;
3818+ RefreshRecentProjects ( ) ;
3819+ }
38013820//private void menuProjectProperties_Click(object sender, RoutedEventArgs e)
38023821//{
38033822// var proj = GetSelectedProject();