1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 11:27:24 +08:00

Remove redundant type parameter.

Nested type has implicit type parameter from base type.
This commit is contained in:
Huo Yaoyuan 2017-03-21 01:05:48 +08:00
parent df17f2c996
commit 1d13924e0a

View File

@ -16,7 +16,7 @@ namespace osu.Game.Graphics.UserInterface
{ {
public class OsuTabControl<T> : TabControl<T> public class OsuTabControl<T> : TabControl<T>
{ {
protected override DropDownMenu<T> CreateDropDownMenu() => new OsuTabDropDownMenu<T>(); protected override DropDownMenu<T> CreateDropDownMenu() => new OsuTabDropDownMenu();
protected override TabItem<T> CreateTabItem(T value) => new OsuTabItem<T> { Value = value }; protected override TabItem<T> CreateTabItem(T value) => new OsuTabItem<T> { Value = value };
@ -45,7 +45,7 @@ namespace osu.Game.Graphics.UserInterface
set set
{ {
accentColour = value; accentColour = value;
var dropDown = DropDown as OsuTabDropDownMenu<T>; var dropDown = DropDown as OsuTabDropDownMenu;
if (dropDown != null) if (dropDown != null)
dropDown.AccentColour = value; dropDown.AccentColour = value;
foreach (var item in TabContainer.Children.OfType<OsuTabItem<T>>()) foreach (var item in TabContainer.Children.OfType<OsuTabItem<T>>())
@ -53,7 +53,7 @@ namespace osu.Game.Graphics.UserInterface
} }
} }
public class OsuTabDropDownMenu<T1> : OsuDropDownMenu<T1> public class OsuTabDropDownMenu : OsuDropDownMenu<T>
{ {
protected override DropDownHeader CreateHeader() => new OsuTabDropDownHeader protected override DropDownHeader CreateHeader() => new OsuTabDropDownHeader
{ {
@ -62,7 +62,7 @@ namespace osu.Game.Graphics.UserInterface
Origin = Anchor.TopRight, Origin = Anchor.TopRight,
}; };
protected override DropDownMenuItem<T1> CreateDropDownItem(string key, T1 value) protected override DropDownMenuItem<T> CreateDropDownItem(string key, T value)
{ {
var item = base.CreateDropDownItem(key, value); var item = base.CreateDropDownItem(key, value);
item.ForegroundColourHover = Color4.Black; item.ForegroundColourHover = Color4.Black;