Android Open Source - feeligo_android_sdk Feeligo Settings






From Project

Back to project page feeligo_android_sdk.

License

The source code is released under:

MIT License

If you think the Android project feeligo_android_sdk listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package fr.baloomba.feeligo.helper;
/*w  ww .  ja v a  2 s .  co  m*/
import android.content.Context;

import fr.baloomba.feeligo.R;

public class FeeligoSettings {

    // <editor-fold desc="VARIABLES">

    private static final String TAG = FeeligoSettings.class.getSimpleName();

    private static final String FEELIGO_DOMAIN_KEY = "com.feeligo.Domain";
    private static final String FEELIGO_ACTIVE_COLOR = "com.feeligo.Color";
    private static final String FEELIGO_STORE_AVAILABLE =
            "com.feeligo.StoreAvailable";
    private static final String FEELIGO_RECENT_STICKER_AVAILABLE =
            "com.feeligo.RecentStickerAvailable";
    private static final String FEELIGO_POPULAR_STICKER_AVAILABLE =
            "com.feeligo.PopularStickerAvailable";
    private static final String FEELIGO_SEARCH_STICKER_AVAILABLE =
            "com.feeligo.SearchStickerAvailable";

    private static FeeligoSettings sInstance;

    private Context mContext;

    private static String sDomain;
    private static int sActiveColor;
    private static Boolean sStoreAvailable;
    private static Boolean sRecentAvailable;
    private static Boolean sPopularAvailable;
    private static Boolean sSearchAvailable;

    // </editor-fold>

    // <editor-fold desc="INSTANCE">

    public static FeeligoSettings getInstance(Context context) {
        if (sInstance == null) {
            sInstance = new FeeligoSettings(context);
        }
        return sInstance;
    }

    // </editor-fold>

    // <editor-fold desc="CONSTRUCTORS">

    public FeeligoSettings(Context context) {
        mContext = context;
    }

    // </editor-fold>

    // <editor-fold desc="GETTERS">

    public static String getDomain() {
        return sDomain;
    }

    public static int getActiveColor() {
        return sActiveColor;
    }

    public static Boolean getStoreAvailable() {
        return sStoreAvailable;
    }

    public static Boolean getRecentAvailable() {
        return sRecentAvailable;
    }

    public static Boolean getPopularAvailable() {
        return sPopularAvailable;
    }

    public static Boolean getSearchAvailable() {
        return sSearchAvailable;
    }

    // </editor-fold>

    // <editor-fold desc="METHODS">

    public void init() {
        sDomain = (String)FeeligoHelper.retrieveData(mContext, FEELIGO_DOMAIN_KEY);
        try {
            sActiveColor = (Integer)FeeligoHelper.retrieveData(mContext, FEELIGO_ACTIVE_COLOR);
        } catch (Exception e) {
            sActiveColor = mContext.getResources().getColor(R.color.default_active_color);
        }
        sStoreAvailable = (Boolean)FeeligoHelper.retrieveData(mContext,
                FEELIGO_STORE_AVAILABLE, true);
        sRecentAvailable = (Boolean)FeeligoHelper.retrieveData(mContext,
                FEELIGO_RECENT_STICKER_AVAILABLE, true);
        sPopularAvailable = (Boolean)FeeligoHelper.retrieveData(mContext,
                FEELIGO_POPULAR_STICKER_AVAILABLE, false);
        sSearchAvailable = (Boolean)FeeligoHelper.retrieveData(mContext,
                FEELIGO_SEARCH_STICKER_AVAILABLE, false);
    }

    // </editor-fold>

}




Java Source Code List

fr.baloomba.feeligo.FeeligoKeyboard.java
fr.baloomba.feeligo.FeeligoLog.java
fr.baloomba.feeligo.Feeligo.java
fr.baloomba.feeligo.helper.ActionBarHelper.java
fr.baloomba.feeligo.helper.DisplayHelper.java
fr.baloomba.feeligo.helper.FeeligoHelper.java
fr.baloomba.feeligo.helper.FeeligoLog.java
fr.baloomba.feeligo.helper.FeeligoSettings.java
fr.baloomba.feeligo.helper.JSONHelper.java
fr.baloomba.feeligo.helper.ViewHelper.java
fr.baloomba.feeligo.keyboard.FeeligoKeyboardGridAdapter.java
fr.baloomba.feeligo.keyboard.FeeligoKeyboardListener.java
fr.baloomba.feeligo.keyboard.FeeligoKeyboardPageAdapter.java
fr.baloomba.feeligo.keyboard.FeeligoKeyboardStickerPackPage.java
fr.baloomba.feeligo.model.StickerImage.java
fr.baloomba.feeligo.model.StickerPack.java
fr.baloomba.feeligo.model.Sticker.java
fr.baloomba.feeligo.model.UserStickerPack.java
fr.baloomba.feeligo.network.RequestBuilder.java
fr.baloomba.feeligo.network.URLBuilder.java
fr.baloomba.feeligo.store.FeeligoStickerStoreActivity.java
fr.baloomba.feeligo.store.FeeligoStickerStoreAdapter.java
fr.baloomba.feeligo.store.FeeligoStickerStoreDetailActivity.java
fr.baloomba.feeligo.store.FeeligoStoreDetailAdapter.java
fr.baloomba.feeligo.widget.FeeligoStickerImageView.java
fr.baloomba.feeligo.widget.FeeligoStickerPackTextView.java