Questions tagged [android-6.0-marshmallow]

Android Marshmallow, formerly known as just "Android M", is version 6.0 of Android, is supporting API Level 23, and began shipping in October 2015.

Android Marshmallow, formerly known as just "Android M", is version 6.0 of Android, and began shipping in October 2015.

It was first shown at Google I/O 2015, with the final name confirmed on August 17th.

All API changes

Here is a summary of the major API-changes:

  • Runtime Permissions
  • Power-Saving Optimizations
  • Adoptable Storage Devices
  • Apache HTTP Client Removal
  • AudioManager Changes
  • Notifications
  • Text Selection
  • Android Keystore Changes
  • Wi-Fi and Networking Changes
  • Camera Service Changes
  • Runtime
  • Access to Hardware Identifier
  • APK Validation
  • USB Connection
  • Android for Work Changes

Official:

2168 questions
14
votes
1 answer

Lacking privileges to access camera service in Android 6.0

I am using Camera2API in Android 6.0. I was done without error in Android 5.0. However, when I used my code in the Android 6.0, I have a issue. The issue is that sometime I can open the camera successfully and take picture. However, sometime the…
14
votes
4 answers

How to handle permission requests outside Activity and Fragment?

I'm developing a custom compound View that needs to access external storage. How can I implement the permission handling without involving outside parties, i.e. Activity or Fragment? I get that I can request the permissions using the View's…
14
votes
5 answers

in android 6.0.1, retrieving the camera photo is not working

1- Some colleague (who is an android developer using android studio) is facing a problem when he tests his application on my phone (which is a nexus 5 with android 6.0.1), the problem he is facing is that when he takes an image from a gallery it…
DeyaEldeen
  • 10,847
  • 10
  • 42
  • 75
14
votes
1 answer

Why is `hasEnrolledFingerprints` giving error that it requires a permission only in my Fragment but not in the Activity in Google's Example?

I am trying to implement the Google's Fingerprint API in my app (in my Fragment specifically). Google has given an example but it's implemented inside an Activity here. My specific question is that the code below to check if there are enrolled…
14
votes
3 answers

Since marshmallow update Bluetooth discovery using BluetoothAdapter.getDefaultAdapter().startDiscovery(); is broken

I have an app using bluetooth and connecting to devices, can'f find any devices using BluetoothAdapter.getDefaultAdapter().startDiscovery(); It worked fine just before discovery. Tried also other apps, it doesn't work in other apps as well. But the…
mikugo
  • 155
  • 1
  • 2
  • 15
14
votes
1 answer

Android 6 getAccountName() Missing android.permission.GET_ACCOUNTS

I get the following Exception while running on a Android 6 device. java.lang.SecurityException: Missing android.permission.GET_ACCOUNTS This looks like a fairly straight forward exception, but for me it's not. My manifest looks like this:
Joshude
  • 183
  • 1
  • 8
14
votes
4 answers

How to read selected mock location app in Android M - API 23

I am trying to find a way of reading the new settings for mock locations in Android M. Before Android M, the mock location setting was a toggle option called "use mock locations", and it was readable with this setting:…
androidseb
  • 1,257
  • 2
  • 14
  • 17
14
votes
4 answers

windowBackground in Android 6 (Marshmallow)

I have defined a base style for my application with the following element: @color/window_background Which has set the background color for all my activities fine until I tested my app on Android 6 where…
Heinrisch
  • 5,835
  • 4
  • 33
  • 43
14
votes
4 answers

Capture image without permission with Android 6.0

I need to let the user take a picture (from the gallery or from a camera app) with Android 6.0. Because I don't need to control the camera, I wanted to use an intent as describe here: However, if you don't need such control, you can just use an…
14
votes
1 answer

Application is getting killed after enable/disable permissions from settings on Android M nexus 6

Application is restarting after enable/disble the permissions from Settings->apps->my app->Permissions. Adb can see Permission related app op changed... , 08-31 14:30:29.480 I/ActivityManager( 8206): Displayed…
14
votes
4 answers

Android 6(M) permission issue (create directory not working)

I have this code for creating directory for saving pictures: File storageDir = null; if (Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState())) { storageDir = new…
Jemshit
  • 9,501
  • 5
  • 69
  • 106
14
votes
1 answer

Android M : Billing and GCM permissions

I have an app which use GCM and Billing. In order to make it Android M-ready i'm trying to implement the new permission model. Unfortunately i can't find any informations about GCM and Billing permissions. They don't appear in the normal permission…
grunk
  • 14,718
  • 15
  • 67
  • 108
14
votes
1 answer

Custom Application not created on Android M (final preview)

The documentation of Application#onCreate() states: Called when the application is starting, before any activity, service, or receiver objects (excluding content providers) have been created. This has been true in practise for as long as I can…
Michell Bak
  • 13,182
  • 11
  • 64
  • 121
14
votes
3 answers

How to send a high-priority GCM?

I'm using a Nexus 5 with Android M Preview. My problem that I'm trying to solve is: Network access is disabled, unless your app receives a high priority Google Cloud Messaging tickle. What I'm doing is: I put the phone into Doze mode and then I…
jlopes
  • 1,012
  • 2
  • 11
  • 18
14
votes
3 answers

Set specific App to ignore optimization by code in Android M

In the new Android M build, the Battery Optimization feature will stop the app on certain condition to save battery, but for the VOIPapps that need to stay alive all the time, this feature cause troubles for the developer. Currently there is one way…
Zheng Wei
  • 141
  • 1
  • 1
  • 3