Refactoring

pull/197/head
M66B 4 years ago
parent 29990109d7
commit 5f363e1a58

@ -961,7 +961,7 @@ public class AdapterFolder extends RecyclerView.Adapter<AdapterFolder.ViewHolder
}
private void onActionPinFolder() {
ShortcutInfoCompat.Builder builder = Shortcuts.getFolder(context, folder);
ShortcutInfoCompat.Builder builder = Shortcuts.getShortcut(context, folder);
ShortcutManagerCompat.requestPinShortcut(context, builder.build(), null);
}

@ -4922,7 +4922,7 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
@Override
protected void onExecuted(Bundle args, ContactInfo[] contactInfo) {
ShortcutInfoCompat.Builder builder =
Shortcuts.getMessage(context, message, contactInfo);
Shortcuts.getShortcut(context, message, contactInfo);
ShortcutManagerCompat.requestPinShortcut(context, builder.build(), null);
}

@ -224,7 +224,7 @@ class Shortcuts {
}
@NonNull
static ShortcutInfoCompat.Builder getMessage(Context context, EntityMessage message, ContactInfo[] contactInfo) {
static ShortcutInfoCompat.Builder getShortcut(Context context, EntityMessage message, ContactInfo[] contactInfo) {
Intent thread = new Intent(context, ActivityView.class);
thread.setAction("thread:" + message.id);
thread.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
@ -264,7 +264,7 @@ class Shortcuts {
}
@NonNull
static ShortcutInfoCompat.Builder getFolder(Context context, EntityFolder folder) {
static ShortcutInfoCompat.Builder getShortcut(Context context, EntityFolder folder) {
Intent view = new Intent(context, ActivityView.class);
view.setAction("folder:" + folder.id);
view.putExtra("account", folder.account);

Loading…
Cancel
Save