Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build() method starts to return void instead of TileView #539

Open
mwe8 opened this issue Jan 15, 2020 · 1 comment
Open

build() method starts to return void instead of TileView #539

mwe8 opened this issue Jan 15, 2020 · 1 comment

Comments

@mwe8
Copy link

mwe8 commented Jan 15, 2020

@Override
protected void onCreate(Bundle savedInstanceState) {
  super.onCreate(savedInstanceState);
  TileView tileView = new TileView.Builder(this)
  	.setSize(3000, 3000)
  	.defineZoomLevel("tile-%d-%d.png")
  	.build();
  setContentView(tileView);
}

So, now how we can use it?

@danramteke
Copy link

danramteke commented Jan 18, 2020

This is what I do, @mwe8 :

this.tileView = findViewById(R.id.tileview)
TileView.Builder(this.tileView)
            .setSize(MAP_WIDTH, MAP_HEIGHT)
            .setTileSize(512)
            .defineZoomLevel("map-tiles/13_%d_%d.png")
            .addReadyListener(readyDelegate)
            .build()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants