checkstyle: Add LocalFinalVariableName
This commit is contained in:
parent
6ee3dba3ea
commit
caa91186cc
@ -1188,14 +1188,14 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
private final View.OnClickListener expanderDescription = new View.OnClickListener() {
|
private final View.OnClickListener expanderDescription = new View.OnClickListener() {
|
||||||
public void onClick(View v) {
|
public void onClick(View v) {
|
||||||
final TextView description = (TextView) ll_view_more_description.findViewById(R.id.description);
|
final TextView description = (TextView) ll_view_more_description.findViewById(R.id.description);
|
||||||
final TextView view_more_permissions = (TextView) ll_view_more_description.findViewById(R.id.view_more_description);
|
final TextView viewMorePermissions = (TextView) ll_view_more_description.findViewById(R.id.view_more_description);
|
||||||
if (view_all_description) {
|
if (view_all_description) {
|
||||||
description.setMaxLines(Integer.MAX_VALUE);
|
description.setMaxLines(Integer.MAX_VALUE);
|
||||||
view_more_permissions.setText(getString(R.string.less));
|
viewMorePermissions.setText(getString(R.string.less));
|
||||||
} else {
|
} else {
|
||||||
description.setMaxLines(MAX_LINES);
|
description.setMaxLines(MAX_LINES);
|
||||||
description.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
description.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||||
view_more_permissions.setText(R.string.more);
|
viewMorePermissions.setText(R.string.more);
|
||||||
}
|
}
|
||||||
view_all_description ^= true;
|
view_all_description ^= true;
|
||||||
}
|
}
|
||||||
@ -1207,7 +1207,7 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
final Spanned desc = Html.fromHtml(getApp().description, null, new Utils.HtmlTagHandler());
|
final Spanned desc = Html.fromHtml(getApp().description, null, new Utils.HtmlTagHandler());
|
||||||
description.setMovementMethod(SafeLinkMovementMethod.getInstance(getActivity()));
|
description.setMovementMethod(SafeLinkMovementMethod.getInstance(getActivity()));
|
||||||
description.setText(trimNewlines(desc));
|
description.setText(trimNewlines(desc));
|
||||||
final View view_more_description = view.findViewById(R.id.view_more_description);
|
final View viewMoreDescription = view.findViewById(R.id.view_more_description);
|
||||||
description.post(new Runnable() {
|
description.post(new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
@ -1221,9 +1221,9 @@ public class AppDetails extends AppCompatActivity implements ProgressListener, A
|
|||||||
ll_view_more_description = (LinearLayout) view.findViewById(R.id.ll_description);
|
ll_view_more_description = (LinearLayout) view.findViewById(R.id.ll_description);
|
||||||
ll_view_more_description.setOnClickListener(expanderDescription);
|
ll_view_more_description.setOnClickListener(expanderDescription);
|
||||||
|
|
||||||
view_more_description.setOnClickListener(expanderDescription);
|
viewMoreDescription.setOnClickListener(expanderDescription);
|
||||||
} else {
|
} else {
|
||||||
view_more_description.setVisibility(View.GONE);
|
viewMoreDescription.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -107,9 +107,9 @@ public class InstallConfirmActivity extends Activity implements OnCancelListener
|
|||||||
findViewById(R.id.tabscontainer).setVisibility(View.GONE);
|
findViewById(R.id.tabscontainer).setVisibility(View.GONE);
|
||||||
findViewById(R.id.divider).setVisibility(View.VISIBLE);
|
findViewById(R.id.divider).setVisibility(View.VISIBLE);
|
||||||
}
|
}
|
||||||
final int NP = perms.getPermissionCount(AppSecurityPermissions.WHICH_PERSONAL);
|
final int np = perms.getPermissionCount(AppSecurityPermissions.WHICH_PERSONAL);
|
||||||
final int ND = perms.getPermissionCount(AppSecurityPermissions.WHICH_DEVICE);
|
final int nd = perms.getPermissionCount(AppSecurityPermissions.WHICH_DEVICE);
|
||||||
if (NP > 0 || ND > 0) {
|
if (np > 0 || nd > 0) {
|
||||||
permVisible = true;
|
permVisible = true;
|
||||||
LayoutInflater inflater = (LayoutInflater) getSystemService(
|
LayoutInflater inflater = (LayoutInflater) getSystemService(
|
||||||
Context.LAYOUT_INFLATER_SERVICE);
|
Context.LAYOUT_INFLATER_SERVICE);
|
||||||
@ -118,13 +118,13 @@ public class InstallConfirmActivity extends Activity implements OnCancelListener
|
|||||||
mScrollView = (CaffeinatedScrollView) root.findViewById(R.id.scrollview);
|
mScrollView = (CaffeinatedScrollView) root.findViewById(R.id.scrollview);
|
||||||
}
|
}
|
||||||
final ViewGroup privacyList = (ViewGroup) root.findViewById(R.id.privacylist);
|
final ViewGroup privacyList = (ViewGroup) root.findViewById(R.id.privacylist);
|
||||||
if (NP > 0) {
|
if (np > 0) {
|
||||||
privacyList.addView(perms.getPermissionsView(AppSecurityPermissions.WHICH_PERSONAL));
|
privacyList.addView(perms.getPermissionsView(AppSecurityPermissions.WHICH_PERSONAL));
|
||||||
} else {
|
} else {
|
||||||
privacyList.setVisibility(View.GONE);
|
privacyList.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
final ViewGroup deviceList = (ViewGroup) root.findViewById(R.id.devicelist);
|
final ViewGroup deviceList = (ViewGroup) root.findViewById(R.id.devicelist);
|
||||||
if (ND > 0) {
|
if (nd > 0) {
|
||||||
deviceList.addView(perms.getPermissionsView(AppSecurityPermissions.WHICH_DEVICE));
|
deviceList.addView(perms.getPermissionsView(AppSecurityPermissions.WHICH_DEVICE));
|
||||||
} else {
|
} else {
|
||||||
root.findViewById(R.id.devicelist).setVisibility(View.GONE);
|
root.findViewById(R.id.devicelist).setVisibility(View.GONE);
|
||||||
|
@ -121,12 +121,12 @@ public abstract class AppListFragment extends ThemeableListFragment implements
|
|||||||
* be bad.
|
* be bad.
|
||||||
*/
|
*/
|
||||||
public boolean updateEmptyRepos() {
|
public boolean updateEmptyRepos() {
|
||||||
final String TRIED_EMPTY_UPDATE = "triedEmptyUpdate";
|
final String triedEmptyUpdate = "triedEmptyUpdate";
|
||||||
SharedPreferences prefs = getActivity().getPreferences(Context.MODE_PRIVATE);
|
SharedPreferences prefs = getActivity().getPreferences(Context.MODE_PRIVATE);
|
||||||
boolean hasTriedEmptyUpdate = prefs.getBoolean(TRIED_EMPTY_UPDATE, false);
|
boolean hasTriedEmptyUpdate = prefs.getBoolean(triedEmptyUpdate, false);
|
||||||
if (!hasTriedEmptyUpdate) {
|
if (!hasTriedEmptyUpdate) {
|
||||||
Utils.debugLog(TAG, "Empty app list, and we haven't done an update yet. Forcing repo update.");
|
Utils.debugLog(TAG, "Empty app list, and we haven't done an update yet. Forcing repo update.");
|
||||||
prefs.edit().putBoolean(TRIED_EMPTY_UPDATE, true).commit();
|
prefs.edit().putBoolean(triedEmptyUpdate, true).commit();
|
||||||
UpdateService.updateNow(getActivity());
|
UpdateService.updateNow(getActivity());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<module name="TreeWalker">
|
<module name="TreeWalker">
|
||||||
|
|
||||||
<!--<module name="ConstantName" />-->
|
<!--<module name="ConstantName" />-->
|
||||||
<!--<module name="LocalFinalVariableName" />-->
|
<module name="LocalFinalVariableName" />
|
||||||
<module name="LocalVariableName" />
|
<module name="LocalVariableName" />
|
||||||
<module name="MemberName" />
|
<module name="MemberName" />
|
||||||
<module name="MethodName" />
|
<module name="MethodName" />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user