Skip to content

Commit

Permalink
fixes #444
Browse files Browse the repository at this point in the history
  • Loading branch information
1-alex98 committed Dec 17, 2016
1 parent 87c2729 commit dfaa559
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/main/java/com/faforever/client/preferences/WindowPrefs.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
import javafx.collections.ObservableMap;

public class WindowPrefs {

private final int minHeightValue=100;
private final int minWidthValue=100;
private final IntegerProperty width;
private final IntegerProperty height;
private final BooleanProperty maximized;
Expand All @@ -34,10 +35,13 @@ public WindowPrefs() {
}

public int getWidth() {
return width.get();
if(this.width.get()<minWidthValue)return minWidthValue;
return this.width.get();
//fixes #444
}

public void setWidth(int width) {

this.width.set(width);
}

Expand All @@ -46,7 +50,9 @@ public IntegerProperty widthProperty() {
}

public int getHeight() {
return height.get();
if(this.height.get()<minHeightValue)return minHeightValue;
return this.height.get();
//fixes #444
}

public void setHeight(int height) {
Expand Down

0 comments on commit dfaa559

Please sign in to comment.