FORUMS
Remove All Ads from XDA

Question: Developer options

1,330 posts
Thanks Meter: 324
 
By Compusmurf, Senior Member on 31st December 2019, 12:53 AM
Post Reply Email Thread
Any way to toggle the override Forced dark mode in android 10 using Tasker on non rooted device?

Sent from my SM-N975U using Tapatalk
31st December 2019, 03:05 AM |#2  
ktmom's Avatar
Forum Moderator
Thanks Meter: 2,688
 
More
Quote:
Originally Posted by Compusmurf

Any way to toggle the override Forced dark mode in android 10 using Tasker on non rooted device?

Sent from my SM-N975U using Tapatalk

Not (yet) on A10, but if this is a setting in developer options, likely the way to do this unrooted is to use an intent to open the developer option menu, then use emulated touches via AutoInput to make the toggle happen.

Code:
        
        A1: Send Intent [ 
        Action:android.settings.APPLICATION_DEVELOPMENT_SETTINGS 
        Cat: None 
        Mime Type: 
        Data: 
        Extra: 
        Extra: 
        Extra: 
        Package: com.android.settings 
        Class: 
        Target: Activity ]
Edit:
I should point out, using the intent is old school tasker . There is an action under settings -> developer settings.


Edit 2:

Thinking about it, you should be able to set it with the tasker settings -> custom setting action. You may have to give tasker read/write secure settings permissions through ADB first if you haven't already.

Code:
   On
        A1: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 2 
        Use Root: Off 
        Read Setting To: ]

   Off
        A2: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 0 
        Use Root: Off 
        Read Setting To: ]

   Check value
        A3: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 
        Use Root: Off 
        Read Setting To: %dark_mode ]

        A4: Flash [ 
        Text:dark_mode: %dark_mode 
        Long: On ]
2nd January 2020, 02:52 PM |#3  
Compusmurf's Avatar
OP Senior Member
Flag Tampa, FL
Thanks Meter: 324
 
More
Quote:
Originally Posted by ktmom

Not (yet) on A10, but if this is a setting in developer options, likely the way to do this unrooted is to use an intent to open the developer option menu, then use emulated touches via AutoInput to make the toggle happen.

Code:
        
        A1: Send Intent [ 
        Action:android.settings.APPLICATION_DEVELOPMENT_SETTINGS 
        Cat: None 
        Mime Type: 
        Data: 
        Extra: 
        Extra: 
        Extra: 
        Package: com.android.settings 
        Class: 
        Target: Activity ]
Edit:
I should point out, using the intent is old school tasker . There is an action under settings -> developer settings.


Edit 2:

Thinking about it, you should be able to set it with the tasker settings -> custom setting action. You may have to give tasker read/write secure settings permissions through ADB first if you haven't already.

Code:
   On
        A1: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 2 
        Use Root: Off 
        Read Setting To: ]

   Off
        A2: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 0 
        Use Root: Off 
        Read Setting To: ]

   Check value
        A3: Custom Setting [ 
        Type: Secure 
        Name: ui_night_mode 
        Value: 
        Use Root: Off 
        Read Setting To: %dark_mode ]

        A4: Flash [ 
        Text:dark_mode: %dark_mode 
        Long: On ]

That's regular night/dark. In 10 there is another called. FORCED DARK. After spending an hour digging thru global and system areas I see nothing for forced dark there unless it has a different name. I will dig some more.

Sent from my SM-N975U using Tapatalk
2nd January 2020, 03:29 PM |#4  
ktmom's Avatar
Forum Moderator
Thanks Meter: 2,688
 
More
You shouldn't have to dig. Use the built-in tasker custom setting action, then on the name field, tap the magnifying glass for help to find the setting.
3rd January 2020, 04:32 AM |#5  
Compusmurf's Avatar
OP Senior Member
Flag Tampa, FL
Thanks Meter: 324
 
More
Quote:
Originally Posted by ktmom

You shouldn't have to dig. Use the built-in tasker custom setting action, then on the name field, tap the magnifying glass for help to find the setting.

Cool feature. Says nothing found. Will poke around some.

Sent from my SM-N975U using Tapatalk
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes