Coder Social home page Coder Social logo

Comments (4)

MFlisar avatar MFlisar commented on June 15, 2024

Here's what I do:

  • I show a settings button with the text from here:

<string name="gdpr_withdraw_consent">Withdraw data protection consent</string>

  • On click I reset the consent, no need to show the dialog here actually

    GDPR.getInstance().resetConsent()

  • in the activity before this either check the consent in onResume/onActivityResult/onCreate, whatever is appropriate for your setup...

This way if the user leaves the settings screen he is presented the consent dialog again...

from gdprdialog.

Luklek avatar Luklek commented on June 15, 2024

What if the user passed a negative consent in the beginning? does the wording "withdraw" can still be used here? (I guess yes, but asked anyway^^)

I am showing this setting in the NavDrawer like this at the moment:

case R.id.drawer_item_gdpr:
            GDPRConsentState consentState = GDPR.getInstance().getConsentState();
            mSetup = new GDPRSetup(GDPRDefinitions.ADMOB) // add all networks you use to the constructor, signature is `GDPRSetup(GDPRNetwork... adNetworks)`
                    .withPrivacyPolicy(AppConfig.PRIVACY_POLICY_URL)
                    .withForceSelection(true)
                    .withCustomDialogTheme(R.style.BottomSheet)
                    .withLoadAdMobNetworks(getString(R.string.admob_pub_id_1), getString(R.string.admob_pub_id_2))
                    .withNoToolbarTheme(true)
                    .withBottomSheet(true)
            ;
            GDPRDialog dlg = GDPRDialog.newInstance(mSetup, consentState.getLocation(), false);
            dlg.show(this.getSupportFragmentManager(), GDPRDialog.class.getName());
            break;

from gdprdialog.

ivfit avatar ivfit commented on June 15, 2024

Two items should be displayed in the app's menu: "Privacy Policy" (with the link to detailed privacy policy explaining how we use user's data) and e.g. "Data Protection" or similar opening GDPR dialog.

from gdprdialog.

MFlisar avatar MFlisar commented on June 15, 2024

The default texts say "you can always change your mind in the app settings" or similar and so do all the translations...

So I would put it in the settings, but this is up to you.

The current code looks fine, but can be replaced with following:

GDPR.getInstance().resetConsent(); // after this call the `checkIfNeedsToBeShown` function will show the dialog again
mSetup = ...;
GDPR.getInstance().checkIfNeedsToBeShown(this, mSetup);

from gdprdialog.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.