On Sun, 2009-05-17 at 17:56 +0200, Vreixo Formoso wrote:
> I have added constants for mouse buttons 8 (BACK) and 9 (FORWARD), as
> many new mice have such buttons, and not including them causes an
> exception to be thrown. I have not named it EIGHT or NINE
Sure. If you've got a reasonable name for them, that's excellent.
> /**
> - * Mouse button <code>4</code>.
> + * Mouse button <code>4</code>. Do not use this, connect to
> + * {@link ScrollEvent} instead.
> */
> + @Deprecated
> public static final MouseButton FOURTH = new MouseButton(4,
> "FOURTH");
So,
1. If you're going to mark something deprecated, use the JavaDoc
@deprecated tag please. That way you'll be consistent with everywhere
else in the library.
and,
2. Good of you to say "what to use instead". We don't generate javadoc
for deprecated methods, but it'll be good if someone is hovering over a
deprecated constant.
but,
3. I'm not sure that these should to be deprecated. Do these
ButtonPressEvents not get generated anymore? They still get emitted, *as
well as* ScrolledEvent, right?
Certainly the text about "what you really want is..." and a @link is
excellent.
4. What happens if you scroll the mouse wheel in a window without a
Viewport & Scrollbar? Do you still get ScrollEvent?
Otherwise, yes, this is great.
AfC
Sydney
|