KEYCLOAK-1475
This commit is contained in:
parent
0bec2bcd1e
commit
676792d07d
1 changed files with 10 additions and 8 deletions
|
@ -85,8 +85,8 @@ public class ExtendingThemeManager implements ThemeProvider {
|
||||||
|
|
||||||
private Theme loadTheme(String name, Theme.Type type) throws IOException {
|
private Theme loadTheme(String name, Theme.Type type) throws IOException {
|
||||||
Theme theme = findTheme(name, type);
|
Theme theme = findTheme(name, type);
|
||||||
if (theme != null && theme.getParentName() != null) {
|
if (theme != null && (theme.getParentName() != null || theme.getImportName() != null)) {
|
||||||
List<Theme> themes = new LinkedList<Theme>();
|
List<Theme> themes = new LinkedList<>();
|
||||||
themes.add(theme);
|
themes.add(theme);
|
||||||
|
|
||||||
if (theme.getImportName() != null) {
|
if (theme.getImportName() != null) {
|
||||||
|
@ -94,13 +94,15 @@ public class ExtendingThemeManager implements ThemeProvider {
|
||||||
themes.add(findTheme(s[1], Theme.Type.valueOf(s[0].toUpperCase())));
|
themes.add(findTheme(s[1], Theme.Type.valueOf(s[0].toUpperCase())));
|
||||||
}
|
}
|
||||||
|
|
||||||
for (String parentName = theme.getParentName(); parentName != null; parentName = theme.getParentName()) {
|
if (theme.getParentName() != null) {
|
||||||
theme = findTheme(parentName, type);
|
for (String parentName = theme.getParentName(); parentName != null; parentName = theme.getParentName()) {
|
||||||
themes.add(theme);
|
theme = findTheme(parentName, type);
|
||||||
|
themes.add(theme);
|
||||||
|
|
||||||
if (theme.getImportName() != null) {
|
if (theme.getImportName() != null) {
|
||||||
String[] s = theme.getImportName().split("/");
|
String[] s = theme.getImportName().split("/");
|
||||||
themes.add(findTheme(s[1], Theme.Type.valueOf(s[0].toUpperCase())));
|
themes.add(findTheme(s[1], Theme.Type.valueOf(s[0].toUpperCase())));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue