Search in sources :

Example 21 with Intent

use of android.content.Intent in project UltimateAndroid by cymcsg.

the class ProgressMenuItemActivity method onOptionsItemSelected.

@Override
public boolean onOptionsItemSelected(MenuItem item) {
    switch(item.getItemId()) {
        case R.id.action_refresh:
            Intent reloadService = new Intent(this, ReloadIntentService.class);
            reloadReceiver.startProgress();
            this.startService(reloadService);
            return true;
        case R.id.howToUse:
            BasicUtils.sendIntent(this, HowToUseActivity.class, "data", "ProgressMenuItemActivity");
            return true;
        default:
            return super.onOptionsItemSelected(item);
    }
}
Also used : Intent(android.content.Intent)

Example 22 with Intent

use of android.content.Intent in project kickmaterial by byoutline.

the class CategoriesListActivity method launch.

public static void launch(@Nonnull Activity context, @Nonnull Category category, View sharedElement) {
    final Bundle options = KickMaterialBaseActivity.getSharedElementsBundle(context, sharedElement);
    Intent intent = new Intent(context, CategoriesListActivity.class);
    intent.putExtra(ARG_CATEGORY, Parcels.wrap(category));
    ActivityCompat.startActivityForResult(context, intent, DEFAULT_REQUEST_CODE, options);
}
Also used : Bundle(android.os.Bundle) Intent(android.content.Intent)

Example 23 with Intent

use of android.content.Intent in project android by cSploit.

the class System method checkNetworking.

public static boolean checkNetworking(final Activity current) {
    if (!mNetwork.isConnected()) {
        Intent intent = new Intent();
        intent.putExtra(WifiScannerFragment.CONNECTED, false);
        current.setResult(Activity.RESULT_OK, intent);
        String title = current.getString(R.string.error);
        String message = current.getString(R.string.wifi_went_down);
        new FatalDialog(title, message, current).show();
        return false;
    }
    return true;
}
Also used : Intent(android.content.Intent) FatalDialog(org.csploit.android.gui.dialogs.FatalDialog)

Example 24 with Intent

use of android.content.Intent in project photo-picker-plus-android by chute.

the class ServicesActivity method recordVideo.

@Override
public void recordVideo() {
    Intent intent = new Intent(MediaStore.ACTION_VIDEO_CAPTURE);
    mediaPath = AppUtil.getOutputMediaFileUri(MediaType.VIDEO);
    intent.putExtra(MediaStore.EXTRA_OUTPUT, mediaPath);
    intent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY, 1);
    startTheCamera(intent, Constants.CAMERA_VIDEO_REQUEST);
}
Also used : Intent(android.content.Intent)

Example 25 with Intent

use of android.content.Intent in project photo-picker-plus-android by chute.

the class IntentUtil method deliverDataToInitialActivity.

public static void deliverDataToInitialActivity(final FragmentActivity context, final List<AssetModel> collection, AccountModel accountModel) {
    final PhotoPickerPlusIntentWrapper wrapper = new PhotoPickerPlusIntentWrapper(new Intent(context, ServicesActivity.class));
    wrapper.setMediaCollection(collection);
    if (accountModel != null) {
        wrapper.setAccountModel(accountModel);
    }
    wrapper.getIntent().addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP);
    wrapper.startActivity(context);
}
Also used : Intent(android.content.Intent) ServicesActivity(com.getchute.android.photopickerplus.ui.activity.ServicesActivity)

Aggregations

Intent (android.content.Intent)13686 PendingIntent (android.app.PendingIntent)2730 View (android.view.View)1004 ComponentName (android.content.ComponentName)943 Bundle (android.os.Bundle)841 ResolveInfo (android.content.pm.ResolveInfo)743 Uri (android.net.Uri)707 Context (android.content.Context)663 RemoteException (android.os.RemoteException)657 TextView (android.widget.TextView)624 PackageManager (android.content.pm.PackageManager)524 Test (org.junit.Test)509 IntentFilter (android.content.IntentFilter)496 ArrayList (java.util.ArrayList)465 ActivityNotFoundException (android.content.ActivityNotFoundException)376 ImageView (android.widget.ImageView)375 BroadcastReceiver (android.content.BroadcastReceiver)354 IOException (java.io.IOException)353 File (java.io.File)337 Notification (android.app.Notification)283