<Swing Dev> [PATCH] 6179357-related: warnings removal: gtk

Pavel Porvatov Pavel.Porvatov at Sun.COM
Thu Nov 13 11:55:47 UTC 2008


Hi Florian,

I approved your fix and now you can commit it. Don't forget write 
appropriate changeset comment (see 
http://openjdk.java.net/guide/producingChangeset.html#changesetComment).

I filed a bug for your change:
<bugid>: 6771030
<synopsis-of-symptom>: Code improvement and warnings removing from the 
com.sun.java.swing.plaf.gtk package

Let me know if you have any question.

Thanks, Pavel.

> Hi Pavel,
> 
> I fixed the 2 issues.
> 
> -Florian
> 
> Am Mittwoch, 12. November 2008 schrieb Pavel Porvatov:
>> Hi Florian,
>>
>> Your fix looks very good. I have a couple comments:
>>
>> 1.
>> com.sun.java.swing.plaf.gtk.GTKColorChooserPanel.ColorTriangle#colorWheelLo
>> cationToRGB - can you fix javadoc please (this is a private method). The
>> last
>> "param" tag should be replaced by "return" tag
>>
>> 2.
>> @@ -895,10 +895,10 @@ class GTKFileChooserUI extends SynthFile
>>
>>       private class GTKDirectoryModel extends BasicDirectoryModel {
>>           FileSystemView fsv;
>> -        private Comparator fileComparator = new Comparator() {
>> -            public int compare(Object o, Object o1) {
>> -                return fsv.getSystemDisplayName((File) o).compareTo
>> -                      (fsv.getSystemDisplayName((File) o1));
>> +        private Comparator<File> fileComparator = new Comparator<File>() {
>> +            public int compare(File o, File o1) {
>> +                return fsv.getSystemDisplayName(o).compareTo
>> +                      (fsv.getSystemDisplayName(o1));
>>               }
>>           };
>>
>> Can you make return statement in a single line please
>>
>>
>> Regards, Pavel.
>>
>>> Hi Pavel,
>>>
>>> any news about my patch?
>>>
>>> Thanks.
>>> -Florian
>>>
>>> Am Freitag, 10. Oktober 2008 schrieb Pavel Porvatov:
>>>> Hi Florian,
>>>>
>>>> Thanks for your patch. I'll review your patch in two-three weeks and
>>>> mail you response.
>>>>
>>>> Thanks, Pavel.
>>>>
>>>>> Hi,
>>>>>
>>>>> here another patch to remove warnings in the gtk package.
>>>>>
>>>>> When compiling with
>>>>> -Xlint -J-Xms80m -J-Xmx256m -Xlint:-serial -Xlint:-deprecation
>>>>> -Xlint:-fallthrough -Xmaxwarns 2300
>>>>> this patch reduces the number of reported warnings from 201 to 112.
>>>>>
>>>>> Again, I tried only to change things related to the warnings and not to
>>>>> change any public or protected APIs in public or protected classes in
>>>>> this patch.
>>>>>
>>>>> At many places I tried to add type parameters as meaningful as
>>>>> possible, but with some cases I just used Object, if a more meaningful
>>>>> type parameter was not so trivial. You might want to refactor this if
>>>>> needed. (Though everything should work as it is.)
>>>>>
>>>>> -Florian
> 
> 




More information about the swing-dev mailing list