ViewController: refactor 'setScreenSize' to 'setViewSize', 'setMapScreenCenter' to 'setMapViewCenter' (#523)
This commit is contained in:
@@ -62,7 +62,7 @@ public class GdxSpriteBatchTest extends GdxMapApp {
|
||||
mMapRenderer = new MapRenderer(mMap);
|
||||
mMapRenderer.onSurfaceCreated();
|
||||
mMapRenderer.onSurfaceChanged(Gdx.graphics.getWidth(), Gdx.graphics.getHeight());
|
||||
mMap.viewport().setScreenSize(Gdx.graphics.getWidth(), Gdx.graphics.getHeight());
|
||||
mMap.viewport().setViewSize(Gdx.graphics.getWidth(), Gdx.graphics.getHeight());
|
||||
|
||||
// Generate a simple texture for testing
|
||||
Pixmap pixmap = new Pixmap(64, 64, Pixmap.Format.RGB565);
|
||||
@@ -115,7 +115,7 @@ public class GdxSpriteBatchTest extends GdxMapApp {
|
||||
@Override
|
||||
public void resize(int w, int h) {
|
||||
mMapRenderer.onSurfaceChanged(w, h);
|
||||
mMap.viewport().setScreenSize(w, h);
|
||||
mMap.viewport().setViewSize(w, h);
|
||||
viewport.update(w, h);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user