MCPcopy Index your code
hub / github.com/benfry/processing4 / rename

Method rename

app/src/processing/app/ui/Recent.java:254–265  ·  view source on GitHub ↗
(Editor editor, String oldPath)

Source from the content-addressed store, hash-verified

252
253
254 synchronized static public void rename(Editor editor, String oldPath) {
255 if (records.size() == Preferences.getInteger("recent.count")) {
256 records.remove(0); // remove the first entry
257 }
258 int index = findRecord(oldPath);
259 //check if record exists
260 if (index != -1) {
261 records.remove(index);
262 }
263 records.add(new Record(editor));
264 save();
265 }
266
267
268 static int findRecord(String path) {

Callers 1

renameSketchMethod · 0.95

Calls 6

getIntegerMethod · 0.95
findRecordMethod · 0.95
saveMethod · 0.95
sizeMethod · 0.45
removeMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected