List of usage examples for android.media.projection MediaProjectionManager createScreenCaptureIntent
public Intent createScreenCaptureIntent()
From source file:Main.java
static void fireScreenCaptureIntent(Activity activity) { MediaProjectionManager manager = (MediaProjectionManager) activity .getSystemService(MEDIA_PROJECTION_SERVICE); Intent intent = manager.createScreenCaptureIntent(); activity.startActivityForResult(intent, CREATE_SCREEN_CAPTURE); }
From source file:Main.java
static void fireScreenCaptureIntent(Activity activity) { MediaProjectionManager manager = (MediaProjectionManager) activity .getSystemService(Context.MEDIA_PROJECTION_SERVICE); Intent intent = manager.createScreenCaptureIntent(); activity.startActivityForResult(intent, CREATE_SCREENSHOT); Log.i("TakeScreenshotService", "fireScreenCaptureIntent..."); }
From source file:com.garlicg.screenrecord4cm.SettingsActivity.java
/** * ?//from w w w. j a va 2s . c o m */ void requestCapture(int requestCode) { MediaProjectionManager mm = (MediaProjectionManager) getSystemService(MEDIA_PROJECTION_SERVICE); Intent intent = mm.createScreenCaptureIntent(); startActivityForResult(intent, requestCode); }