Clean up usage of theme colors, deprecated Resources.getColor* methods

Change-Id: I34e11e0773c9f8e00e3eab422781094e19a16d3d
This commit is contained in:
Alan Viverette
2015-03-18 18:10:52 -07:00
parent 9a23adf69d
commit 55eaa96fe4
13 changed files with 73 additions and 25 deletions

View File

@@ -449,10 +449,10 @@ public class RunningProcessesView extends FrameLayout
mHeader = inflater.inflate(R.layout.running_processes_header, null);
mListView.addHeaderView(mHeader, null, false /* set as not selectable */);
mColorBar = (LinearColorBar)mHeader.findViewById(R.id.color_bar);
Resources res = getResources();
mColorBar.setColors(res.getColor(R.color.running_processes_system_ram),
res.getColor(R.color.running_processes_apps_ram),
res.getColor(R.color.running_processes_free_ram));
final Context context = getContext();
mColorBar.setColors(context.getColor(R.color.running_processes_system_ram),
context.getColor(R.color.running_processes_apps_ram),
context.getColor(R.color.running_processes_free_ram));
mBackgroundProcessPrefix = (TextView)mHeader.findViewById(R.id.freeSizePrefix);
mAppsProcessPrefix = (TextView)mHeader.findViewById(R.id.appsSizePrefix);
mForegroundProcessPrefix = (TextView)mHeader.findViewById(R.id.systemSizePrefix);