public void IconSectionGUI(NamedBuildTarget namedBuildTarget, ISettingEditorExtension settingsExtension, int platformID, int sectionIndex)
        {
            m_SelectedPlatform = platformID;
            if (!m_Owner.BeginSettingsBox(sectionIndex, SettingsContent.iconTitle))
            {
                m_Owner.EndSettingsBox();
                return;
            }

            var platformUsesStandardIcons = true;

            if (settingsExtension != null)
            {
                platformUsesStandardIcons = settingsExtension.UsesStandardIcons();
            }

            if (platformUsesStandardIcons)
            {
                var selectedDefault = (m_SelectedPlatform < 0);
                // Set default platform variables
                BuildPlatform platform = null;
                namedBuildTarget = NamedBuildTarget.Standalone;
                var platformName = "";

                // Override if a platform is selected
                if (!selectedDefault)
                {
                    platform         = m_ValidPlatforms[m_SelectedPlatform];
                    namedBuildTarget = platform.namedBuildTarget;
                    platformName     = platform.name;
                }

                if (namedBuildTarget == NamedBuildTarget.WebGL || namedBuildTarget == NamedBuildTarget.Server)
                {
                    PlayerSettingsEditor.ShowNoSettings();
                    EditorGUILayout.Space();
                }
                else if (namedBuildTarget != NamedBuildTarget.WindowsStoreApps) // UWP does this in its editor extension
                {
                    // Both default icon and Legacy icons are serialized to the same map
                    // That's why m_LegacyPlatformIcons can be excluded in two places (other place in CommonSettings())
                    using (var vertical = new EditorGUILayout.VerticalScope())
                        using (new EditorGUI.PropertyScope(vertical.rect, GUIContent.none, m_LegacyPlatformIcons))
                        {
                            // Get icons and icon sizes for selected platform (or default)
                            var icons   = PlayerSettings.GetPlatformIconsForTargetIcons(platformName, IconKind.Any, m_AllLegacyIcons);
                            var widths  = PlayerSettings.GetIconWidthsForPlatform(platformName, IconKind.Any);
                            var heights = PlayerSettings.GetIconHeightsForPlatform(platformName, IconKind.Any);
                            var kinds   = PlayerSettings.GetIconKindsForPlatform(platformName);

                            var overrideIcons = true;

                            if (!selectedDefault)
                            {
                                // If the list of icons for this platform is not empty (and has the correct size),
                                // consider the icon overridden for this platform
                                EditorGUI.BeginChangeCheck();
                                overrideIcons = (icons.Length == widths.Length);
                                overrideIcons = GUILayout.Toggle(overrideIcons, string.Format(L10n.Tr("Override for {0}"), platform.title.text));
                                EditorGUI.BeginDisabled(!overrideIcons);
                                var changed = EditorGUI.EndChangeCheck();
                                if (changed || (!overrideIcons && icons.Length > 0))
                                {
                                    // Set the list of icons to correct length if overridden, otherwise to an empty list
                                    if (overrideIcons)
                                    {
                                        icons = new Texture2D[widths.Length];
                                    }
                                    else
                                    {
                                        icons = new Texture2D[0];
                                    }

                                    if (changed)
                                    {
                                        SetLegacyPlatformIcons(platformName, icons, IconKind.Any, ref m_AllLegacyIcons);
                                    }
                                }
                            }

                            // Show the icons for this platform (or default)
                            EditorGUI.BeginChangeCheck();
                            for (int i = 0; i < widths.Length; i++)
                            {
                                var previewWidth  = Mathf.Min(kMaxPreviewSize, widths[i]);
                                var previewHeight = (int)((float)heights[i] * previewWidth / widths[i]); // take into account the aspect ratio

                                if (namedBuildTarget == NamedBuildTarget.iOS)
                                {
                                    // Spotlight icons begin with 120 but there are two in the list.
                                    // So check if the next one is 80.
                                    if (kinds[i] == IconKind.Spotlight && kinds[i - 1] != IconKind.Spotlight)
                                    {
                                        var labelRect = GUILayoutUtility.GetRect(EditorGUIUtility.labelWidth, 20);
                                        GUI.Label(new Rect(labelRect.x, labelRect.y, EditorGUIUtility.labelWidth, 20), "Spotlight icons", EditorStyles.boldLabel);
                                    }

                                    if (kinds[i] == IconKind.Settings && kinds[i - 1] != IconKind.Settings)
                                    {
                                        var labelRect = GUILayoutUtility.GetRect(EditorGUIUtility.labelWidth, 20);
                                        GUI.Label(new Rect(labelRect.x, labelRect.y, EditorGUIUtility.labelWidth, 20), "Settings icons", EditorStyles.boldLabel);
                                    }

                                    if (kinds[i] == IconKind.Notification && kinds[i - 1] != IconKind.Notification)
                                    {
                                        var labelRect = GUILayoutUtility.GetRect(EditorGUIUtility.labelWidth, 20);
                                        GUI.Label(new Rect(labelRect.x, labelRect.y, EditorGUIUtility.labelWidth, 20), "Notification icons", EditorStyles.boldLabel);
                                    }

                                    if (kinds[i] == IconKind.Store && kinds[i - 1] != IconKind.Store)
                                    {
                                        var labelRect = GUILayoutUtility.GetRect(EditorGUIUtility.labelWidth, 20);
                                        GUI.Label(new Rect(labelRect.x, labelRect.y, EditorGUIUtility.labelWidth, 20), "App Store icons", EditorStyles.boldLabel);
                                    }
                                }

                                var rect  = GUILayoutUtility.GetRect(kSlotSize, Mathf.Max(kSlotSize, previewHeight) + kIconSpacing);
                                var width = Mathf.Min(rect.width, EditorGUIUtility.labelWidth + 4 + kSlotSize + kIconSpacing + kMaxPreviewSize);

                                // Label
                                var label = widths[i] + "x" + heights[i];
                                GUI.Label(new Rect(rect.x, rect.y, width - kMaxPreviewSize - kSlotSize - 2 * kIconSpacing, 20), label);

                                // Texture slot
                                if (overrideIcons)
                                {
                                    var slotWidth  = kSlotSize;
                                    var slotHeight = (int)((float)heights[i] / widths[i] * kSlotSize); // take into account the aspect ratio
                                    icons[i] = (Texture2D)EditorGUI.ObjectField(
                                        new Rect(rect.x + width - kMaxPreviewSize - kSlotSize - kIconSpacing, rect.y, slotWidth, slotHeight),
                                        icons[i],
                                        typeof(Texture2D),
                                        false);
                                }

                                // Preview
                                var previewRect = new Rect(rect.x + width - kMaxPreviewSize, rect.y, previewWidth, previewHeight);
                                var closestIcon = PlayerSettings.GetPlatformIconForSizeForTargetIcons(platformName, widths[i], heights[i], kinds[i], m_AllLegacyIcons);
                                if (closestIcon != null)
                                {
                                    GUI.DrawTexture(previewRect, closestIcon);
                                }
                                else
                                {
                                    GUI.Box(previewRect, "");
                                }
                            }

                            // Save changes
                            if (EditorGUI.EndChangeCheck())
                            {
                                Undo.RecordObjects(m_Owner.targets, SettingsContent.undoChangedIconString);
                                SetLegacyPlatformIcons(platformName, icons, IconKind.Any, ref m_AllLegacyIcons);
                            }

                            EditorGUI.EndDisabled();

                            if (namedBuildTarget == NamedBuildTarget.iOS || namedBuildTarget == NamedBuildTarget.tvOS)
                            {
                                EditorGUILayout.PropertyField(m_UIPrerenderedIcon, SettingsContent.UIPrerenderedIcon);
                                EditorGUILayout.Space();
                            }
                        }
                }
            }

            if (settingsExtension != null)
            {
                settingsExtension.IconSectionGUI();
            }

            m_Owner.EndSettingsBox();
        }