You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
api-impl: misc stubs for WhatsApp support
This commit is contained in:
@@ -622,4 +622,8 @@ public class Activity extends ContextThemeWrapper implements Window.Callback, La
|
||||
public int getChangingConfigurations() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public void finishAfterTransition() {
|
||||
finish();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,10 @@ public class ActivityOptions {
|
||||
return new ActivityOptions();
|
||||
}
|
||||
|
||||
public static ActivityOptions makeSceneTransitionAnimation(Activity activity, View view, String name) {
|
||||
return new ActivityOptions();
|
||||
}
|
||||
|
||||
public Bundle toBundle() {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -53,6 +53,8 @@ public class Notification implements Parcelable {
|
||||
|
||||
public Bundle extras;
|
||||
|
||||
public String category;
|
||||
|
||||
String text;
|
||||
String title;
|
||||
List<Action> actions = new ArrayList<Action>();
|
||||
|
||||
@@ -118,4 +118,8 @@ public class NotificationManager {
|
||||
public List<NotificationChannelGroup> getNotificationChannelGroups() {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
public boolean areNotificationsEnabled() {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,4 +59,12 @@ public class PendingIntent implements Parcelable {
|
||||
|
||||
public class CanceledException extends Exception {
|
||||
}
|
||||
|
||||
public String getCreatorPackage() {
|
||||
return Context.this_application.getPackageName();
|
||||
}
|
||||
|
||||
public int getCreatorUid() {
|
||||
return Context.this_application.getApplicationInfo().uid;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,6 +46,14 @@ public class JobInfo {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setRequiresBatteryNotLow(boolean requires_battery_not_low) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setRequiresStorageNotLow(boolean requires_storage_not_low) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public JobInfo build() {
|
||||
return new JobInfo();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user