Skip to content

[CQ] migrate from deprecated LayeredIcon constructor #8203

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 20, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions flutter-idea/src/io/flutter/utils/CustomIconMaker.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ public Icon getCustomIcon(String fromText, IconKind kind, boolean isAbstract) {

if (!iconCache.containsKey(mapKey)) {
final Icon baseIcon = isAbstract ? kind.abstractIcon : kind.icon;

final Icon icon = new LayeredIcon(baseIcon, new Icon() {
final Icon icon = LayeredIcon.layeredIcon(() -> new Icon[]{baseIcon, new Icon() {
public void paintIcon(Component c, Graphics g, int x, int y) {
final Graphics2D g2 = (Graphics2D)g.create();

Expand Down Expand Up @@ -78,7 +78,7 @@ public int getIconWidth() {
public int getIconHeight() {
return baseIcon != null ? baseIcon.getIconHeight() : 13;
}
});
}});

iconCache.put(mapKey, icon);
}
Expand Down