Index: applications/editors/josm/plugins/turnrestrictions/build.xml
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/build.xml	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/build.xml	(revision 33780)
@@ -4,5 +4,5 @@
     <property name="commit.message" value="Adapt to JOSM core change (DefaultNameFormatter)"/>
     <!-- enter the *lowest* JOSM version this plugin is currently compatible with -->
-    <property name="plugin.main.version" value="12663"/>
+    <property name="plugin.main.version" value="12859"/>
 
     <!-- Configure these properties (replace "..." accordingly).
Index: applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/MemberRoleCellEditor.java
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/MemberRoleCellEditor.java	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/MemberRoleCellEditor.java	(revision 33780)
@@ -8,8 +8,8 @@
 import javax.swing.table.TableCellEditor;
 
+import org.openstreetmap.josm.data.tagging.ac.AutoCompletionItem;
+import org.openstreetmap.josm.data.tagging.ac.AutoCompletionPriority;
 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletingTextField;
-import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionItemPriority;
 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionList;
-import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionListItem;
 
 /**
@@ -32,8 +32,8 @@
         autoCompletionList = new AutoCompletionList();
         editor.setAutoCompletionList(autoCompletionList);
-        autoCompletionList.add(new AutoCompletionListItem("from", AutoCompletionItemPriority.IS_IN_STANDARD));
-        autoCompletionList.add(new AutoCompletionListItem("to", AutoCompletionItemPriority.IS_IN_STANDARD));
-        autoCompletionList.add(new AutoCompletionListItem("via", AutoCompletionItemPriority.IS_IN_STANDARD));
-        autoCompletionList.add(new AutoCompletionListItem("location_hint", AutoCompletionItemPriority.IS_IN_STANDARD));
+        autoCompletionList.add(new AutoCompletionItem("from", AutoCompletionPriority.IS_IN_STANDARD));
+        autoCompletionList.add(new AutoCompletionItem("to", AutoCompletionPriority.IS_IN_STANDARD));
+        autoCompletionList.add(new AutoCompletionItem("via", AutoCompletionPriority.IS_IN_STANDARD));
+        autoCompletionList.add(new AutoCompletionItem("location_hint", AutoCompletionPriority.IS_IN_STANDARD));
     }
 
Index: applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditor.java
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditor.java	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditor.java	(revision 33780)
@@ -40,6 +40,4 @@
 import org.openstreetmap.josm.command.ChangeCommand;
 import org.openstreetmap.josm.command.conflict.ConflictAddCommand;
-import org.openstreetmap.josm.data.Preferences.PreferenceChangeEvent;
-import org.openstreetmap.josm.data.Preferences.PreferenceChangedListener;
 import org.openstreetmap.josm.data.conflict.Conflict;
 import org.openstreetmap.josm.data.osm.DefaultNameFormatter;
@@ -55,4 +53,6 @@
 import org.openstreetmap.josm.plugins.turnrestrictions.preferences.PreferenceKeys;
 import org.openstreetmap.josm.plugins.turnrestrictions.qa.IssuesView;
+import org.openstreetmap.josm.spi.preferences.PreferenceChangeEvent;
+import org.openstreetmap.josm.spi.preferences.PreferenceChangedListener;
 import org.openstreetmap.josm.tools.CheckParameterUtil;
 import org.openstreetmap.josm.tools.ImageProvider;
@@ -546,5 +546,5 @@
             }
 
-            MainApplication.undoRedo.add(new AddCommand(getLayer(), newTurnRestriction));
+            MainApplication.undoRedo.add(new AddCommand(getLayer().data, newTurnRestriction));
 
             // make sure everybody is notified about the changes
@@ -568,5 +568,5 @@
             editorModel.apply(toUpdate);
             Conflict<Relation> conflict = new Conflict<>(getTurnRestriction(), toUpdate);
-            MainApplication.undoRedo.add(new ConflictAddCommand(getLayer(), conflict));
+            MainApplication.undoRedo.add(new ConflictAddCommand(getLayer().data, conflict));
         }
 
@@ -578,5 +578,5 @@
             if (getTurnRestriction().getDataSet() == null) {
                 editorModel.apply(getTurnRestriction());
-                MainApplication.undoRedo.add(new AddCommand(getTurnRestriction()));
+                MainApplication.undoRedo.add(new AddCommand(getLayer().data, getTurnRestriction()));
             } else {
                 Relation toUpdate = new Relation(getTurnRestriction());
Index: applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/list/TurnRestrictionsListDialog.java
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/list/TurnRestrictionsListDialog.java	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/list/TurnRestrictionsListDialog.java	(revision 33780)
@@ -25,6 +25,4 @@
 import org.openstreetmap.josm.Main;
 import org.openstreetmap.josm.actions.AutoScaleAction;
-import org.openstreetmap.josm.data.Preferences.PreferenceChangeEvent;
-import org.openstreetmap.josm.data.Preferences.PreferenceChangedListener;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
 import org.openstreetmap.josm.data.osm.Relation;
@@ -42,4 +40,6 @@
 import org.openstreetmap.josm.plugins.turnrestrictions.editor.TurnRestrictionEditorManager;
 import org.openstreetmap.josm.plugins.turnrestrictions.preferences.PreferenceKeys;
+import org.openstreetmap.josm.spi.preferences.PreferenceChangeEvent;
+import org.openstreetmap.josm.spi.preferences.PreferenceChangedListener;
 import org.openstreetmap.josm.tools.ImageProvider;
 
Index: applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/preferences/PreferencesPanel.java
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/preferences/PreferencesPanel.java	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/preferences/PreferencesPanel.java	(revision 33780)
@@ -196,5 +196,5 @@
     public void saveToPreferences(Preferences prefs) {
         prefs.put(PreferenceKeys.ROAD_SIGNS, rbSetA.isSelected() ? "set-a" : "set-b");
-        prefs.put(PreferenceKeys.SHOW_VIAS_IN_BASIC_EDITOR, cbShowViaListInBasicEditor.isSelected());
+        prefs.putBoolean(PreferenceKeys.SHOW_VIAS_IN_BASIC_EDITOR, cbShowViaListInBasicEditor.isSelected());
     }
 
Index: applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java
===================================================================
--- applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java	(revision 33741)
+++ applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java	(revision 33780)
@@ -10,6 +10,5 @@
 import javax.swing.AbstractAction;
 
-import org.openstreetmap.josm.actions.SplitWayAction;
-import org.openstreetmap.josm.actions.SplitWayAction.SplitWayResult;
+import org.openstreetmap.josm.command.SplitWayCommand;
 import org.openstreetmap.josm.data.osm.DefaultNameFormatter;
 import org.openstreetmap.josm.data.osm.Node;
@@ -131,8 +130,7 @@
         public void actionPerformed(ActionEvent e) {
 
-            SplitWayResult result = null;
+            SplitWayCommand result = null;
             if (role == null || role.equals(TurnRestrictionLegRole.FROM)) {
-                  result = SplitWayAction.split(
-                          parent.getEditorModel().getLayer(),
+                  result = SplitWayCommand.split(
                           from,
                           Collections.singletonList(intersect),
@@ -140,11 +138,10 @@
                   );
                   if (result != null) {
-                	  MainApplication.undoRedo.add(result.getCommand());
+                      MainApplication.undoRedo.add(result);
                   }
             }
 
             if (role == null || role.equals(TurnRestrictionLegRole.TO)) {
-                result = SplitWayAction.split(
-                        parent.getEditorModel().getLayer(),
+                result = SplitWayCommand.split(
                         to,
                         Collections.singletonList(intersect),
@@ -152,5 +149,5 @@
                 );
                 if (result != null) {
-                    MainApplication.undoRedo.add(result.getCommand());
+                    MainApplication.undoRedo.add(result);
                 }
                 if (result == null) return;
