package com.xplora.xpsettings.Fragment;

import android.app.DialogFragment;
import android.content.Context;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import android.widget.TextView;

import com.xplora.xpsettings.Observer.Listener;
import com.xplora.xpsettings.R;

public class RoamingAlertFragment extends DialogFragment {
    private Context mContext = null;

    public static RoamingAlertFragment newInstance(Context context) {
        RoamingAlertFragment fragment = new RoamingAlertFragment();
        fragment.mContext = context;
        return fragment;
    }

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setStyle(DialogFragment.STYLE_NORMAL, android.R.style.Theme_Translucent_NoTitleBar_Fullscreen);
    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        View rootView = inflater.inflate(R.layout.fragment_roaming_alert, container, false);
        Button mOkBtn = (Button)rootView.findViewById(R.id.mOkBtn);

        mOkBtn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                remove();
            }
        });
        return rootView;
    }

    private void remove() {
        dismissAllowingStateLoss();
    }

    @Override
    public void onDestroy() {
        super.onDestroy();
    }
}