Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Delta Between Two Patch Sets: adblockplussbrowser/src/org/adblockplus/sbrowser/contentblocker/MainPreferences.java

Issue 29445587: Issue 5223 - App is freezing sometimes (Closed)
Left Patch Set: Removed AsycTask, added ProgressDialog for pendig subscriptions, deleted locks on UI thread Created June 1, 2017, 4:35 p.m.
Right Patch Set: Fixed formatting and set dialog = null Created June 26, 2017, 2:04 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
LEFTRIGHT
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2016 Eyeo GmbH 3 * Copyright (C) 2006-2016 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 else if (this.getString(R.string.key_application_activated).equals(key)) 245 else if (this.getString(R.string.key_application_activated).equals(key))
246 { 246 {
247 if (this.dialogTitleResId == R.string.setup_dialog_title) 247 if (this.dialogTitleResId == R.string.setup_dialog_title)
248 { 248 {
249 this.dismissDialog(); 249 this.dismissDialog();
250 } 250 }
251 } 251 }
252 } 252 }
253 253
254 @Override 254 @Override
255 public void subscriptionUpdateRequested() 255 public void subscriptionUpdateRequested(final boolean enabled)
256 { 256 {
257 this.dialog = ProgressDialog.show(this, null, this.getString(R.string.subscr iption_update_message)); 257 this.dialog = ProgressDialog.show(this, null, enabled ?
anton 2017/06/26 14:45:54 would it not be better to have it like this ".. en
258 getString(R.string.add_subscription_dialog_message) : getString(R.string .remove_subscription_dialog_message));
258 } 259 }
259 260
260 @Override 261 @Override
261 public void subscriptionUpdatedApplied() 262 public void subscriptionUpdatedApplied()
262 { 263 {
263 if (dialog != null) 264 this.dismissDialog();
264 {
265 dialog.dismiss();
266 }
267 } 265 }
268 } 266 }
LEFTRIGHT

Powered by Google App Engine
This is Rietveld