merging 1.7.5 source: windows changes
This commit is contained in:
@@ -17,13 +17,15 @@
|
||||
*/
|
||||
package com.shatteredpixel.shatteredpixeldungeon.windows;
|
||||
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ShatteredPixelDungeon;
|
||||
import com.watabou.noosa.BitmapTextMultiline;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.scenes.PixelScene;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ui.Window;
|
||||
|
||||
public class WndMessage extends Window {
|
||||
|
||||
private static final int WIDTH = 120;
|
||||
|
||||
private static final int WIDTH_P = 120;
|
||||
private static final int WIDTH_L = 144;
|
||||
private static final int MARGIN = 4;
|
||||
|
||||
public WndMessage( String text ) {
|
||||
@@ -31,7 +33,7 @@ public class WndMessage extends Window {
|
||||
super();
|
||||
|
||||
BitmapTextMultiline info = PixelScene.createMultiline( text, 6 );
|
||||
info.maxWidth = WIDTH - MARGIN * 2;
|
||||
info.maxWidth = (ShatteredPixelDungeon.landscape() ? WIDTH_L : WIDTH_P) - MARGIN * 2;
|
||||
info.measure();
|
||||
info.x = info.y = MARGIN;
|
||||
add( info );
|
||||
|
||||
Reference in New Issue
Block a user