I found a CLEAN AND WORKING SOLUTION for this ( but there is no code example here, - read and understand it why) making sure there is no scenario when taking action that normally ask for permission, doesn't do anything.
The flag shouldShowPermission() - alone, there is no difference between the first time the app ask for given permission and after "dont show again was clicked", it will return false in both cases. It will keep returning true each time until the permission has been set do Dont Ask Again. Meaning starting a second time we ask for permission to infinity or until user clicks on dont ask again.
So to differentiate first time a permission is asked for, and the time when its asked for, after the user has already set Dont Ask Again, you can use a custom flag.
It is a clean and simple workaround to that that will determine if the don't ask again option was set. ( tested and working in 2 productions apps)
The solution:
Add a flag called "rationaleDisplayed" (or whatever you want, that will be indication of permissionRationeDialog being shown to user) - with default value false, store it in prefs. After presenting to user the rationale dialog at least once, set this flag to be true.
Now you have two params, and combination of them when shouldShowRationaleDialog = false, and rationalePermissionDisplayed = true, effectively is the indication of "Dont show again" being set.
Why this works?
It works because the shouldShowRationale, will return false when first time asking for permission and the rationaleDisplayedFlag are both false, so the popup will show up correctly. (2 falses) - this is the case of asking for a permission first time.
Then if you deny the first time, sshouldShowRationale will be true, and rationaleDisplayed will be true - (2 trues), this will be the case until the dont set again option is used. - this is the case of asking for permission second time, after the first one was declined.
Finnaly, if you set Dont Ask Again - or on Android api 30 and decline permission 2 times, the flag shouldShowRationale will return false next time it is called.
There you have a case of shouldShowRationale = false, and your own flag rationaleDisplayed = true, which tells you that the Don't Ask Again was set. (otherwise, the shouldShowRationale would still be false). - this is the case when the user declined the permission twice (api 30) or set the Dont Show Again option while denying.
Having that logic case, you can now add a custom permission dialog, with instructions on how to manually enable permissions, and open the app settings with ok button. ( intent to open settings in dialog positive listener).
The flag rationaleDisplayed is basically there to make sure first time app ask for permission it will be shown correctly, but its value allows for determination of the state when user set to dont ask again.
Works like a charm.