Skip to content

Commit

Permalink
Fix for regression mentioned in this stackoverflow issue https://stac…
Browse files Browse the repository at this point in the history
  • Loading branch information
shai-almog committed Aug 12, 2017
1 parent d4d6bfc commit 98754e0
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions CodenameOne/src/com/codename1/ui/Button.java
Original file line number Diff line number Diff line change
Expand Up @@ -872,10 +872,13 @@ public void setCapsText(boolean capsText) {
*/
@Override
public void setText(String t) {
if(isCapsText() && t != null) {
super.setText(getUIManager().localize(t, t).toUpperCase());
return;
}
if(isCapsText()) {
putClientProperty("cn1$origText", t);
if(t != null) {
super.setText(getUIManager().localize(t, t).toUpperCase());
return;
}
}
super.setText(t);
}
}

0 comments on commit 98754e0

Please sign in to comment.