MCPcopy Create free account
hub / github.com/Garten/sourcecraft / saveNewPlace

Method saveNewPlace

src/main/Main.java:103–118  ·  view source on GitHub ↗

returns true if place has been found.

()

Source from the content-addressed store, hash-verified

101 * returns true if place has been found.
102 */
103 private void saveNewPlace() {
104 if (this.gui.getRememberPlaceSelected()) {
105 String name = this.gui.getSaveLocation();
106 if (name != null && name.length() > 0) {
107 Loggger.log("Saving new place " + name + ".");
108 Place place = this.gui.getPlaceFromCoordinates();
109 Periphery.PLACES.addPlace(place);
110 }
111 } else {
112 Place place = this.gui.getPlace();
113 Place placeFromCoordinates = this.gui.getPlaceFromCoordinates();
114 if (place != null) {
115 place.setTo(placeFromCoordinates);
116 }
117 }
118 }
119
120 private void moveFolder(File materiaPath) {
121 Object[] options = { "Cancel", "Copy" };

Callers 1

MainMethod · 0.95

Calls 7

logMethod · 0.95
setToMethod · 0.95
addPlaceMethod · 0.80
getSaveLocationMethod · 0.45
getPlaceMethod · 0.45

Tested by

no test coverage detected