public final void setMaxWidth ( final int maxWidth ) { if ( maxWidth != - 1 ) { Condition . INSTANCE . ensureAtLeast ( maxWidth , 1 , "The maximum width must be at least 1" ) ; } this . maxWidth = maxWidth ; requestLayout ( ) ; }
Sets the maximum width of the view .