com.yanzhenjie.album.AlbumConfig Java Examples

The following examples show how to use com.yanzhenjie.album.AlbumConfig. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Application.java    From Album with Apache License 2.0 5 votes vote down vote up
@Override
public void onCreate() {
    super.onCreate();
    if (instance == null) {
        instance = this;

        Album.initialize(AlbumConfig.newBuilder(this)
                .setAlbumLoader(new MediaLoader())
                .setLocale(Locale.getDefault())
                .build()
        );
    }
}
 
Example #2
Source File: App.java    From NoHttp with Apache License 2.0 5 votes vote down vote up
public void initialize() {
    AppConfig.get().initFileDir();

    NoHttp.initialize(InitializationConfig.newBuilder(this)
                        .networkExecutor(new OkHttpNetworkExecutor())
                        .cacheStore(new DiskCacheStore(this))
                        .cookieStore(new DBCookieStore(this))
                        .interceptor(new LoginInterceptor())
                        .build());

    Album.initialize(AlbumConfig.newBuilder(this).setAlbumLoader(new MediaLoader()).build());
}
 
Example #3
Source File: App.java    From Kalle with Apache License 2.0 4 votes vote down vote up
private void album() {
    Album.initialize(AlbumConfig.newBuilder(this).setAlbumLoader(new MediaLoader()).build());
}