Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f0eb72ea authored by nicolasroard's avatar nicolasroard
Browse files

Fix crash when showing history

bug:7418823
Change-Id: I0a84bb4d8fc8b42fc953f8301bb2b24cf64edce7
parent 24f28850
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -457,6 +457,9 @@ public class FilterShowActivity extends Activity implements OnItemClickListener,
        int accessoryPanelWidth = viewPanel.getWidth();
        int mainViewWidth = findViewById(R.id.mainView).getWidth();
        int mainPanelWidth = mImageShow.getDisplayedImageBounds().width();
        if (mainPanelWidth == 0) {
            mainPanelWidth = mainViewWidth;
        }
        int leftOver = mainViewWidth - mainPanelWidth - accessoryPanelWidth;
        if (leftOver < 0) {
            return -accessoryPanelWidth;
+1 −1
Original line number Diff line number Diff line
@@ -83,7 +83,7 @@ public class ImageShow extends View implements OnGestureListener,
    private HistoryAdapter mHistoryAdapter = null;
    private ImageStateAdapter mImageStateAdapter = null;

    private Rect mImageBounds = null;
    private Rect mImageBounds = new Rect();

    private boolean mTouchShowOriginal = false;
    private long mTouchShowOriginalDate = 0;