
package me.imid.swipebacklayout.lib.app;

import me.imid.swipebacklayout.lib.SwipeBackLayout;
import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import android.view.View;

public class SwipeBackActivity extends FragmentActivity implements SwipeBackActivityBase{
    private SwipeBackActivityHelper mHelper;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        mHelper = new SwipeBackActivityHelper(this);
        mHelper.onActivityCreate();
    }

    @Override
    protected void onPostCreate(Bundle savedInstanceState) {
        super.onPostCreate(savedInstanceState);
        mHelper.onPostCreate();
    }

    @Override
    public View findViewById(int id) {
        View v = super.findViewById(id);
        if (v == null && mHelper != null)
            return mHelper.findViewById(id);
        return v;
    }
    
    @Override
    public SwipeBackLayout getSwipeBackLayout() {
        return mHelper.getSwipeBackLayout();
    }
    @Override
    public void setSwipeBackEnable(boolean enable) {
        getSwipeBackLayout().setEnableGesture(enable);
    }

    @Override
    public void scrollToFinishActivity() {
        getSwipeBackLayout().scrollToFinishActivity();
    }
}

@@ -40,60 +40,8 @@
 p;%0A%0A
-import me.imid.swipebacklayout.lib.SwipeBackLayout;%0A
 impo
@@ -62,16 +62,16 @@
 Bundle;%0A
+
 import a
@@ -137,16 +137,69 @@
 .View;%0A%0A
+import me.imid.swipebacklayout.lib.SwipeBackLayout;%0A%0A
 public c
@@ -278,16 +278,17 @@
 vityBase
+ 
 %7B%0A    pr
@@ -905,20 +905,16 @@
 ;%0A    %7D%0A
-    
 %0A    @Ov
@@ -1021,16 +1021,17 @@
 ;%0A    %7D%0A
+%0A
     @Ove

format code