forked from Tencent/Shadow
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(activity-container): 添加API23,24引入的类型的假定义,使API22可以正常启动
Activity在新版本上添加的新接口带有一些新版本才引入的系统类。这些类在低版本系统上找不到,会导致Crash。通过定义假的类定义,可以使ClassLoader在BootClassLoader找不到类定义时也能找到一个假的定义。由于这些方法在低版本系统上本来就不工作,所以假定义可以满足需求。 Tencent#230
- Loading branch information
Showing
3 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
5 changes: 5 additions & 0 deletions
5
projects/sdk/core/activity-container/src/main/java/android/app/assist/AssistContent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package android.app.assist; | ||
|
||
//避免API 23以下系统找不到这个类 | ||
public interface AssistContent { | ||
} |
5 changes: 5 additions & 0 deletions
5
projects/sdk/core/activity-container/src/main/java/android/view/SearchEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package android.view; | ||
|
||
//避免API 23以下系统找不到这个类 | ||
public interface SearchEvent { | ||
} |
5 changes: 5 additions & 0 deletions
5
projects/sdk/core/activity-container/src/main/java/java/util/function/Consumer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package java.util.function; | ||
|
||
//避免API 24以下系统找不到这个类 | ||
public interface Consumer<T> { | ||
} |