harism / android-pagecurl

An example application for creating page curl/flip effect on Android using OpenGL ES.
Apache License 2.0
1.66k stars 610 forks source link

PageCurlExample #80

Open DhiruBhaiBansal opened 9 years ago

DhiruBhaiBansal commented 9 years ago

I want to increase size and margins from left/right/top/bottom of image in page curl example. please send me code how to done this. thank you

myeganeh2876 commented 7 years ago
private class SizeChangedObserver implements CurlView.SizeChangedObserver { 
        @Override
        public void onSizeChanged(int w, int h) {
            if (w > h) {
                mCurlView.setViewMode(CurlView.SHOW_TWO_PAGES);
                mCurlView.setMargins(0f, 0f, 0f, 0f);
            } else {
                mCurlView.setViewMode(CurlView.SHOW_ONE_PAGE);
                mCurlView.setMargins(0f, 0f, 0f, 0f);
            }
        }
    }

jest edit mCurlView.setMargins(0f, 0f, 0f, 0f); in the CurlActivity this will provide zero margins thus full screen CurlView