From i30817 at gmail.com Mon Jul 2 07:05:08 2007 From: i30817 at gmail.com (Paulo Levi) Date: Mon, 2 Jul 2007 08:05:08 +0100 Subject: HTML parser tr, td and th tags. Message-ID: <212322090707020005k5e02aaa3p3dd692505b2dc57b@mail.gmail.com> It seems that the boolean breaksflow() method for the tr, td and th (at least, didn't test others) tags gives wrong results. t.TR.breaksFlow() == false t.TD.breaksFlow() == true t.TH.breaksFlow() == true Considering that the breaksflow method says: /** * Returns true if this tag causes a * line break to the flow of data, otherwise returns * false. * * @return true if this tag causes a * line break to the flow of data, otherwise returns * false */ Unless we consider justification as a line break, i think its wrong. Anyway i didn't sign the contributor agreement but this seems like an easy fix: would somebody check it out? -------------- next part -------------- An HTML attachment was scrubbed... URL: From Phil.Race at Sun.COM Mon Jul 2 14:14:18 2007 From: Phil.Race at Sun.COM (Phil Race) Date: Mon, 02 Jul 2007 07:14:18 -0700 Subject: HTML parser tr, td and th tags. In-Reply-To: <212322090707020005k5e02aaa3p3dd692505b2dc57b@mail.gmail.com> References: <212322090707020005k5e02aaa3p3dd692505b2dc57b@mail.gmail.com> Message-ID: <4689083A.8020809@sun.com> Paulo, As I told you on the awt-dev list, if you have a bug to report, please report it at bugs.sun.com, not on these lists. -phil. Paulo Levi wrote: > It seems that the boolean breaksflow() method for the tr, td and th > (at least, didn't test others) tags gives wrong results. > t.TR.breaksFlow() == false > t.TD.breaksFlow() == true > t.TH.breaksFlow() == true > Considering that the breaksflow method says: > /** > * Returns true if this tag causes a > * line break to the flow of data, otherwise returns > * false. > * > * @return true if this tag causes a > * line break to the flow of data, otherwise returns > * false > */ > Unless we consider justification as a line break, i think its wrong. > Anyway i didn't sign the contributor agreement but this seems like an > easy fix: would somebody check it out? From david.gilbert at object-refinery.com Tue Jul 10 12:59:40 2007 From: david.gilbert at object-refinery.com (David Gilbert) Date: Tue, 10 Jul 2007 13:59:40 +0100 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: References: <46486965.1030900@object-refinery.com> Message-ID: <469382BC.9030701@object-refinery.com> Hi Richard, Any update on this? Dave. Richard Bair wrote: > Hey Dave, thanks for the patch. > > For those following along, I've been talking with Dave about it > offline, sorry for not posting back to the openjdk list. I'm repenting > :-). Also, due to post-JavaOne vacations, this is taking a wee bit > longer than usual. > > I've looked at the patch, it looks good. I *really* appreciate the > supplied test as well. The only thing I need to verify is that > oldModel is never null (or this new line would produce an NPE). From a > cursory look at JSpinner, it appears to never be null, but I need to > take another look. > > Also, I'm working with Igor on a code review and putback. > > Thanks Dave! > > Richard > > On May 14, 2007, at 6:51 AM, David Gilbert wrote: > >> Hi, >> >> The attached patch is a proposed fix for bug 6463712. It is a >> one-line fix to the setModel(SpinnerModel) method - the listener that >> works on behalf of the JSpinner to forward events from the model >> needs to be deregistered from the old model when a new model is >> assigned. >> >> The patch includes a regression test that can be run using jtreg. I >> also tested using the JSpinner-related tests in Mauve[1]. >> >> I'm working against the initial OpenJDK source release (b12). >> Any questions, just ask... >> >> Regards, >> >> Dave Gilbert >> http://www.jfree.org/ >> >> [1] http://sourceware.org/mauve/ >> >> diff -ruN j2se/src/share/classes/javax/swing/JSpinner.java >> ../mods/openjdk/j2se/src/share/classes/javax/swing/JSpinner.java >> --- j2se/src/share/classes/javax/swing/JSpinner.java 2007-05-06 >> 10:11:15.000000000 +0100 >> +++ >> ../mods/openjdk/j2se/src/share/classes/javax/swing/JSpinner.java >> 2007-05-08 22:19:11.000000000 +0100 >> @@ -286,6 +286,7 @@ >> SpinnerModel oldModel = this.model; >> this.model = model; >> if (modelListener != null) { >> + oldModel.removeChangeListener(modelListener); >> this.model.addChangeListener(modelListener); >> } >> firePropertyChange("model", oldModel, model); >> diff -ruN j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >> ../mods/openjdk/j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >> --- j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >> 1970-01-01 01:00:00.000000000 +0100 >> +++ >> ../mods/openjdk/j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >> 2007-05-14 12:19:22.000000000 +0100 >> @@ -0,0 +1,55 @@ >> +/* >> + * Copyright 2007, Object Refinery Limited. All Rights Reserved. >> + * >> + * This program is free software; you can redistribute it and/or modify >> + * it under the terms of the GNU General Public License as published by >> + * the Free Software Foundation; either version 2 of the License, or >> + * (at your option) any later version. >> + * >> + * This program is distributed in the hope that it will be useful, >> + * but WITHOUT ANY WARRANTY; without even the implied warranty of >> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the >> + * GNU General Public License for more details. >> + * >> + * You should have received a copy of the GNU General Public License >> + * along with this program; if not, write to the Free Software >> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA >> + * 02110-1301, USA >> + */ >> + >> +import javax.swing.JSpinner; >> +import javax.swing.SpinnerDateModel; >> +import javax.swing.SpinnerNumberModel; >> +import javax.swing.event.ChangeEvent; >> +import javax.swing.event.ChangeListener; >> + >> +/* >> + * @test >> + * @bug 6463712 >> + * @summary Events forwarded from previous model >> + */ >> +public class JSpinnerBug6463712 implements ChangeListener { >> + >> + public JSpinnerBug6463712() >> + { >> + SpinnerNumberModel m1 = new SpinnerNumberModel(); >> + JSpinner s = new JSpinner(m1); >> + s.addChangeListener(this); >> + SpinnerDateModel m2 = new SpinnerDateModel(); >> + s.setModel(m2); >> + >> + // m1 is no longer linked to the JSpinner (it has been replaced >> by m2), so >> + // the following should not trigger a call to our stateChanged() >> method... >> + m1.setValue(new Integer(1)); >> + } >> + >> + public void stateChanged(ChangeEvent e) >> + { >> + throw new RuntimeException("Should not receive this event."); >> + } >> + >> + public static void main(String[] args) >> + { >> + JSpinnerBug6463712 bug = new JSpinnerBug6463712(); >> + } >> +} > > > From Richard.Bair at Sun.COM Wed Jul 11 17:01:50 2007 From: Richard.Bair at Sun.COM (Richard Bair) Date: Wed, 11 Jul 2007 10:01:50 -0700 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <469382BC.9030701@object-refinery.com> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> Message-ID: <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> Hey Dave, Thanks for the ping. It is in the review queue. I think the recent mad work on the Nimbus LAF and JSR 295 is slowing things down. I know Nimbus is sure taking it's toll on my schedule :-) So just to let you know what is going on, when the bugfix has been applied to a local workspace, we generate a "webrev" which shows the revisions between the old and new files (a kind of diff, but with a lot more ways to view the changes). This then gets sent to two or more reviewers, even for trivial bugs like this one. Sometimes these reviews can sit in a queue for a bit, if the reviewers are hurting for time. After both reviewers give it the ok, I can put the bug back. It will then take several weeks before the swing workspace is integrated back into the main workspace, goes through testing, and pops out in a build. Thanks Richard On Jul 10, 2007, at 5:59 AM, David Gilbert wrote: > Hi Richard, > > Any update on this? > > Dave. > > Richard Bair wrote: >> Hey Dave, thanks for the patch. >> >> For those following along, I've been talking with Dave about it >> offline, sorry for not posting back to the openjdk list. I'm >> repenting :-). Also, due to post-JavaOne vacations, this is taking >> a wee bit longer than usual. >> >> I've looked at the patch, it looks good. I *really* appreciate the >> supplied test as well. The only thing I need to verify is that >> oldModel is never null (or this new line would produce an NPE). >> From a cursory look at JSpinner, it appears to never be null, but >> I need to take another look. >> >> Also, I'm working with Igor on a code review and putback. >> >> Thanks Dave! >> >> Richard >> >> On May 14, 2007, at 6:51 AM, David Gilbert wrote: >> >>> Hi, >>> >>> The attached patch is a proposed fix for bug 6463712. It is a >>> one-line fix to the setModel(SpinnerModel) method - the listener >>> that works on behalf of the JSpinner to forward events from the >>> model needs to be deregistered from the old model when a new >>> model is assigned. >>> >>> The patch includes a regression test that can be run using >>> jtreg. I also tested using the JSpinner-related tests in Mauve[1]. >>> >>> I'm working against the initial OpenJDK source release (b12). >>> Any questions, just ask... >>> >>> Regards, >>> >>> Dave Gilbert >>> http://www.jfree.org/ >>> >>> [1] http://sourceware.org/mauve/ >>> >>> diff -ruN j2se/src/share/classes/javax/swing/JSpinner.java ../ >>> mods/openjdk/j2se/src/share/classes/javax/swing/JSpinner.java >>> --- j2se/src/share/classes/javax/swing/JSpinner.java >>> 2007-05-06 10:11:15.000000000 +0100 >>> +++ ../mods/openjdk/j2se/src/share/classes/javax/swing/ >>> JSpinner.java 2007-05-08 22:19:11.000000000 +0100 >>> @@ -286,6 +286,7 @@ >>> SpinnerModel oldModel = this.model; >>> this.model = model; >>> if (modelListener != null) { >>> + oldModel.removeChangeListener(modelListener); >>> this.model.addChangeListener(modelListener); >>> } >>> firePropertyChange("model", oldModel, model); >>> diff -ruN j2se/test/javax/swing/JSpinner/ >>> JSpinnerBug6463712.java ../mods/openjdk/j2se/test/javax/swing/ >>> JSpinner/JSpinnerBug6463712.java >>> --- j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >>> 1970-01-01 01:00:00.000000000 +0100 >>> +++ ../mods/openjdk/j2se/test/javax/swing/JSpinner/ >>> JSpinnerBug6463712.java 2007-05-14 12:19:22.000000000 +0100 >>> @@ -0,0 +1,55 @@ >>> +/* >>> + * Copyright 2007, Object Refinery Limited. All Rights Reserved. >>> + * >>> + * This program is free software; you can redistribute it and/or >>> modify >>> + * it under the terms of the GNU General Public License as >>> published by >>> + * the Free Software Foundation; either version 2 of the >>> License, or >>> + * (at your option) any later version. >>> + * >>> + * This program is distributed in the hope that it will be useful, >>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of >>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the >>> + * GNU General Public License for more details. >>> + * >>> + * You should have received a copy of the GNU General Public >>> License >>> + * along with this program; if not, write to the Free Software >>> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA >>> + * 02110-1301, USA >>> + */ >>> + >>> +import javax.swing.JSpinner; >>> +import javax.swing.SpinnerDateModel; >>> +import javax.swing.SpinnerNumberModel; >>> +import javax.swing.event.ChangeEvent; >>> +import javax.swing.event.ChangeListener; >>> + >>> +/* >>> + * @test >>> + * @bug 6463712 >>> + * @summary Events forwarded from previous model >>> + */ >>> +public class JSpinnerBug6463712 implements ChangeListener { >>> + >>> + public JSpinnerBug6463712() >>> + { >>> + SpinnerNumberModel m1 = new SpinnerNumberModel(); >>> + JSpinner s = new JSpinner(m1); >>> + s.addChangeListener(this); >>> + SpinnerDateModel m2 = new SpinnerDateModel(); >>> + s.setModel(m2); >>> + >>> + // m1 is no longer linked to the JSpinner (it has been >>> replaced by m2), so >>> + // the following should not trigger a call to our >>> stateChanged() method... >>> + m1.setValue(new Integer(1)); >>> + } >>> + >>> + public void stateChanged(ChangeEvent e) >>> + { >>> + throw new RuntimeException("Should not receive this event."); >>> + } >>> + >>> + public static void main(String[] args) >>> + { >>> + JSpinnerBug6463712 bug = new JSpinnerBug6463712(); >>> + } >>> +} >> >> >> > From roman at kennke.org Thu Jul 12 19:46:33 2007 From: roman at kennke.org (Roman Kennke) Date: Thu, 12 Jul 2007 21:46:33 +0200 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> Message-ID: <1184269593.30033.8.camel@mercury> Hi, > So just to let you know what is going on, when the bugfix has been > applied to a local workspace, we generate a "webrev" which shows the > revisions between the old and new files (a kind of diff, but with a > lot more ways to view the changes). This then gets sent to two or > more reviewers, even for trivial bugs like this one. Sometimes these > reviews can sit in a queue for a bit, if the reviewers are hurting > for time. > > After both reviewers give it the ok, I can put the bug back. It will > then take several weeks before the swing workspace is integrated back > into the main workspace, goes through testing, and pops out in a build. Eh. You really want to scare off voluntary contributors, would you? I mean, requiring this procedure from paid developers is one thing, but voluntary developers often do develop for fun (or some other kind of - let's call it 'social reward' -). And a procedure like this really useful for bringing motivation down to zero. I mean, this patch is perfect, it's obvious, it even comes with a testcase. And I really really doubt that such a procedure adds much to the overall quality of the code. Or how would you explain, for example, the crazy code in UIManager.initialize() ;-) (I've seen a couple of places in OpenJDK, where a non-visible method of another package is called via reflection. This is not only evil, it's dangerous too. What if such a method is renamed or removed? And after all, it's not even necessary to write such code in the first place. A little refactoring of things should help too). Just my 2 cents. /Roman -- http://kennke.org/blog/ From Oleg.Sukhodolsky at Sun.COM Thu Jul 12 20:03:17 2007 From: Oleg.Sukhodolsky at Sun.COM (Oleg Sukhodolsky) Date: Fri, 13 Jul 2007 00:03:17 +0400 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <1184269593.30033.8.camel@mercury> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> <1184269593.30033.8.camel@mercury> Message-ID: <46968905.4010508@sun.com> Hi Roman, Roman Kennke wrote: > Hi, > >> So just to let you know what is going on, when the bugfix has been >> applied to a local workspace, we generate a "webrev" which shows the >> revisions between the old and new files (a kind of diff, but with a >> lot more ways to view the changes). This then gets sent to two or >> more reviewers, even for trivial bugs like this one. Sometimes these >> reviews can sit in a queue for a bit, if the reviewers are hurting >> for time. >> >> After both reviewers give it the ok, I can put the bug back. It will >> then take several weeks before the swing workspace is integrated back >> into the main workspace, goes through testing, and pops out in a build. > > Eh. You really want to scare off voluntary contributors, would you? I > mean, requiring this procedure from paid developers is one thing, but > voluntary developers often do develop for fun (or some other kind of - > let's call it 'social reward' -). And a procedure like this really > useful for bringing motivation down to zero. I mean, this patch is > perfect, it's obvious, it even comes with a testcase. And I really > really doubt that such a procedure adds much to the overall quality of I agree with you, but this is a bureaucracy we have to live with :( It will be great if we could process contributions faster, but we can not :( at least for now) > the code. Or how would you explain, for example, the crazy code in > UIManager.initialize() ;-) (I've seen a couple of places in OpenJDK, > where a non-visible method of another package is called via reflection. > This is not only evil, it's dangerous too. What if such a method is > renamed or removed? And after all, it's not even necessary to write such > code in the first place. A little refactoring of things should help > too). I do not know what places you are referring to, but in most cases I know this is because we can not (or do not want to) provide public method, because this would be an (unnecessary) API change. As contrast, Swing number of public methods which are only public because they should be accessible from laf, but at the same time regular developer should not use them. And this is also bad :( > Just my 2 cents. +2c from me :) Oleg. > > /Roman > From david.gilbert at object-refinery.com Fri Jul 13 16:07:51 2007 From: david.gilbert at object-refinery.com (David Gilbert) Date: Fri, 13 Jul 2007 17:07:51 +0100 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> <319BD059-1256-4D34-9B13-92091590AE55@Sun.COM> Message-ID: <4697A357.3020407@object-refinery.com> Hi Richard, Richard Bair wrote: > > After both reviewers give it the ok, I can put the bug back. It will > then take several weeks before the swing workspace is integrated back > into the main workspace, goes through testing, and pops out in a build. > Thanks for the info. This is a simple patch, so I can easily forget about it until it "pops out in a build", but if the patch was larger / more complex, by now I'd have forgotten all the details. I think an improvement to the process would be to set up a "contributors" build, and have that run daily against a regression test suite (or a number of test suites), with results posted automatically to the OpenJDK web site. Then I could submit my patch, get it committed "as soon as", wait for the test suite to update and check for regressions. The key point is that if there are regressions, I'd like to know about them as quick as possible, so I can rework the patch (while the bug or whatever is still fresh in my mind). Once I've got a patch that doesn't break anything obvious, I'm happy to wait through the long QA process to get it into a real build (or deal with anything that the QA picks up that the automated regression tests didn't). I'm sure this is an obvious suggestion, and I'm sure it's being worked on...but for now the long feedback loop is deterring me from spending too much time on OpenJDK (which isn't so bad, since I may have a little more time to look at stuff like JSRs 295/296). Regards, Dave From Richard.Bair at Sun.COM Mon Jul 23 17:44:34 2007 From: Richard.Bair at Sun.COM (Richard Bair) Date: Mon, 23 Jul 2007 10:44:34 -0700 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <469382BC.9030701@object-refinery.com> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> Message-ID: <4146E2A0-7A13-4BB5-B699-1D5D6081019F@Sun.COM> Hey Dave, The fix has (finally) been putback. I'm not sure of the schedule, but I'd expect it to make it into a build soonish (next couple of weeks). Thanks Richard On Jul 10, 2007, at 5:59 AM, David Gilbert wrote: > Hi Richard, > > Any update on this? > > Dave. > > Richard Bair wrote: >> Hey Dave, thanks for the patch. >> >> For those following along, I've been talking with Dave about it >> offline, sorry for not posting back to the openjdk list. I'm >> repenting :-). Also, due to post-JavaOne vacations, this is taking >> a wee bit longer than usual. >> >> I've looked at the patch, it looks good. I *really* appreciate the >> supplied test as well. The only thing I need to verify is that >> oldModel is never null (or this new line would produce an NPE). >> From a cursory look at JSpinner, it appears to never be null, but >> I need to take another look. >> >> Also, I'm working with Igor on a code review and putback. >> >> Thanks Dave! >> >> Richard >> >> On May 14, 2007, at 6:51 AM, David Gilbert wrote: >> >>> Hi, >>> >>> The attached patch is a proposed fix for bug 6463712. It is a >>> one-line fix to the setModel(SpinnerModel) method - the listener >>> that works on behalf of the JSpinner to forward events from the >>> model needs to be deregistered from the old model when a new >>> model is assigned. >>> >>> The patch includes a regression test that can be run using >>> jtreg. I also tested using the JSpinner-related tests in Mauve[1]. >>> >>> I'm working against the initial OpenJDK source release (b12). >>> Any questions, just ask... >>> >>> Regards, >>> >>> Dave Gilbert >>> http://www.jfree.org/ >>> >>> [1] http://sourceware.org/mauve/ >>> >>> diff -ruN j2se/src/share/classes/javax/swing/JSpinner.java ../ >>> mods/openjdk/j2se/src/share/classes/javax/swing/JSpinner.java >>> --- j2se/src/share/classes/javax/swing/JSpinner.java >>> 2007-05-06 10:11:15.000000000 +0100 >>> +++ ../mods/openjdk/j2se/src/share/classes/javax/swing/ >>> JSpinner.java 2007-05-08 22:19:11.000000000 +0100 >>> @@ -286,6 +286,7 @@ >>> SpinnerModel oldModel = this.model; >>> this.model = model; >>> if (modelListener != null) { >>> + oldModel.removeChangeListener(modelListener); >>> this.model.addChangeListener(modelListener); >>> } >>> firePropertyChange("model", oldModel, model); >>> diff -ruN j2se/test/javax/swing/JSpinner/ >>> JSpinnerBug6463712.java ../mods/openjdk/j2se/test/javax/swing/ >>> JSpinner/JSpinnerBug6463712.java >>> --- j2se/test/javax/swing/JSpinner/JSpinnerBug6463712.java >>> 1970-01-01 01:00:00.000000000 +0100 >>> +++ ../mods/openjdk/j2se/test/javax/swing/JSpinner/ >>> JSpinnerBug6463712.java 2007-05-14 12:19:22.000000000 +0100 >>> @@ -0,0 +1,55 @@ >>> +/* >>> + * Copyright 2007, Object Refinery Limited. All Rights Reserved. >>> + * >>> + * This program is free software; you can redistribute it and/or >>> modify >>> + * it under the terms of the GNU General Public License as >>> published by >>> + * the Free Software Foundation; either version 2 of the >>> License, or >>> + * (at your option) any later version. >>> + * >>> + * This program is distributed in the hope that it will be useful, >>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of >>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the >>> + * GNU General Public License for more details. >>> + * >>> + * You should have received a copy of the GNU General Public >>> License >>> + * along with this program; if not, write to the Free Software >>> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA >>> + * 02110-1301, USA >>> + */ >>> + >>> +import javax.swing.JSpinner; >>> +import javax.swing.SpinnerDateModel; >>> +import javax.swing.SpinnerNumberModel; >>> +import javax.swing.event.ChangeEvent; >>> +import javax.swing.event.ChangeListener; >>> + >>> +/* >>> + * @test >>> + * @bug 6463712 >>> + * @summary Events forwarded from previous model >>> + */ >>> +public class JSpinnerBug6463712 implements ChangeListener { >>> + >>> + public JSpinnerBug6463712() >>> + { >>> + SpinnerNumberModel m1 = new SpinnerNumberModel(); >>> + JSpinner s = new JSpinner(m1); >>> + s.addChangeListener(this); >>> + SpinnerDateModel m2 = new SpinnerDateModel(); >>> + s.setModel(m2); >>> + >>> + // m1 is no longer linked to the JSpinner (it has been >>> replaced by m2), so >>> + // the following should not trigger a call to our >>> stateChanged() method... >>> + m1.setValue(new Integer(1)); >>> + } >>> + >>> + public void stateChanged(ChangeEvent e) >>> + { >>> + throw new RuntimeException("Should not receive this event."); >>> + } >>> + >>> + public static void main(String[] args) >>> + { >>> + JSpinnerBug6463712 bug = new JSpinnerBug6463712(); >>> + } >>> +} >> >> >> > From david.gilbert at object-refinery.com Tue Jul 24 11:32:21 2007 From: david.gilbert at object-refinery.com (David Gilbert) Date: Tue, 24 Jul 2007 12:32:21 +0100 Subject: [PATCH] 6463712: JSpinner forwards events from old model In-Reply-To: <4146E2A0-7A13-4BB5-B699-1D5D6081019F@Sun.COM> References: <46486965.1030900@object-refinery.com> <469382BC.9030701@object-refinery.com> <4146E2A0-7A13-4BB5-B699-1D5D6081019F@Sun.COM> Message-ID: <46A5E345.3080301@object-refinery.com> Richard Bair wrote: > Hey Dave, > > The fix has (finally) been putback. I'm not sure of the schedule, but > I'd expect it to make it into a build soonish (next couple of weeks). > > Thanks > Richard Thanks! I'll watch out for it... Regards, Dave From Mikhail.Lapshin at Sun.COM Mon Jul 30 16:48:58 2007 From: Mikhail.Lapshin at Sun.COM (Mikhail Lapshin) Date: Mon, 30 Jul 2007 20:48:58 +0400 Subject: A problem with initial location of JSplitPane divider Message-ID: <46AE167A.2040601@sun.com> Hello everybody, There is RFE 6528446: JSplitPane lacks of a method to set up the initial divider location . It is intended to solve the following problem: JSplitPane lacks for a method to set up the initial divider location in terms of percents or proportions. There is the setDividerLocation(double) method, but it doesn't work unless the split pane is shown on the screen. I wrote two fix versions, implementing two different ideas. However the both ideas turned out not so good. 1. The first fix idea. http://sa.sfbay.sun.com/projects/swing_data/7/6528446.0/ To modify the setDividerLocation(double) method in such a way, that it can work even for a split pane in non-realized state. The method will store the desirable proportionalLocation in a private field and then apply it when the split pane becomes realized. It turned out not so good because JSplitPane gets a new internal state, which cannot be read with the existing API. For example, there is no any possibility to read the stored divider location if the location was set before the showing of the split pane. 2. The second fix idea: http://sa.sfbay.sun.com/projects/swing_data/7/6528446.1/ To add a new API, which will allow to set the initial divider location. It turned out not so good because it requires addition of three new API methods to solve such small problem. If you have a better idea how to implement the setting of the initial divider location, I will be very grateful. Thanks! --Mikhail -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirillcool at yahoo.com Mon Jul 30 16:56:22 2007 From: kirillcool at yahoo.com (Kirill Grouchnikov) Date: Mon, 30 Jul 2007 09:56:22 -0700 (PDT) Subject: A problem with initial location of JSplitPane divider Message-ID: <670423.4685.qm@web52706.mail.re2.yahoo.com> It would help if the fixes were available from a public server... ----- Original Message ---- From: Mikhail Lapshin To: swing-dev at openjdk.java.net Sent: Monday, July 30, 2007 9:48:58 AM Subject: A problem with initial location of JSplitPane divider Hello everybody, There is RFE 6528446: JSplitPane lacks of a method to set up the initial divider location. It is intended to solve the following problem: JSplitPane lacks for a method to set up the initial divider location in terms of percents or proportions. There is the setDividerLocation(double) method, but it doesn't work unless the split pane is shown on the screen. I wrote two fix versions, implementing two different ideas. However the both ideas turned out not so good. 1. The first fix idea. http://sa.sfbay.sun.com/projects/swing_data/7/6528446.0/ To modify the setDividerLocation(double) method in such a way, that it can work even for a split pane in non-realized state. The method will store the desirable proportionalLocation in a private field and then apply it when the split pane becomes realized. It turned out not so good because JSplitPane gets a new internal state, which cannot be read with the existing API. For example, there is no any possibility to read the stored divider location if the location was set before the showing of the split pane. 2. The second fix idea: http://sa.sfbay.sun.com/projects/swing_data/7/6528446.1/ To add a new API, which will allow to set the initial divider location. It turned out not so good because it requires addition of three new API methods to solve such small problem. If you have a better idea how to implement the setting of the initial divider location, I will be very grateful. Thanks! --Mikhail ____________________________________________________________________________________ Fussy? Opinionated? Impossible to please? Perfect. Join Yahoo!'s user panel and lay it on us. http://surveylink.yahoo.com/gmrs/yahoo_panel_invite.asp?a=7 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Mikhail.Lapshin at Sun.COM Mon Jul 30 17:29:46 2007 From: Mikhail.Lapshin at Sun.COM (Mikhail Lapshin) Date: Mon, 30 Jul 2007 21:29:46 +0400 Subject: A problem with initial location of JSplitPane divider Message-ID: <46AE200A.5090404@sun.com> Kirill, thank you for the feedback. Sorry for the internal links. I have attached the fixes as zip archives with html-based diffs and source files. --------------- There is RFE 6528446: JSplitPane lacks of a method to set up the initial divider location . It is intended to solve the following problem: JSplitPane lacks for a method to set up the initial divider location in terms of percents or proportions. There is the setDividerLocation(double) method, but it doesn't work unless the split pane is shown on the screen. I wrote two fix versions, implementing two different ideas. However the both ideas turned out not so good. 1. The first fix idea. (webrev6528446_v0.zip) To modify the setDividerLocation(double) method in such a way, that it can work even for a split pane in non-realized state. The method will store the desirable proportionalLocation in a private field and then apply it when the split pane becomes realized. It turned out not so good because JSplitPane gets a new internal state, which cannot be read with the existing API. For example, there is no any possibility to read the stored divider location if the location was set before the showing of the split pane. 2. The second fix idea. (webrev6528446_v1.zip) To add a new API, which will allow to set the initial divider location. It turned out not so good because it requires addition of three new API methods to solve such small problem. If you have a better idea how to implement the setting of the initial divider location, I will be very grateful. Thanks! --Mikhail -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: webrev6528446_v0.zip Type: application/octet-stream Size: 80329 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: webrev6528446_v1.zip Type: application/octet-stream Size: 193991 bytes Desc: not available URL: