boolean (boolean autoAdjustable) { JRootPane rootPane = getRootPane(); if (rootPane == null) return false; rootPane.putClientProperty(NO_AUTO_RESIZE, autoAdjustable ? null : Boolean.TRUE); return true; }