Make GrAtlas::removePlot static
This CL just calves off a small chunk of (Add atlased layer purging - https://codereview.chromium.org/367073002/).
R=jvanverth@google.com
TBR=jvanverth@google.com
Author: robertphillips@google.com
Review URL: https://codereview.chromium.org/388103002
diff --git a/src/gpu/GrAtlas.cpp b/src/gpu/GrAtlas.cpp
index 1bff42a..a9b8ae9 100644
--- a/src/gpu/GrAtlas.cpp
+++ b/src/gpu/GrAtlas.cpp
@@ -255,7 +255,7 @@
return NULL;
}
-void GrAtlas::removePlot(ClientPlotUsage* usage, const GrPlot* plot) {
+void GrAtlas::RemovePlot(ClientPlotUsage* usage, const GrPlot* plot) {
int index = usage->fPlots.find(const_cast<GrPlot*>(plot));
if (index >= 0) {
usage->fPlots.remove(index);
diff --git a/src/gpu/GrAtlas.h b/src/gpu/GrAtlas.h
index d63c8b9..f990408 100644
--- a/src/gpu/GrAtlas.h
+++ b/src/gpu/GrAtlas.h
@@ -94,7 +94,7 @@
GrPlot* addToAtlas(ClientPlotUsage*, int width, int height, const void* image, SkIPoint16* loc);
// remove reference to this plot
- void removePlot(ClientPlotUsage* usage, const GrPlot* plot);
+ static void RemovePlot(ClientPlotUsage* usage, const GrPlot* plot);
// get a plot that's not being used by the current draw
// this allows us to overwrite this plot without flushing
diff --git a/src/gpu/GrTextStrike.cpp b/src/gpu/GrTextStrike.cpp
index b290d6c..4079893 100644
--- a/src/gpu/GrTextStrike.cpp
+++ b/src/gpu/GrTextStrike.cpp
@@ -278,7 +278,7 @@
}
}
- fAtlas->removePlot(&fPlotUsage, plot);
+ GrAtlas::RemovePlot(&fPlotUsage, plot);
}