Originally Posted by Primokorn
I have a Xiaomi Redmi Note 7 without root and I have a small popup each time to want to enable/disable WiFi while long pressing the home button.
Not at all. I have a OnePlus 3T and location is always disabled.
I am using a note 7 too to write this reply now, no such popup. I do have miui optimization off forever, I don't know if that causes the problem. Rooted, and I use miui global stable rom only, and have no such problem using Evira or stock kernel
I do not have any need for a button to press to control WiFi though, as mine is controlled when Screen off or on. However, I just tried a quick test to enable WiFi using a floating button, no such popup problem. I did not use long press home like you, as I have that button configured for something else and I don't want to change it just to test the problem you are facing.
My mistake on the WiFi and pie thing, it has been a long time, I didn't remember correctly. But I am 100% sure WiFi SSID name cannot be shown by macrodroid on a xiaomi or Huawei with pie., Unless location is on first. Anyway, all my macros doing wifi ops Enable location first, then Disable again after the WiFi ops has completed. Like when Screen on, I want it to popup for a short duration the WiFi name and strength. One needs to put a Wait when turning on / off location before doing next action as it doesn't do it fast enough - e.g. Wait 3 or 5 seconds
Anyway, hope you find a fix, try the macrodroid forum.