package com.mjsheng.myappstore.activity;

import android.os.Bundle;
import android.view.View;
import android.webkit.WebView;

import com.mjsheng.myappstore.R;
import com.mjsheng.myappstore.base.BaseActivity;
import com.mjsheng.myappstore.widget.Sound;

/**
 * Created by chris on 2015/12/9.
 */
public class StatementActivity extends BaseActivity {
    private WebView webView;

    private Sound sound;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_statement);
        sound = new Sound(this);
        webView = (WebView) findViewById(R.id.web);
        webView.loadUrl("file:///android_asset/description.html");
        findViewById(R.id.iv_statement_back).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                sound.playSoundEffect();
                finish();
            }
        });
    }

    @Override
    public void finish() {
        super.finish();
        overridePendingTransition(R.anim.push_right_in, R.anim.push_right_out);
    }
}
