Merge remote-tracking branch 'origin/master'

This commit is contained in:
Anuken
2018-12-07 12:12:09 -05:00
4 changed files with 5 additions and 3 deletions

View File

@ -127,6 +127,7 @@ public class Saves{
saveMap.put(slot.index, slot);
slot.meta = SaveIO.getData(slot.index);
current = slot;
slot.meta.sector = invalidSector;
saveSlots();
return slot;
}

View File

@ -198,7 +198,7 @@ public class FileChooser extends FloatingDialog{
//macs are confined to the Downloads/ directory
if(!OS.isMac){
Image upimage = new Image("icon-folder-parent");
TextButton upbutton = new TextButton(".." + directory.toString(), "clear");
TextButton upbutton = new TextButton(".." + directory.toString(), "clear-toggle");
upbutton.clicked(() -> {
directory = directory.parent();
updateFiles(true);
@ -220,7 +220,7 @@ public class FileChooser extends FloatingDialog{
String filename = file.name();
TextButton button = new TextButton(shorten(filename), "clear");
TextButton button = new TextButton(shorten(filename), "clear-toggle");
group.add(button);
button.clicked(() -> {

View File

@ -161,6 +161,7 @@ public class LoadDialog extends FloatingDialog{
control.saves.importSave(file);
setup();
}catch(IOException e){
e.printStackTrace();
ui.showError(Bundles.format("text.save.import.fail", Strings.parseException(e, false)));
}
}else{

View File

@ -184,7 +184,7 @@ public class PlacementFragment extends Fragment{
categories.addImageButton("icon-" + cat.name(), "clear-toggle", 16*2, () -> {
currentCategory = cat;
rebuildCategory.run();
}).group(group).update(i -> i.setChecked(group.getChecked() == i));
}).group(group).update(i -> i.setChecked(currentCategory == cat));
if(cat.ordinal() %2 == 1) categories.row();
}