[jira] [Created] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
Daniel Zwicker created WICKET-5252: -- Summary: PropertyResolver breaks immutable objects by calling setAccessible Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13693812#comment-13693812 ] Martin Grigorov commented on WICKET-5252: - Then why you use such object in a (property)model ?! This is not a problem of Wicket. Wicket doesn't know of/use your objects unless you tell it. PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13693816#comment-13693816 ] Daniel Zwicker commented on WICKET-5252: I know that wicket doesn't know how to use my object. But i would expect an exception in the case that wicket want to set a property and this property is not accessible. So i get aware of this situation and can think about the solution. But just accessing this private field should not be the decision of wicket. As -you are right- can't know how to use my objects. PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Martin Grigorov resolved WICKET-5252. - Resolution: Won't Fix PropertyModel's javadoc explains that: * Note that the property resolver by default provides access to private members and methods. If * guaranteeing encapsulation of the target objects is a big concern, you should consider using an * alternative implementation. As I said earlier - you should not use PropertyModel if you want to use immutable model object. You can use AbstractReadOnlyModel if you want just read access. PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
git commit: WICKET-5130 removed fix for select z-index bug in IE 7
Updated Branches: refs/heads/master 8c21ccf8c - 835223065 WICKET-5130 removed fix for select z-index bug in IE 7 Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/83522306 Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/83522306 Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/83522306 Branch: refs/heads/master Commit: 8352230656fedb01c5a3569f684ebfd4d72c37bd Parents: 8c21ccf Author: svenmeier s...@meiers.net Authored: Wed Jun 26 10:13:05 2013 +0200 Committer: svenmeier s...@meiers.net Committed: Wed Jun 26 10:13:05 2013 +0200 -- .../AbstractAutoCompleteBehavior.java | 4 +- .../html/autocomplete/AutoCompleteSettings.java | 40 +++ .../html/autocomplete/wicket-autocomplete.js| 53 +--- 3 files changed, 9 insertions(+), 88 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/83522306/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java -- diff --git a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java index 9105f73..a9360a7 100644 --- a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java +++ b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java @@ -150,9 +150,9 @@ public abstract class AbstractAutoCompleteBehavior extends AbstractDefaultAjaxBe sb.append(,maxHeight: ).append(settings.getMaxHeightInPx()); sb.append(,adjustInputWidth: ).append(settings.isAdjustInputWidth()); sb.append(,useSmartPositioning: ).append(settings.getUseSmartPositioning()); - sb.append(,useHideShowCoveredIEFix: ).append(settings.getUseHideShowCoveredIEFix()); sb.append(,showListOnEmptyInput: ).append(settings.getShowListOnEmptyInput()); - sb.append(,ignoreBordersWhenPositioning: ).append(settings.getIgnoreBordersWhenPositioning()); + sb.append(,ignoreBordersWhenPositioning: ).append( + settings.getIgnoreBordersWhenPositioning()); sb.append(,showListOnFocusGain: ).append(settings.getShowListOnFocusGain()); sb.append(,throttleDelay: ).append(settings.getThrottleDelay()); sb.append(,parameterName: ').append(settings.getParameterName()).append('\''); http://git-wip-us.apache.org/repos/asf/wicket/blob/83522306/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AutoCompleteSettings.java -- diff --git a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AutoCompleteSettings.java b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AutoCompleteSettings.java index 8f784ad..0bd6aa8 100644 --- a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AutoCompleteSettings.java +++ b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AutoCompleteSettings.java @@ -59,8 +59,6 @@ public final class AutoCompleteSettings implements IClusterable private boolean ignoreBordersWhenPositioning = true; - private boolean useHideShowCoveredIEFix = true; - private String cssClassName = null; private boolean adjustInputWidth = true; @@ -160,7 +158,7 @@ public final class AutoCompleteSettings implements IClusterable /** * Indicates whether the popup positioning will take into account the borders of the input * element and its ancestors. -* +* * @return true if borders are ignored, false otherwise. */ public boolean getIgnoreBordersWhenPositioning() @@ -172,12 +170,13 @@ public final class AutoCompleteSettings implements IClusterable * Sets whether the popup positioning will take into account the borders of the input element * and its ancestors (by including the codeclientLeft/code and codeclientTop/code DOM * properties in the computation). -* +* * @param ignoreBordersWhenPositioning *the flag * @return this {@link AutoCompleteSettings}. */ - public AutoCompleteSettings setIgnoreBordersWhenPositioning(final boolean
[jira] [Updated] (WICKET-5130) AutoCompleteTextField hides combo boxes - remove setting
[ https://issues.apache.org/jira/browse/WICKET-5130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sven Meier updated WICKET-5130: --- Priority: Minor (was: Major) Issue Type: Task (was: Bug) AutoCompleteTextField hides combo boxes - remove setting Key: WICKET-5130 URL: https://issues.apache.org/jira/browse/WICKET-5130 Project: Wicket Issue Type: Task Affects Versions: 6.6.0 Environment: tested on Windows 7, IE9, valid also for IE7 and IE8 Reporter: Betlista Assignee: Sven Meier Priority: Minor Labels: autocomplete, autocompletetextfield Fix For: 7.0.0 Attachments: ScreenShot326.png, ScreenShot327.png, ScreenShot328.png When I have AutoCompleteTextField in form and there are DropDowns below the autocomplete text field, AutoCompleteTextField drop down hides components below. Steps to simulate the behaviour: 1.) I created maven project mvn archetype:generate -DarchetypeGroupId=org.apache.wicket -DarchetypeArtifactId=wicket-archetype-quickstart -DarchetypeVersion=6.6.0 -DgroupId=net.betlista -DartifactId=bugs-dropdown -DarchetypeRepository=https://repository.apache.org/ -DinteractiveMode=false 2.) in pom.xml I enabled extensions 3.) I changed getHomePage() in WicketApplication application to show my new test page 4.) page markup is !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN http://www.w3.org/TR/html4/loose.dtd; html head meta http-equiv=Content-Type content=text/html; charset=UTF-8 titleInsert title here/title /head body form input type=text wicket:id=auto/br select wicket:id=drop1/selectbr select wicket:id=drop2/selectbr input type=text wicket:id=text/br /form /body /html 5.) Java class for page is package net.betlista; import java.util.Iterator; import java.util.LinkedList; import java.util.List; import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteTextField; import org.apache.wicket.markup.html.WebPage; import org.apache.wicket.markup.html.form.DropDownChoice; import org.apache.wicket.markup.html.form.TextField; public class AutoCompleteAndDropDownTestPage extends WebPage { public AutoCompleteAndDropDownTestPage() { add(new AutoCompleteTextFieldInteger(auto) { @Override protected IteratorInteger getChoices(final String input) { return getNewList(20).iterator(); } }); add(new DropDownChoiceInteger(drop1, getNewList(15))); add(new DropDownChoiceInteger(drop2, getNewList(10))); add(new TextFieldString(text)); } private static ListInteger getNewList(final int upTo) { final LinkedListInteger list = new LinkedListInteger(); for (int i = 0; i upTo; i++) { list.add(i); } return list; } } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (WICKET-5130) AutoCompleteTextField hides combo boxes - remove setting
[ https://issues.apache.org/jira/browse/WICKET-5130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sven Meier resolved WICKET-5130. Resolution: Fixed fix for IE7 is now removed AutoCompleteTextField hides combo boxes - remove setting Key: WICKET-5130 URL: https://issues.apache.org/jira/browse/WICKET-5130 Project: Wicket Issue Type: Task Affects Versions: 6.6.0 Environment: tested on Windows 7, IE9, valid also for IE7 and IE8 Reporter: Betlista Assignee: Sven Meier Priority: Minor Labels: autocomplete, autocompletetextfield Fix For: 7.0.0 Attachments: ScreenShot326.png, ScreenShot327.png, ScreenShot328.png When I have AutoCompleteTextField in form and there are DropDowns below the autocomplete text field, AutoCompleteTextField drop down hides components below. Steps to simulate the behaviour: 1.) I created maven project mvn archetype:generate -DarchetypeGroupId=org.apache.wicket -DarchetypeArtifactId=wicket-archetype-quickstart -DarchetypeVersion=6.6.0 -DgroupId=net.betlista -DartifactId=bugs-dropdown -DarchetypeRepository=https://repository.apache.org/ -DinteractiveMode=false 2.) in pom.xml I enabled extensions 3.) I changed getHomePage() in WicketApplication application to show my new test page 4.) page markup is !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN http://www.w3.org/TR/html4/loose.dtd; html head meta http-equiv=Content-Type content=text/html; charset=UTF-8 titleInsert title here/title /head body form input type=text wicket:id=auto/br select wicket:id=drop1/selectbr select wicket:id=drop2/selectbr input type=text wicket:id=text/br /form /body /html 5.) Java class for page is package net.betlista; import java.util.Iterator; import java.util.LinkedList; import java.util.List; import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteTextField; import org.apache.wicket.markup.html.WebPage; import org.apache.wicket.markup.html.form.DropDownChoice; import org.apache.wicket.markup.html.form.TextField; public class AutoCompleteAndDropDownTestPage extends WebPage { public AutoCompleteAndDropDownTestPage() { add(new AutoCompleteTextFieldInteger(auto) { @Override protected IteratorInteger getChoices(final String input) { return getNewList(20).iterator(); } }); add(new DropDownChoiceInteger(drop1, getNewList(15))); add(new DropDownChoiceInteger(drop2, getNewList(10))); add(new TextFieldString(text)); } private static ListInteger getNewList(final int upTo) { final LinkedListInteger list = new LinkedListInteger(); for (int i = 0; i upTo; i++) { list.add(i); } return list; } } -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13693829#comment-13693829 ] Daniel Zwicker commented on WICKET-5252: Hm. Ok. I will tell my team to refactor all places the PropertyModel is used. But i believe this i a huge problem. Every tutorial for wicket told you to use this PropertyModel! And there is no remark about this behavior! Perhaps you understand the problem with this more when i told you what happen in our project. We have these immutable object. Everybody in the backend team knows these object. Now in the Frontendteam used new AjaxCheckBox(marker). So. I have told him the cause of our bug and he directly respond args immutable.. Sorry. Perhaps a solution would be a configuration switch to configure PropertyResolver to throw exceptions in these cases. So everybody can pay attention to this. PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13693833#comment-13693833 ] Martin Grigorov commented on WICKET-5252: - Well, I cannot help with other people's tutorials. But we can improve Wicket's javadocs. PropertyModel explains all this. We can extend PropertyResolver's javadoc as well. My training materials cover this and I explain that this may lead to problems when SecuriyManager is in use. Feel free to open a new ticket for the new setting. PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[CONF] Apache Wicket Migration to Wicket 7.0
Migration to Wicket 7.0 Page edited by Martin Grigorov Changes (1) ... org.apache.wicket.Component#setResponsePage(page) just delegates to org.apache.wicket.request.cycle.RequestCycle#setResponsePage() that required just IRequestablePage. h5. AutoCompleteTextField doesnt support _useHideShowCoveredIEFix_ setting [WICKET-5130|https://issues.apache.org/jira/browse/WICKET-5130] _useHideShowCoveredIEFix_ setting was needed for IE7 support. This version of IE is not supported officially anymore and this setting has been removed. h3. Behavior changes ... Full Content Migrating to Wicket 7.0 Environment Wicket 7.0 requires at least Java 7 Wicket 7.0 requires Servlet 3.0 The HTTP response is not flushed automatically when the request is started in asynchronous mode. WICKET-5152 API changes org/apache/wicket/core/util/io/SerializableChecker is replaced with org.apache.wicket.core.util.objects.checker.CheckingObjectOutputStream WICKET-4817 org/apache/wicket/markup/html/border/BoxBorder is removed with no replacement WICKET-4966. org.apache.wicket.Component#renderHead(HtmlHeaderContainer) is renamed to Component#internalRenderHead(HtmlHeaderContainer) WICKET-4964 org.apache.wicket.request.resource.ResourceReference#getDependencies() now returns a mutable ListHeaderItem WICKET-5124 org.apache.wicket.model.StringResourceModel constructor accepts IModelString for its default value WICKET-4972 org.apache.wicket.extensions.validation.validator.+Xyz+Validator#decorate() now works with IValidationError WICKET-5174 org.apache.wicket.ajax.attributes.AjaxRequestAttributes#setAllowDefault is renamed to #setPreventDefault WICKET-5197 org.apache.wicket.ajax.attributes.AjaxRequestAttributes#eventPropagation is now BUBBLE by default WICKET-5198 org.apache.wicket.ajax.form.AjaxFormValidatingBehavior doesn't use static methods anymore WICKET-5196 org.apache.wicket.ajax.AjaxRequestTarget.IListener#updateAjaxAttributes() is introduced WICKET-5212 org.apache.wicket.ISessionListener#onUnbound(String) is added WICKET-5213 (Base)WicketTester uses org.junit.Assert instead of junit.framework.Assert org.apache.wicket.Component#setMetaData() value could be only a Serializable WICKET-5227 org.apache.wicket.Application#getHeaderContributorListenerCollection() is renamed to #getHeaderContributorListeners() org.apache.wicket.authorization.IAuthorizationStrategy#isResourceAuthorized(IResource, PageParameters) is introduced WICKET-5012 org.apache.wicket.Component#setResponsePage() now accepts org.apache.wicket.request.component.IRequestablePage instead of org.apache.wicket.Page AutoCompleteTextField doesn't support useHideShowCoveredIEFix setting WICKET-5130 Behavior changes org.apache.wicket.request.Url#getQueryString WICKET-4664 org.apache.wicket.request.http.WebResponse encodes the value of the "filename" in Content-Disposition header WICKET-4934 org.apache.wicket.markup.html.form.FormComponentLabel outputs "required", "disabled" and "error" classes when its form component is either required, disabled or invalid. WICKET-5177 org.apache.wicket.markup.html.panel.FeedbackPanel Do not set CSS class on the li span element for a feedback message WICKET-4831 AjaxEventBehavior doesn't prevent the default behavior of the _javascript_ event WICKET-5197 Ajax behaviors let _javascript_ events bubble by default WICKET-5198 PackageTextTemplate loads its content lazily WICKET-4579 AbstractLink no longer alters its markup to render itself as disabled WICKET-4904 Button no longer silently ignores exceptions WICKET-5235 Deprecated classes/methods/fields are removed WICKET-5201 AbstractDefaultAjaxBehavior's #getSuccessHandler(), #getFailureHandler(), #getChannel() and #getPrecondition() are removed. The old Tree component in wicket-extensions is removed. Wicket.Window.unloadConfirmation has been removed WICKET-5246 Dependency updates Environment Wicket 7.0 requires at least Java 7 Wicket 7.0 requires Servlet 3.0 The HTTP response is not flushed automatically when the request is started in asynchronous mode. WICKET-5152 This is an improvement in Wicket 7.0 which should not affect any application migrating from Wicket 6.x. But if you use Servlet 3.0's AsyncContext in IResource in Wicket 7 then make sure that your code flushes the http response after completing the request. API changes org/apache/wicket/core/util/io/SerializableChecker is replaced with org.apache.wicket.core.util.objects.checker.CheckingObjectOutputStream WICKET-4817 CheckingObjectOutputStream accepts a list of
[1/3] git commit: Fix warnings in IDE - no need to use 'final' on static methods
Updated Branches: refs/heads/master 835223065 - bfcd615e8 Fix warnings in IDE - no need to use 'final' on static methods Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/bfcd615e Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/bfcd615e Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/bfcd615e Branch: refs/heads/master Commit: bfcd615e89241fa6a12886d86180cb74fb15a3c9 Parents: 817db86 Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 11:44:58 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:31:51 2013 +0300 -- .../wicket/core/util/lang/PropertyResolver.java | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/bfcd615e/wicket-core/src/main/java/org/apache/wicket/core/util/lang/PropertyResolver.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/core/util/lang/PropertyResolver.java b/wicket-core/src/main/java/org/apache/wicket/core/util/lang/PropertyResolver.java index 4e0aa44..b39d853 100644 --- a/wicket-core/src/main/java/org/apache/wicket/core/util/lang/PropertyResolver.java +++ b/wicket-core/src/main/java/org/apache/wicket/core/util/lang/PropertyResolver.java @@ -91,7 +91,7 @@ public final class PropertyResolver *The object which is evaluated. * @return The value that is evaluated. Null something in the expression evaluated to null. */ - public final static Object getValue(final String expression, final Object object) + public static Object getValue(final String expression, final Object object) { if (expression == null || expression.equals() || object == null) { @@ -124,7 +124,7 @@ public final class PropertyResolver *The converter to convert the value if needed to the right type. * @throws WicketRuntimeException */ - public final static void setValue(final String expression, final Object object, + public static void setValue(final String expression, final Object object, final Object value, final PropertyResolverConverter converter) { if (expression == null || expression.equals()) @@ -155,7 +155,7 @@ public final class PropertyResolver * @return class of the target property object * @throws WicketRuntimeException if the cannot be resolved */ - public final static Class? getPropertyClass(final String expression, final Object object) + public static Class? getPropertyClass(final String expression, final Object object) { ObjectAndGetSetter setter = getObjectAndGetSetter(expression, object, RESOLVE_CLASS); if (setter == null) @@ -191,7 +191,7 @@ public final class PropertyResolver * @return Field for the property expression * @throws WicketRuntimeException if there is no such field */ - public final static Field getPropertyField(final String expression, final Object object) + public static Field getPropertyField(final String expression, final Object object) { ObjectAndGetSetter setter = getObjectAndGetSetter(expression, object, RESOLVE_CLASS); if (setter == null) @@ -208,7 +208,7 @@ public final class PropertyResolver * @return Getter method for the property expression * @throws WicketRuntimeException if there is no getter method */ - public final static Method getPropertyGetter(final String expression, final Object object) + public static Method getPropertyGetter(final String expression, final Object object) { ObjectAndGetSetter setter = getObjectAndGetSetter(expression, object, RESOLVE_CLASS); if (setter == null) @@ -225,7 +225,7 @@ public final class PropertyResolver * @return Setter method for the property expression * @throws WicketRuntimeException if there is no setter method */ - public final static Method getPropertySetter(final String expression, final Object object) + public static Method getPropertySetter(final String expression, final Object object) { ObjectAndGetSetter setter = getObjectAndGetSetter(expression, object, RESOLVE_CLASS); if (setter == null) @@ -377,7 +377,7 @@ public final class PropertyResolver return -1; } - private final static IGetAndSet getGetAndSetter(String exp, final Class? clz) + private static IGetAndSet getGetAndSetter(String exp, final Class? clz) {
[3/3] git commit: Java 7 diamonds
Java 7 diamonds Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/ebf7beef Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/ebf7beef Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/ebf7beef Branch: refs/heads/master Commit: ebf7beeffa3a44c7926c731ee30c17d69a3b599f Parents: 8352230 Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 10:38:39 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:31:51 2013 +0300 -- .../main/java/org/apache/wicket/markup/html/list/ListView.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/ebf7beef/wicket-core/src/main/java/org/apache/wicket/markup/html/list/ListView.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/markup/html/list/ListView.java b/wicket-core/src/main/java/org/apache/wicket/markup/html/list/ListView.java index 7990084..69a16d2 100644 --- a/wicket-core/src/main/java/org/apache/wicket/markup/html/list/ListView.java +++ b/wicket-core/src/main/java/org/apache/wicket/markup/html/list/ListView.java @@ -264,7 +264,7 @@ public abstract class ListViewT extends AbstractRepeater @Override public void onClick() { - final int index = (int)item.getIndex(); + final int index = item.getIndex(); if (index != -1) { addStateChange(); @@ -446,7 +446,7 @@ public abstract class ListViewT extends AbstractRepeater protected IModelT getListItemModel(final IModel? extends ListT listViewModel, final int index) { - return new ListItemModelT(this, index); + return new ListItemModel(this, index); } /** @@ -459,7 +459,7 @@ public abstract class ListViewT extends AbstractRepeater */ protected ListItemT newItem(final int index, IModelT itemModel) { - return new ListItemT(index, itemModel); + return new ListItem(index, itemModel); } /**
[2/2] git commit: Merge branch 'WICKET-5251' of https://github.com/CedricGatay/wicket into WICKET-5251
Merge branch 'WICKET-5251' of https://github.com/CedricGatay/wicket into WICKET-5251 Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/3d2393c7 Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/3d2393c7 Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/3d2393c7 Branch: refs/heads/master Commit: 3d2393c78814c33de39ad046adcc41d8deec96f9 Parents: bfcd615 6ce34cc Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 12:33:15 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:33:15 2013 +0300 -- .../resource/PackageResourceReference.java | 9 - .../resource/PackageResourceReferenceTest.java | 20 2 files changed, 28 insertions(+), 1 deletion(-) --
[1/2] git commit: WICKET-5251
Updated Branches: refs/heads/master bfcd615e8 - 3d2393c78 WICKET-5251 We now correctly detect if the resource already ends with .min to avoid further unnecessary compression. Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/6ce34ccf Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/6ce34ccf Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/6ce34ccf Branch: refs/heads/master Commit: 6ce34ccf84c48055dad46d4ed90372f9684f2296 Parents: 5c6f59e Author: Cedric Gatay ced...@gatay.fr Authored: Tue Jun 25 22:09:19 2013 +0200 Committer: Cedric Gatay ced...@gatay.fr Committed: Tue Jun 25 22:09:19 2013 +0200 -- .../resource/PackageResourceReference.java | 9 - .../resource/PackageResourceReferenceTest.java | 20 2 files changed, 28 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/6ce34ccf/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java index cc72731..710eef2 100644 --- a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java +++ b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java @@ -207,7 +207,14 @@ public class PackageResourceReference extends ResourceReference if (idxOfExtension -1) { String extension = name.substring(idxOfExtension); - minifiedName = name.substring(0, name.length() - extension.length() + 1) + min + extension; +final String baseName = name.substring(0, name.length() - extension.length() + 1); +if (!.min.equals(extension) !baseName.endsWith(.min.)) +{ +minifiedName = baseName + min + extension; +} else +{ +minifiedName = name; +} } else { minifiedName = name + .min; http://git-wip-us.apache.org/repos/asf/wicket/blob/6ce34ccf/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java -- diff --git a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java index cbde900..63cb6ec 100644 --- a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java +++ b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java @@ -22,6 +22,7 @@ import org.apache.wicket.WicketTestCase; import org.apache.wicket.request.resource.IResource.Attributes; import org.apache.wicket.request.resource.ResourceReference.UrlAttributes; import org.apache.wicket.response.ByteArrayResponse; +import org.junit.Assert; import org.junit.Before; import org.junit.Test; @@ -184,4 +185,23 @@ public class PackageResourceReferenceTest extends WicketTestCase } } +/** + * see WICKET-5251 : Proper detection of already minified resources + */ +@Test +public void testMinifiedNameDetectMinInName() throws Exception +{ +final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); +Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); + +final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); +Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); + +final PackageResourceReference html5notmin = new PackageResourceReference(html5notmin); +Assert.assertEquals(html5notmin.min, html5notmin.getMinifiedName()); + +final PackageResourceReference html5min = new PackageResourceReference(html5.min); +Assert.assertEquals(html5.min, html5min.getMinifiedName()); + +} }
git commit: Fix indenting - use tabs
Updated Branches: refs/heads/master 3d2393c78 - dfa2ed576 Fix indenting - use tabs Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/dfa2ed57 Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/dfa2ed57 Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/dfa2ed57 Branch: refs/heads/master Commit: dfa2ed5763fc8b17ab4fb351147bebabd1ebb0de Parents: 3d2393c Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 12:40:18 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:40:18 2013 +0300 -- .../resource/PackageResourceReference.java | 16 - .../resource/PackageResourceReferenceTest.java | 38 ++-- 2 files changed, 27 insertions(+), 27 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/dfa2ed57/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java index 710eef2..ca248a0 100644 --- a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java +++ b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java @@ -207,14 +207,14 @@ public class PackageResourceReference extends ResourceReference if (idxOfExtension -1) { String extension = name.substring(idxOfExtension); -final String baseName = name.substring(0, name.length() - extension.length() + 1); -if (!.min.equals(extension) !baseName.endsWith(.min.)) -{ -minifiedName = baseName + min + extension; -} else -{ -minifiedName = name; -} + final String baseName = name.substring(0, name.length() - extension.length() + 1); + if (!.min.equals(extension) !baseName.endsWith(.min.)) + { + minifiedName = baseName + min + extension; + } else + { + minifiedName = name; + } } else { minifiedName = name + .min; http://git-wip-us.apache.org/repos/asf/wicket/blob/dfa2ed57/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java -- diff --git a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java index 63cb6ec..5fe8474 100644 --- a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java +++ b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java @@ -185,23 +185,23 @@ public class PackageResourceReferenceTest extends WicketTestCase } } -/** - * see WICKET-5251 : Proper detection of already minified resources - */ -@Test -public void testMinifiedNameDetectMinInName() throws Exception -{ -final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); -Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); - -final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); -Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); - -final PackageResourceReference html5notmin = new PackageResourceReference(html5notmin); -Assert.assertEquals(html5notmin.min, html5notmin.getMinifiedName()); - -final PackageResourceReference html5min = new PackageResourceReference(html5.min); -Assert.assertEquals(html5.min, html5min.getMinifiedName()); - -} + /** +* see WICKET-5251 : Proper detection of already minified resources +*/ + @Test + public void testMinifiedNameDetectMinInName() throws Exception + { + final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); + Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); + + final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); + Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); + + final
[1/2] git commit: Merge branch 'WICKET-5251' of https://github.com/CedricGatay/wicket into WICKET-5251
Updated Branches: refs/heads/wicket-6.x 05e08a2d3 - b2427ddb1 Merge branch 'WICKET-5251' of https://github.com/CedricGatay/wicket into WICKET-5251 Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/9eacfef1 Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/9eacfef1 Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/9eacfef1 Branch: refs/heads/wicket-6.x Commit: 9eacfef1f4716edd5a805f6fe2d72320305bd628 Parents: 05e08a2 Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 12:33:15 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:39:21 2013 +0300 -- .../resource/PackageResourceReference.java | 9 - .../resource/PackageResourceReferenceTest.java | 20 2 files changed, 28 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/9eacfef1/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java index cc72731..710eef2 100644 --- a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java +++ b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java @@ -207,7 +207,14 @@ public class PackageResourceReference extends ResourceReference if (idxOfExtension -1) { String extension = name.substring(idxOfExtension); - minifiedName = name.substring(0, name.length() - extension.length() + 1) + min + extension; +final String baseName = name.substring(0, name.length() - extension.length() + 1); +if (!.min.equals(extension) !baseName.endsWith(.min.)) +{ +minifiedName = baseName + min + extension; +} else +{ +minifiedName = name; +} } else { minifiedName = name + .min; http://git-wip-us.apache.org/repos/asf/wicket/blob/9eacfef1/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java -- diff --git a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java index cbde900..63cb6ec 100644 --- a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java +++ b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java @@ -22,6 +22,7 @@ import org.apache.wicket.WicketTestCase; import org.apache.wicket.request.resource.IResource.Attributes; import org.apache.wicket.request.resource.ResourceReference.UrlAttributes; import org.apache.wicket.response.ByteArrayResponse; +import org.junit.Assert; import org.junit.Before; import org.junit.Test; @@ -184,4 +185,23 @@ public class PackageResourceReferenceTest extends WicketTestCase } } +/** + * see WICKET-5251 : Proper detection of already minified resources + */ +@Test +public void testMinifiedNameDetectMinInName() throws Exception +{ +final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); +Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); + +final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); +Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); + +final PackageResourceReference html5notmin = new PackageResourceReference(html5notmin); +Assert.assertEquals(html5notmin.min, html5notmin.getMinifiedName()); + +final PackageResourceReference html5min = new PackageResourceReference(html5.min); +Assert.assertEquals(html5.min, html5min.getMinifiedName()); + +} }
[2/2] git commit: Fix indenting - use tabs
Fix indenting - use tabs Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/b2427ddb Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/b2427ddb Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/b2427ddb Branch: refs/heads/wicket-6.x Commit: b2427ddb1dd7db1b5426a39a1b8ac97ed902c7d4 Parents: 9eacfef Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 12:40:18 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 12:40:48 2013 +0300 -- .../resource/PackageResourceReference.java | 16 - .../resource/PackageResourceReferenceTest.java | 38 ++-- 2 files changed, 27 insertions(+), 27 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/b2427ddb/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java index 710eef2..ca248a0 100644 --- a/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java +++ b/wicket-core/src/main/java/org/apache/wicket/request/resource/PackageResourceReference.java @@ -207,14 +207,14 @@ public class PackageResourceReference extends ResourceReference if (idxOfExtension -1) { String extension = name.substring(idxOfExtension); -final String baseName = name.substring(0, name.length() - extension.length() + 1); -if (!.min.equals(extension) !baseName.endsWith(.min.)) -{ -minifiedName = baseName + min + extension; -} else -{ -minifiedName = name; -} + final String baseName = name.substring(0, name.length() - extension.length() + 1); + if (!.min.equals(extension) !baseName.endsWith(.min.)) + { + minifiedName = baseName + min + extension; + } else + { + minifiedName = name; + } } else { minifiedName = name + .min; http://git-wip-us.apache.org/repos/asf/wicket/blob/b2427ddb/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java -- diff --git a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java index 63cb6ec..5fe8474 100644 --- a/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java +++ b/wicket-core/src/test/java/org/apache/wicket/request/resource/PackageResourceReferenceTest.java @@ -185,23 +185,23 @@ public class PackageResourceReferenceTest extends WicketTestCase } } -/** - * see WICKET-5251 : Proper detection of already minified resources - */ -@Test -public void testMinifiedNameDetectMinInName() throws Exception -{ -final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); -Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); - -final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); -Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); - -final PackageResourceReference html5notmin = new PackageResourceReference(html5notmin); -Assert.assertEquals(html5notmin.min, html5notmin.getMinifiedName()); - -final PackageResourceReference html5min = new PackageResourceReference(html5.min); -Assert.assertEquals(html5.min, html5min.getMinifiedName()); - -} + /** +* see WICKET-5251 : Proper detection of already minified resources +*/ + @Test + public void testMinifiedNameDetectMinInName() throws Exception + { + final PackageResourceReference html5minjs = new PackageResourceReference(html5.min.js); + Assert.assertEquals(html5.min.js, html5minjs.getMinifiedName()); + + final PackageResourceReference html5notminjs = new PackageResourceReference(html5.notmin.js); + Assert.assertEquals(html5.notmin.min.js, html5notminjs.getMinifiedName()); + + final PackageResourceReference html5notmin = new
[jira] [Resolved] (WICKET-5251) Minified name resolves incorrectly if default resource reference is used
[ https://issues.apache.org/jira/browse/WICKET-5251?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Martin Grigorov resolved WICKET-5251. - Resolution: Fixed Fix Version/s: 7.0.0 6.9.0 Assignee: Martin Grigorov Thanks, Cedric! Minified name resolves incorrectly if default resource reference is used Key: WICKET-5251 URL: https://issues.apache.org/jira/browse/WICKET-5251 Project: Wicket Issue Type: Bug Components: wicket Affects Versions: 6.8.0 Reporter: Johannes Odland Assignee: Martin Grigorov Fix For: 6.9.0, 7.0.0 In PackageResourceReference. When a default reference to a minified resource is used (i.e. the resource wasn't mounted) the resource reference name includes '.min'. When trying to resolve the minified name, another '.min' is appended, resulting in the minified name resolving to 'html5.min.min.js'. As a result, the PackageResourceReference concludes that the resource was not minified, and adds compression. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (WICKET-5251) Minified name resolves incorrectly if default resource reference is used
[ https://issues.apache.org/jira/browse/WICKET-5251?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Martin Grigorov updated WICKET-5251: Fix Version/s: (was: 6.9.0) 6.10.0 Minified name resolves incorrectly if default resource reference is used Key: WICKET-5251 URL: https://issues.apache.org/jira/browse/WICKET-5251 Project: Wicket Issue Type: Bug Components: wicket Affects Versions: 6.8.0 Reporter: Johannes Odland Assignee: Martin Grigorov Fix For: 7.0.0, 6.10.0 In PackageResourceReference. When a default reference to a minified resource is used (i.e. the resource wasn't mounted) the resource reference name includes '.min'. When trying to resolve the minified name, another '.min' is appended, resulting in the minified name resolving to 'html5.min.min.js'. As a result, the PackageResourceReference concludes that the resource was not minified, and adds compression. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-5250) Minified css/js gets compressed
[ https://issues.apache.org/jira/browse/WICKET-5250?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13693877#comment-13693877 ] Johannes Odland commented on WICKET-5250: - In PackageResourceReference#getResource() there is a check that sets compress to false on the resource if a minified name exists (Line 132-136). This method is overwritten by JavaScriptResourceReference (and CssResourceReference). Neither of them checks if the resource is minified. Minified css/js gets compressed --- Key: WICKET-5250 URL: https://issues.apache.org/jira/browse/WICKET-5250 Project: Wicket Issue Type: Bug Components: wicket Affects Versions: 6.8.0 Reporter: Johannes Odland Given an application with a resource reference to a minified script, i.e. html5.js and html5.min.js. When the ResourceRequestHandler responds it will set compress to false, if the resource reference was PackageResourceReference but it will not change compression if the resource reference was JavaScriptResourceReference. PackageResourceReference handles minified resources more or less correctly (if they are minified, they should not be further compressed), but this behavior is overwritten in its subclasses. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
git commit: Fix Javadoc
Updated Branches: refs/heads/master dfa2ed576 - e75eeaa25 Fix Javadoc Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/e75eeaa2 Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/e75eeaa2 Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/e75eeaa2 Branch: refs/heads/master Commit: e75eeaa2511ee0bc0bec7c74cb57d50809dba8ef Parents: dfa2ed5 Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 17:46:31 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 17:46:31 2013 +0300 -- .../apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/e75eeaa2/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java b/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java index 34a59a9..cf1f33b 100644 --- a/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java +++ b/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java @@ -27,14 +27,14 @@ import org.apache.wicket.markup.html.form.TextField; * behavior that wraps the component in a paragraph tag: * * pre - * class PB extends AbstractBehavior + * class PB extends Behavior * { - * public void onBeforeRender(Component c) + * public void beforeRender(Component c) * { * c.getResponse().write(quot;lt;pgt;quot;); * } * - * public void onComponentRendered(Component c) + * public void afterRender(Component c) * { * c.getResponse().write(quot;lt;/pgt;quot;); * } @@ -60,14 +60,14 @@ import org.apache.wicket.markup.html.form.TextField; * To fix this we can modify our behavior as follows: * * pre - * class PB extends AbstractBehavior implements IAjaxRegionMarkupIdProvider + * class PB extends Behavior implements IAjaxRegionMarkupIdProvider * { - * public void onBeforeRender(Component c) + * public void beforeRender(Component c) * { * c.getResponse().write(quot;lt;p id='quot; + c.getMarkupId() + quot;_p'gt;quot;); * } * - * public void onComponentRendered(Component c) + * public void afterRender(Component c) * { * c.getResponse().write(quot;lt;/pgt;quot;); * }
git commit: Fix Javadoc
Updated Branches: refs/heads/wicket-6.x b2427ddb1 - 8a4a367f6 Fix Javadoc Project: http://git-wip-us.apache.org/repos/asf/wicket/repo Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/8a4a367f Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/8a4a367f Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/8a4a367f Branch: refs/heads/wicket-6.x Commit: 8a4a367f670830d0dbe634990bac9eee698112e3 Parents: b2427dd Author: Martin Tzvetanov Grigorov mgrigo...@apache.org Authored: Wed Jun 26 17:46:31 2013 +0300 Committer: Martin Tzvetanov Grigorov mgrigo...@apache.org Committed: Wed Jun 26 17:46:57 2013 +0300 -- .../apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/wicket/blob/8a4a367f/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java -- diff --git a/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java b/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java index 34a59a9..cf1f33b 100644 --- a/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java +++ b/wicket-core/src/main/java/org/apache/wicket/ajax/IAjaxRegionMarkupIdProvider.java @@ -27,14 +27,14 @@ import org.apache.wicket.markup.html.form.TextField; * behavior that wraps the component in a paragraph tag: * * pre - * class PB extends AbstractBehavior + * class PB extends Behavior * { - * public void onBeforeRender(Component c) + * public void beforeRender(Component c) * { * c.getResponse().write(quot;lt;pgt;quot;); * } * - * public void onComponentRendered(Component c) + * public void afterRender(Component c) * { * c.getResponse().write(quot;lt;/pgt;quot;); * } @@ -60,14 +60,14 @@ import org.apache.wicket.markup.html.form.TextField; * To fix this we can modify our behavior as follows: * * pre - * class PB extends AbstractBehavior implements IAjaxRegionMarkupIdProvider + * class PB extends Behavior implements IAjaxRegionMarkupIdProvider * { - * public void onBeforeRender(Component c) + * public void beforeRender(Component c) * { * c.getResponse().write(quot;lt;p id='quot; + c.getMarkupId() + quot;_p'gt;quot;); * } * - * public void onComponentRendered(Component c) + * public void afterRender(Component c) * { * c.getResponse().write(quot;lt;/pgt;quot;); * }
[jira] [Closed] (WICKET-5252) PropertyResolver breaks immutable objects by calling setAccessible
[ https://issues.apache.org/jira/browse/WICKET-5252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Daniel Zwicker closed WICKET-5252. -- PropertyResolver breaks immutable objects by calling setAccessible -- Key: WICKET-5252 URL: https://issues.apache.org/jira/browse/WICKET-5252 Project: Wicket Issue Type: Bug Affects Versions: 6.8.0 Reporter: Daniel Zwicker If a Bean only have private fields and no setter this object is immutable. The decision to implement such an object has a bunch of implications. e.g. it is thread safe, you can take snapshots of these object to store a version history and so on. Now your use of reflection breaks this isolation silently. I believe if somebody want set the values of the object he should implement a setter or provide a public field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira