ImageView loaded with Picasso from url and pinch zoom not working
See original GitHub issueI have problem with creating pinch to zoom effect, as i load ImageView into PhotoViewAttacher. ImageView was previously created with picasso from remote server url source.
Here is my code:
FullScreenActivity
public class FullScreenActivity extends AppCompatActivity {
private ImageView imageView;
private PhotoViewAttacher photoViewAttacher;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_full_screen);
imageView = (ImageView) findViewById(R.id.photoView);
String imageUrl = getIntent().getExtras().getString("imageUrl");
Picasso.with(getApplicationContext())
.load(imageUrl)
.into(imageView);
photoViewAttacher = new PhotoViewAttacher(imageView);
photoViewAttacher.update();
}
}`
Layout
<?xml version="1.0" encoding="utf-8"?><FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:fresco="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/photoView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</FrameLayout>
Issue Analytics
- State:
- Created 6 years ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
ImageView loaded with Picasso from url and pinch zoom not ...
I have problem with creating pinch to zoom effect, as i load ImageView into PhotoViewAttacher. ImageView was previously created with picasso ...
Read more >How to implement Pinch Zoom in Picasso library?
Picasso library is used only to load the images from network. You need to address your request with other library such as PhotoView...
Read more >Java – How to implement Pinch Zoom in Picasso library – iTecNote
Everything is working fine but I just can't figure out how to implement Pinch Zoom for all images that are being loaded from...
Read more >Android Image Gallery App: Using Gestures and Transition
Create an Android Gallery using Glide and support for gestures. Learn about shared element transitions between RecyclerView and a ViewPager.
Read more >Pinch to Zoom Android ImageView Tutorial - Coding Demos
Learn how to build pinch to zoom Android function, where you can tap on Android ImageView to see image inside an AlertDialog and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Where:
Super simple.
Still not working.