forked from External/mage
- added GUI scale support for dialog titles; - added GUI scale support for hints tool; - fixed broken font in chat and game logs on settings change; - fixed wrong size of pick choice dialog in some use cases;
This commit is contained in:
parent
1578ab7946
commit
8186b35dfb
9 changed files with 56 additions and 26 deletions
|
|
@ -52,11 +52,7 @@ public class PickChoiceDialog extends MageDialog {
|
|||
this.textSubMessage.enableTextLabelMode();
|
||||
|
||||
// pick choice shared in multiple dialogs, so modify window size only one time
|
||||
// TODO: implement global window size settings and runtime theme support by gui scale logic (interface like MageThemeSupported:onSizeChanged,onThemeChanged,etc)
|
||||
float guiScale = GUISizeHelper.gameFeedbackPanelFont.getSize2D() / GUISizeHelper.gameDialogAreaDefaultFontSize;
|
||||
int newWidth = GUISizeHelper.guiSizeScale(this.getSize().width, guiScale);
|
||||
int newHeight = GUISizeHelper.guiSizeScale(this.getSize().height, guiScale);
|
||||
this.setSize(newWidth, newHeight);
|
||||
this.setSize(GUISizeHelper.dialogGuiScaleSize(this.getSize()));
|
||||
|
||||
this.listChoices.setModel(new DefaultListModel<KeyValueItem>());
|
||||
this.setModal(true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue