question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cropbox getting dislocated

See original GitHub issue

I am facing a strange problem. I am using this in a viewpager which has different fragments. Each fragment has a crop imageview. After I set the cropbox, i save the value of croppoints in a variable. When i move in this pattern between fragments 0->1->2->1->0 then 0th fragment doesn’t show cropimageview correctly and box is dislocated. I am using this code in OnViewCreated ->

public void onBitmapLoaded(Bitmap bitmap, Picasso.LoadedFrom from) {
mProgressBar.setVisibility(View.GONE);
cropImageView.setVisibility(View.VISIBLE);
cropImageView.setImageResource(bitmap);
                if (answerModel.isFilled()) {
                    cropImageView.setCropRect(answerModel.getRect());
                    lockBoundingBox();
                } else {
                    unlockBoundingBox();
                }
            }

and to save the croppoints in answermodel,

answerModel.addRect(cropImageView.getCropRect());

Can you help me solve this?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:20 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
ArthurHubcommented, Jun 20, 2016

sorry, not yet, hope to tackle it in the next few days.

1reaction
mshukla19commented, Jun 17, 2016

Thank you. Not able to test right now. Will test it asap. 😃 On 17-Jun-2016 7:52 PM, “Arthur” notifications@github.com wrote:

fixed the issue by preventing state restore if already set, so

  1. Make sure you use latest version (2.2.3), it should just work when you use 2.2.+ in gradle.
  2. cropImageView.setImageResource(R.drawable.xyz) should be before cropImageView.setCropRect(rect1) as rectangle cannot be set before there is image to crop.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ArthurHub/Android-Image-Cropper/issues/99#issuecomment-226782136, or mute the thread https://github.com/notifications/unsubscribe/AHPg3nL6y5ZyPJS7IMoIkHj33u6GW5_yks5qMq2agaJpZM4I4PJH .

Read more comments on GitHub >

github_iconTop Results From Across the Web

k2pdfopt version history - Willus.com
This helped fix an issue where rows were not ** getting selected properly in a ... NEW MS WINDOWS GUI FEATURES ** -...
Read more >
Inhibition of Atrogin-1/MAFbx Mediated MyoD Proteolysis ...
Mice were killed by cervical dislocation, and muscles were collected 14 days after electro transfer. Histological analysis and fibre measurement.
Read more >
Chronic Shoulder Instability and Dislocation - OrthoInfo - AAOS
Once a shoulder has dislocated, it is vulnerable to repeat episodes. When the shoulder is loose and slips out of place repeatedly, it...
Read more >
Nroff/Troff User's Manual - GitHub Pages
The CropBox restricts the area of the page that is shown by a PDF viewer program. It is useful to hide cut marks...
Read more >
BIOQUANT OSTEO 2020 20.8.6 Release Notes
Issue Resolved: BIOQUANT defualt Path Gets Broken if Image is Opened or you go Live/Held. The defualt path information for the Selected Lists...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found