Opened on 04/08/2014 at 07:29:07 AM

Last modified on 09/10/2015 at 03:17:13 PM

#281 reviewing change

Define the acceptable ads opt-in dialog in XML

Reported by: fhd Assignee: Mailkov
Priority: P4 Milestone:
Module: Adblock-Plus-for-Android Keywords: goodfirstbug
Cc: Blocked By:
Blocking: Platform: Unknown
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):



We're currently hard coding style properties, we shouldn't. See:

What to change

We should have an XML resource for the acceptable ads opt-in message.

Attachments (0)

Change History (8)

comment:1 Changed on 07/24/2014 at 07:42:01 AM by fhd

  • Keywords goodfirstbug added
  • Platform set to Unknown

comment:2 Changed on 12/31/2014 at 03:14:06 PM by Mailkov

Hi , I would like to work on this change, I have already cloned the adblockplus for android from GitHub.

Last edited on 12/31/2014 at 03:15:07 PM by Mailkov

comment:3 Changed on 01/02/2015 at 04:54:25 PM by fhd

  • Owner set to Mailkov

Sure, sorry for the delay.

Please have a look at for working with the GitHub mirrors.

comment:4 Changed on 01/07/2015 at 12:05:48 PM by Mailkov

I would like to know the email that I send the contributor agreement,
For this issue I'm creating a common layout dialog for acceptable ads is right?

Last edited on 01/07/2015 at 12:06:50 PM by Mailkov

comment:5 Changed on 01/08/2015 at 09:33:51 AM by fhd

You can send the agreement to me,

This is just about the Acceptable Ads opt-in dialog, pretty small one. Still, we should define it via XML rather than hard code it.

comment:6 Changed on 01/08/2015 at 06:43:46 PM by Mailkov

This is the current code

private void showNotificationDialog(final String title, String message, String url)
    url = TextUtils.htmlEncode(url);
    message = TextUtils.htmlEncode(message)
        .replaceAll("&lt;a&gt;(.*?)&lt;/a&gt;", "<a href=\"" + url + "\">$1</a>");
    final TextView messageView = new TextView(this);
    final int padding = 10;
    messageView.setPadding(padding, padding, padding, padding);
    new AlertDialog.Builder(this).setTitle(title)
        .setPositiveButton(R.string.ok, null).create().show();

So , I thought I would create a XML layout to add a common AlertDialog.

Example partial code :

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android=""
    android:orientation="vertical" >

        android:padding="10dp" />


Is it right?
Or Want you a simple xml resource for 10 or other?

If not, Can You show me the rows code currently hard coding style.

Thank's for help

Last edited on 01/08/2015 at 06:47:45 PM by Mailkov

comment:7 Changed on 01/27/2015 at 07:41:37 AM by Mailkov

pull request:

Can you review this ? Thanks.

comment:8 Changed on 09/10/2015 at 03:17:13 PM by fhd

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing
  • Tester set to Unknown

Seems we forgot to change the state here. It's a bit crazy for us right now in Adblock Browser, I hope we'll get around to have a look soon.

Add Comment

Modify Ticket

Change Properties
as reviewing .
as The resolution will be set. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Mailkov.
Note: See TracTickets for help on using tickets.