Skip to content

Commit

Permalink
allow creating temp themes without dedicated classloader
Browse files Browse the repository at this point in the history
  • Loading branch information
bulenkov committed Jan 9, 2019
1 parent 4591c09 commit d1c6b41
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions platform/platform-impl/src/com/intellij/ide/ui/UITheme.java
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,12 @@ public String getAuthor() {
return author;
}

public static UITheme loadFromJson(InputStream stream, @NotNull String themeId, @NotNull ClassLoader provider) throws IOException {
public static UITheme loadFromJson(InputStream stream, @NotNull String themeId, @Nullable ClassLoader provider) throws IOException {
UITheme theme = new ObjectMapper().readValue(stream, UITheme.class);
theme.id = themeId;
theme.providerClassLoader = provider;
if (provider != null) {
theme.providerClassLoader = provider;
}
if (theme.icons != null && !theme.icons.isEmpty()) {
theme.patcher = new IconPathPatcher() {
@Nullable
Expand Down

0 comments on commit d1c6b41

Please sign in to comment.