package com.trace.drawing.people.tools;

import android.app.Application;
import android.content.res.AssetManager;
import android.graphics.Typeface;

import com.trace.drawing.people.bean.MyDataBase;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;

public class App extends Application {
    public static String Key_ViewDir = "pre_dir";
    public static String Key_ISMAIN = "ismain";
    public static String Key_Camera = "camera_data";

    public static String TAG = "=============";


    public static App app;

    public static final String[] CLASS_NAMES = {
            "local_Aesthetic",
            "local_One Line Art",
            "local_People",
            "local_Animals",
            "local_Birds",
            "local_Tropical Paradise",
            "local_World Monuments",
            "local_Butterfly",
            "local_Food",
            "local_Cartoons",
            "local_Christmas",
            "local_Festivals",
            "local_Flowers",
            "local_Fruits",
            "local_General",
            "local_Mehndi",
            "local_Nature",
            "local_Architectures",
            "local_Rangoli",
            "local_Sports",
            "local_Car",
            "local_Space"
    };

//    private String APPId ="h67505d35951dc";
//
//    private String AppKey ="a81d17e5cc10cd96a65fe75c0ffd15334";

    public static Typeface defaultFont;
    private static List<String> classNameList;

    @Override
    public void onCreate() {
        super.onCreate();
        app = this;
        AssetManager assets = getAssets();
        defaultFont = Typeface.createFromAsset(assets, "myfont.ttf");
        classNameList = Arrays.asList(CLASS_NAMES);
        MyDataBase.init(this);

    }

//    private void initSDk(){
//        ATSDK.checkIsEuTraffic(this, new NetTrafficeCallback() {
//
//            @Override
//            public void onResultCallback(boolean isEU) {
//                if (isEU && ATSDK.getGDPRDataLevel(MyApplication.this) == ATSDK.UNKNOWN) {
//                    ATSDK.showGdprAuth(MyApplication.this);
//                }
//
//            }
//
//            @Override
//            public void onErrorCallback(String errorMsg) {
//
//            }
//        });
//        ATSDK.init( this, APPId, AppKey);
//        ;
//    }

    public static List<String> getAllDir() {
        Collections.shuffle(classNameList);
        return classNameList;


    }
}
