Skip to content

Commit fb607f1

Browse files
committedDec 26, 2020
8245922: [macos] Taskbar.Feature.ICON_BADGE_NUMBER no longer supported on MacOS
Reviewed-by: kcr, prr
1 parent 3f67afd commit fb607f1

File tree

2 files changed

+3
-17
lines changed

2 files changed

+3
-17
lines changed
 

‎src/java.desktop/macosx/classes/apple/laf/JRSUIUtils.java

+1-12
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2011, 2020, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -36,17 +36,12 @@ public final class JRSUIUtils {
3636

3737
static boolean isLeopard = isMacOSXLeopard();
3838
static boolean isSnowLeopardOrBelow = isMacOSXSnowLeopardOrBelow();
39-
static boolean isCatalinaOrAbove = isMacOSXCatalinaOrAbove();
4039
static boolean isBigSurOrAbove = isMacOSXBigSurOrAbove();
4140

4241
public static boolean isMacOSXBigSurOrAbove() {
4342
return currentMacOSXVersionMatchesGivenVersionRange(16, true, false, true);
4443
}
4544

46-
static boolean isMacOSXCatalinaOrAbove() {
47-
return currentMacOSXVersionMatchesGivenVersionRange(15, true, false, true);
48-
}
49-
5045
static boolean isMacOSXLeopard() {
5146
return isCurrentMacOSXVersion(5);
5247
}
@@ -84,12 +79,6 @@ static boolean currentMacOSXVersionMatchesGivenVersionRange(
8479
return false;
8580
}
8681

87-
public static class TaskBar {
88-
public static boolean isIconBadgeSupported() {
89-
return !isCatalinaOrAbove;
90-
}
91-
}
92-
9382
public static class TabbedPane {
9483
public static boolean useLegacyTabs() {
9584
return isLeopard;

‎src/java.desktop/macosx/classes/sun/lwawt/macosx/CTaskbarPeer.java

+2-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -25,14 +25,12 @@
2525

2626
package sun.lwawt.macosx;
2727

28+
import com.apple.eawt.Application;
2829
import java.awt.Image;
2930
import java.awt.PopupMenu;
3031
import java.awt.Taskbar.Feature;
3132
import java.awt.peer.TaskbarPeer;
3233

33-
import apple.laf.JRSUIUtils;
34-
import com.apple.eawt.Application;
35-
3634
final public class CTaskbarPeer implements TaskbarPeer {
3735

3836
CTaskbarPeer() {}
@@ -42,7 +40,6 @@ public boolean isSupported(Feature feature) {
4240
switch(feature) {
4341
case ICON_BADGE_TEXT:
4442
case ICON_BADGE_NUMBER:
45-
return JRSUIUtils.TaskBar.isIconBadgeSupported();
4643
case ICON_IMAGE:
4744
case MENU:
4845
case PROGRESS_VALUE:

0 commit comments

Comments
 (0)
Please sign in to comment.