This is an automated email from the ASF dual-hosted git repository.

jamesfredley pushed a commit to branch spring-boot-4
in repository https://gitbox.apache.org/repos/asf/grails-core.git

commit 0ab833dd13ef7c856848a1f6865b96a1c2338042
Author: James Fredley <[email protected]>
AuthorDate: Fri Mar 20 15:40:43 2026 -0400

    fix: remove theme references from GrailsApplicationContext reintroduced by 
8.0.x merge
    
    Remove ThemeSource field, onRefresh() theme initialization, and
    getTheme() method that were reintroduced by the 8.0.x merge. These
    were deprecated in 7.1 and removed as part of #15457.
    
    Assisted-by: Claude Code <[email protected]>
---
 .../grails/spring/GrailsApplicationContext.java    | 29 ----------------------
 1 file changed, 29 deletions(-)

diff --git 
a/grails-spring/src/main/groovy/org/grails/spring/GrailsApplicationContext.java 
b/grails-spring/src/main/groovy/org/grails/spring/GrailsApplicationContext.java
index 40bbe2daa8..ecfff26168 100644
--- 
a/grails-spring/src/main/groovy/org/grails/spring/GrailsApplicationContext.java
+++ 
b/grails-spring/src/main/groovy/org/grails/spring/GrailsApplicationContext.java
@@ -32,9 +32,6 @@ import 
org.springframework.beans.factory.support.DefaultListableBeanFactory;
 import org.springframework.beans.factory.support.GenericBeanDefinition;
 import org.springframework.context.ApplicationContext;
 import org.springframework.context.support.GenericApplicationContext;
-import org.springframework.ui.context.Theme;
-import org.springframework.ui.context.ThemeSource;
-import org.springframework.ui.context.support.UiApplicationContextUtils;
 
 /**
  * An ApplicationContext that extends StaticApplicationContext and implements 
GroovyObject such that
@@ -47,7 +44,6 @@ public class GrailsApplicationContext extends 
GenericApplicationContext implemen
 
     protected MetaClass metaClass;
     private BeanWrapper ctxBean = new BeanWrapperImpl(this);
-    private ThemeSource themeSource;
     private static final String GRAILS_ENVIRONMENT_BEAN_NAME = 
"springEnvironment";
 
     public GrailsApplicationContext(DefaultListableBeanFactory 
defaultListableBeanFactory) {
@@ -96,31 +92,6 @@ public class GrailsApplicationContext extends 
GenericApplicationContext implemen
         this.metaClass = metaClass;
     }
 
-    /**
-     * Initialize the theme capability.
-     *
-     * @deprecated since 7.1, for removal in 8.0. Spring's theme support 
({@link ThemeSource},
-     * {@link UiApplicationContextUtils#initThemeSource}) is deprecated in 
Spring Boot 3 and
-     * removed in Spring Boot 4. This method will be removed in Grails 8.0.0.
-     */
-    @Deprecated(since = "7.1", forRemoval = true)
-    @Override
-    protected void onRefresh() {
-        themeSource = UiApplicationContextUtils.initThemeSource(this);
-    }
-
-    /**
-     * Return the {@link Theme} instance for the given theme name.
-     *
-     * @deprecated since 7.1, for removal in 8.0. Spring's theme support 
({@link ThemeSource},
-     * {@link Theme}) is deprecated in Spring Boot 3 and removed in Spring 
Boot 4.
-     * This method will be removed in Grails 8.0.0.
-     */
-    @Deprecated(since = "7.1", forRemoval = true)
-    public Theme getTheme(String themeName) {
-        return themeSource.getTheme(themeName);
-    }
-
     public void setProperty(String property, Object newValue) {
         if (newValue instanceof BeanDefinition) {
             if (containsBean(property)) {

Reply via email to