resize main page widget position changed
This commit is contained in:
parent
7ca69899b3
commit
bdbb6f7fd4
@ -97,6 +97,7 @@ public class RhythmBullet extends Game {
|
||||
|
||||
queueAssets();
|
||||
setScreen(initialScreen);
|
||||
|
||||
screenWidth = Gdx.graphics.getWidth();
|
||||
screenHeight = Gdx.graphics.getHeight();
|
||||
}
|
||||
@ -160,7 +161,10 @@ public class RhythmBullet extends Game {
|
||||
|
||||
@Override
|
||||
public void resize(int width, int height) {
|
||||
Gdx.app.debug("RhythmBullet/resize", "Previous size:" + screenWidth + "x" + screenHeight + " new size: " + width + "x" + height);
|
||||
if (width != screenWidth || height != screenHeight) {
|
||||
screenWidth = Gdx.graphics.getWidth();
|
||||
screenHeight = Gdx.graphics.getHeight();
|
||||
if (initComplete) {
|
||||
Gdx.app.debug("Resize", "Pre-transition is happening. Using resolution " + width + "x" + height);
|
||||
rRHandler.setResolution(width, height);
|
||||
|
@ -199,7 +199,6 @@ public class Visualizer extends Widget implements Disposable {
|
||||
updateVisualizerProperties();
|
||||
vis.updatePositionInfo();
|
||||
vis.setxPos(((vis.getWidth() - vis.getActualWidth())/2f));
|
||||
Gdx.app.debug("Visualizer", "currently offseting visualizer by (px): " + vis.getxPos());
|
||||
vis.updatePositionInfo();
|
||||
}
|
||||
|
||||
|
@ -86,12 +86,12 @@ public class MainPage extends Page implements Observer {
|
||||
table.add(quitButton).fillX();
|
||||
|
||||
musicControls = new MusicControls(core.getDefaultSkin(), mlc);
|
||||
musicControls.setPosition((getWidth()-musicControls.getMinWidth() - 20f), getHeight()-musicControls.getMinHeight()-15f);
|
||||
musicControls.setPosition((getWidth()-musicControls.getMinWidth() - 20f), getHeight()-musicControls.getMinHeight()-20f);
|
||||
addActor(musicControls);
|
||||
|
||||
scrollText = new ScrollText("...", "...", core.getDefaultSkin(), false, true);
|
||||
scrollText.setWidth(0.5f*getWidth());
|
||||
scrollText.setPosition(15, getHeight() - scrollText.getHeight()-15f);
|
||||
scrollText.setPosition(15, getHeight() - scrollText.getHeight()-25f);
|
||||
addActor(scrollText);
|
||||
|
||||
if (mlc.getMusicList().isSearched() && mlc.getCurrentMusicManager() != null) {
|
||||
|
Loading…
Reference in New Issue
Block a user