Skip to content

Commit

Permalink
feat(android): support use host ImageDecoderAdapter
Browse files Browse the repository at this point in the history
  • Loading branch information
siguangli authored and hippy-actions[bot] committed Jan 3, 2023
1 parent f981bdf commit fe72cce
Show file tree
Hide file tree
Showing 16 changed files with 550 additions and 342 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
import com.tencent.mtt.hippy.adapter.thirdparty.HippyThirdPartyAdapter;

import com.tencent.renderer.ControllerProvider;
import com.tencent.renderer.component.image.ImageLoaderAdapter;
import com.tencent.renderer.component.image.ImageDecoderAdapter;
import com.tencent.vfs.Processor;
import java.util.ArrayList;
import java.util.HashMap;
Expand Down Expand Up @@ -248,6 +248,7 @@ public static class EngineInitParams {
// 可选参数 code cache的名字,如果设置为空,则不启用code cache,默认为 ""
public String codeCacheTag = "";

public ImageDecoderAdapter imageDecoderAdapter;
//可选参数 接收RuntimeId
public HippyThirdPartyAdapter thirdPartyAdapter;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
import com.tencent.mtt.hippy.utils.UIThreadUtils;
import com.tencent.renderer.ControllerProvider;
import com.tencent.renderer.FrameworkProxy;
import com.tencent.renderer.component.image.ImageDecoderAdapter;
import com.tencent.renderer.component.text.FontAdapter;
import com.tencent.vfs.DefaultProcessor;
import com.tencent.devtools.vfs.DevtoolsProcessor;
Expand Down Expand Up @@ -281,6 +282,11 @@ public FontAdapter getFontAdapter() {
return mEngineContext.getGlobalConfigs().getFontScaleAdapter();
}

@Override
public ImageDecoderAdapter getImageDecoderAdapter() {
return mEngineContext.getGlobalConfigs().getImageDecoderAdapter();
}

@NonNull
public VfsManager getVfsManager() {
return mEngineContext.getVfsManager();
Expand Down
Loading

0 comments on commit fe72cce

Please sign in to comment.