On Thu, 12 Mar 2026 08:20:12 GMT, Prasanta Sadhukhan <[email protected]> wrote:
> The protected methods ScrollBarUI#getTrackBounds() > ScrollBarUI#getThumbBounds() have > become inaccessible since JRE9 which is required to override the paint method > and to paint the knob/thumb so we can consider making them public. > > A CSR will be raised if this access expansion is accepted.. Issues / questions with this include 1) It is returning an internal reference (not a copy) to the client. Dilemma here perhaps .. making a copy every time might be inefficient. Is there any impact ? 2) It is asymmetric, the requestor asked for what s/he needed and nothing more, but that doesn't mean that's exactly what makes sense. 3) This is actually a source incompatible change. If some subclass over-rode the method and kept the protected modifier, they'll now fail to compile. This doesn't mean you can't do it, but it needs to be called out in the CSR. 4) Are there alternatives to what they requested ? ie a better way of doing this ? 5) Why specifically these methods ? 6) Conversely and extending (2) are there other methods that other people might ask for ? ------------- PR Comment: https://git.openjdk.org/jdk/pull/30209#issuecomment-4057546057
