Moto Maxx with android 6.0.1 takes random pictures upon on/off button pressing: There is something prompting the camera of my cellphone to take a picture whenever I try to block it. The blocking does occur but a picture is taken.  I took a look on the system UI configs and nothing different is set. How do I check which actions are assigned to my on off/button?
Check under Display and disable the highlighted button. This is on Moto X Play and I think you should find it there in your device too