Codota Logo
ResolverActivity
Code IndexAdd Codota to your IDE (free)

How to use
ResolverActivity
in
com.lody.virtual.client.stub

Best Java code snippets using com.lody.virtual.client.stub.ResolverActivity (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
LocalDateTime l =
  • Codota Iconnew LocalDateTime()
  • Codota IconLocalDateTime.now()
  • Codota IconDateTimeFormatter formatter;String text;formatter.parseLocalDateTime(text)
  • Smart code suggestions by Codota
}
origin: android-hacker/VirtualXposed

super.onCreate(savedInstanceState);
mLaunchedFromUid = userid;
mPm = getPackageManager();
mAlwaysUseOption = alwaysUseOption;
mMaxColumns = getResources().getInteger(R.integer.config_maxResolverActivityColumns);
final ActivityManager am = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
mIconDpi = am.getLauncherLargeIconDensity();
mIconSize = am.getLauncherLargeIconSize();
  if (mLaunchedFromUid < 0) {
    finish();
    return;
  startSelected(0, false);
  mRegistered = false;
  finish();
  return;
origin: android-hacker/VirtualXposed

Drawable loadIconForResolveInfo(ResolveInfo ri) {
  Drawable dr;
  try {
    if (ri.resolvePackageName != null && ri.icon != 0) {
      dr = getIcon(mPm.getResourcesForApplication(ri.resolvePackageName), ri.icon);
      if (dr != null) {
        return dr;
      }
    }
    final int iconRes = ri.getIconResource();
    if (iconRes != 0) {
      dr = getIcon(mPm.getResourcesForApplication(ri.activityInfo.packageName), iconRes);
      if (dr != null) {
        return dr;
      }
    }
  } catch (PackageManager.NameNotFoundException e) {
    VLog.e(TAG, "Couldn't find resources for package\n" + VLog.getStackTraceString(e));
  }
  return ri.loadIcon(mPm);
}
origin: android-hacker/VirtualXposed

@Override
protected void onStop() {
  super.onStop();
  if (mRegistered) {
    mRegistered = false;
  }
  if ((getIntent().getFlags() & Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
    // This resolver is in the unusual situation where it has been
    // launched at the top of a new task.  We don't let it be added
    // to the recent tasks shown to the user, and we need to make sure
    // that each time we are launched we get the correct launching
    // uid (not re-using the same resolver from an old launching uid),
    // so we will now finish ourself since being no longer visible,
    // the user probably can't get back to us.
    if (!isChangingConfigurations()) {
      finish();
    }
  }
}
origin: android-hacker/VirtualXposed

void startSelected(int which, boolean always) {
  if (isFinishing()) {
    return;
  }
  ResolveInfo ri = mAdapter.resolveInfoForPosition(which);
  Intent intent = mAdapter.intentForPosition(which);
  onIntentSelected(ri, intent, always);
  finish();
}
origin: android-hacker/VirtualXposed

@SuppressLint("MissingSuperCall")
@Override
protected void onCreate(Bundle savedInstanceState) {
  final int titleResource;
  final Intent intent = makeMyIntent();
  final Set<String> categories = intent.getCategories();
  if (Intent.ACTION_MAIN.equals(intent.getAction())
      && categories != null
      && categories.size() == 1
      && categories.contains(Intent.CATEGORY_HOME)) {
    titleResource = R.string.choose;
  } else {
    titleResource = R.string.choose;
  }
  onCreate(savedInstanceState, intent, getResources().getText(titleResource),
      null, null, true, VUserHandle.getCallingUserId());
}
origin: android-hacker/VirtualXposed

    getPackageManager().addPreferredActivity(filter, bestMatch, set,
        intent.getComponent());
  } else {
      Reflect.on(VClientImpl.get().getCurrentApplication().getPackageManager()).call("setLastChosenActivity",
          intent,
          intent.resolveTypeIfNeeded(getContentResolver()),
          PackageManager.MATCH_DEFAULT_ONLY,
          filter, bestMatch, intent.getComponent());
if (info == null) {
  startActivity(intent);
origin: android-hacker/VirtualXposed

  @Override
  public void onCancel(DialogInterface dialog) {
    finish();
  }
});
origin: android-hacker/VirtualXposed

private Intent makeMyIntent() {
  Intent intent = new Intent(getIntent());
  intent.setComponent(null);
  intent.setFlags(intent.getFlags() & ~Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
  return intent;
}
origin: android-hacker/VirtualXposed

@Override
protected DisplayResolveInfo doInBackground(DisplayResolveInfo... params) {
  final DisplayResolveInfo info = params[0];
  if (info.displayIcon == null) {
    info.displayIcon = loadIconForResolveInfo(info.ri);
  }
  return info;
}
origin: android-hacker/VirtualXposed

    getPackageManager(), 0);
if (ai == null) {
  VLog.w("ResolverActivity", "No activity found for "
    ri.loadLabel(getPackageManager()), null, ii));
origin: darkskygit/VirtualApp

void startSelected(int which, boolean always) {
  if (isFinishing()) {
    return;
  }
  ResolveInfo ri = mAdapter.resolveInfoForPosition(which);
  Intent intent = mAdapter.intentForPosition(which);
  onIntentSelected(ri, intent, always);
  finish();
}
origin: darkskygit/VirtualApp

@SuppressLint("MissingSuperCall")
@Override
protected void onCreate(Bundle savedInstanceState) {
  final int titleResource;
  final Intent intent = makeMyIntent();
  final Set<String> categories = intent.getCategories();
  if (Intent.ACTION_MAIN.equals(intent.getAction())
      && categories != null
      && categories.size() == 1
      && categories.contains(Intent.CATEGORY_HOME)) {
    titleResource = R.string.choose;
  } else {
    titleResource = R.string.choose;
  }
  onCreate(savedInstanceState, intent, getResources().getText(titleResource),
      null, null, true, VUserHandle.getCallingUserId());
}
origin: darkskygit/VirtualApp

    getPackageManager().addPreferredActivity(filter, bestMatch, set,
        intent.getComponent());
  } else {
      Reflect.on(VClientImpl.get().getCurrentApplication().getPackageManager()).call("setLastChosenActivity",
          intent,
          intent.resolveTypeIfNeeded(getContentResolver()),
          PackageManager.MATCH_DEFAULT_ONLY,
          filter, bestMatch, intent.getComponent());
if (info == null) {
  startActivity(intent);
origin: android-hacker/VirtualXposed

public void handlePackagesChanged() {
  final int oldItemCount = getCount();
  rebuildList();
  notifyDataSetChanged();
  final int newItemCount = getCount();
  if (newItemCount == 0) {
    // We no longer have any items...  just finish the activity.
    finish();
  }
}
origin: bzsome/VirtualApp-x326

private Intent makeMyIntent() {
  Intent intent = new Intent(getIntent());
  intent.setComponent(null);
  intent.setFlags(intent.getFlags() & ~Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
  return intent;
}
origin: darkskygit/VirtualApp

@Override
protected DisplayResolveInfo doInBackground(DisplayResolveInfo... params) {
  final DisplayResolveInfo info = params[0];
  if (info.displayIcon == null) {
    info.displayIcon = loadIconForResolveInfo(info.ri);
  }
  return info;
}
origin: bzsome/VirtualApp-x326

    getPackageManager(), 0);
if (ai == null) {
  VLog.w("ResolverActivity", "No activity found for "
    ri.loadLabel(getPackageManager()), null, ii));
origin: darkskygit/VirtualApp

super.onCreate(savedInstanceState);
mLaunchedFromUid = userid;
mPm = getPackageManager();
mAlwaysUseOption = alwaysUseOption;
mMaxColumns = getResources().getInteger(R.integer.config_maxResolverActivityColumns);
final ActivityManager am = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
mIconDpi = am.getLauncherLargeIconDensity();
mIconSize = am.getLauncherLargeIconSize();
  if (mLaunchedFromUid < 0) {
    finish();
    return;
  startSelected(0, false);
  mRegistered = false;
  finish();
  return;
origin: bzsome/VirtualApp-x326

void startSelected(int which, boolean always) {
  if (isFinishing()) {
    return;
  }
  ResolveInfo ri = mAdapter.resolveInfoForPosition(which);
  Intent intent = mAdapter.intentForPosition(which);
  onIntentSelected(ri, intent, always);
  finish();
}
origin: bzsome/VirtualApp-x326

@SuppressLint("MissingSuperCall")
@Override
protected void onCreate(Bundle savedInstanceState) {
  final int titleResource;
  final Intent intent = makeMyIntent();
  final Set<String> categories = intent.getCategories();
  if (Intent.ACTION_MAIN.equals(intent.getAction())
      && categories != null
      && categories.size() == 1
      && categories.contains(Intent.CATEGORY_HOME)) {
    titleResource = R.string.choose;
  } else {
    titleResource = R.string.choose;
  }
  onCreate(savedInstanceState, intent, getResources().getText(titleResource),
      null, null, true, VUserHandle.getCallingUserId());
}
com.lody.virtual.client.stubResolverActivity

Most used methods

  • finish
  • getContentResolver
  • getIcon
  • getIntent
  • getPackageManager
  • getResources
  • getSystemService
  • isChangingConfigurations
  • isFinishing
  • loadIconForResolveInfo
  • makeMyIntent
  • onCreate
  • makeMyIntent,
  • onCreate,
  • onIntentSelected,
  • showAppDetails,
  • startActivity,
  • startSelected

Popular in Java

  • Updating database using SQL prepared statement
  • setRequestProperty (URLConnection)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • Stack (java.util)
    The Stack class represents a last-in-first-out (LIFO) stack of objects. It extends class Vector with
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • LogFactory (org.apache.commons.logging)
    A minimal incarnation of Apache Commons Logging's LogFactory API, providing just the common Log look
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now