From 7d39973c8cdd043be741f0c40ee5d67de3e802e3 Mon Sep 17 00:00:00 2001 From: Paul Sladen Date: Sun, 5 Apr 2009 16:23:01 +0300 Subject: [PATCH] * Load first-use Keyboard mapping from GetDataFolder("Controls") not ~/ --- debian/changelog | 1 + openBVE/OpenBve/Program.cs | 2 +- openBVE/OpenBve/formMain.cs | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 1c73bd9..4d4adc1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,6 +4,7 @@ openbve (1.0.2.0-0buntu1) unreleased; urgency=low * debian/rules: tweak to allow easy building of Debug or Release target * pass '/fhs' from the mono wrapper instead of hardcoding * overload GetSettingsFolder() to create the config directory before return it + * Load first-use Keyboard mapping from GetDataFolder("Controls") not ~/ -- Paul Sladen Sun, 05 Apr 2009 12:33:10 +0000 diff --git a/openBVE/OpenBve/Program.cs b/openBVE/OpenBve/Program.cs index b77da7e..b8e7d37 100644 --- a/openBVE/OpenBve/Program.cs +++ b/openBVE/OpenBve/Program.cs @@ -121,7 +121,7 @@ namespace OpenBve { Interface.LoadOptions(); Interface.LoadControls(null, out Interface.CurrentControls); { - string f = Interface.GetCombinedFileName(Interface.GetControlsFolder(), "Default keyboard assignment.controls"); + string f = Interface.GetCombinedFileName(Interface.GetDataFolder("Controls"), "Default keyboard assignment.controls"); Interface.Control[] c; Interface.LoadControls(f, out c); Interface.AddControls(ref Interface.CurrentControls, c); diff --git a/openBVE/OpenBve/formMain.cs b/openBVE/OpenBve/formMain.cs index 2856cad..894748f 100644 --- a/openBVE/OpenBve/formMain.cs +++ b/openBVE/OpenBve/formMain.cs @@ -1763,7 +1763,7 @@ namespace OpenBve { private void buttonControlsImport_Click(object sender, EventArgs e) { OpenFileDialog Dialog = new OpenFileDialog(); Dialog.CheckFileExists = true; - Dialog.InitialDirectory = Interface.GetControlsFolder(); + Dialog.InitialDirectory = Interface.GetDataFolder("Controls"); Dialog.Filter = Interface.GetInterfaceString("dialog_controlsfiles") + "|*.controls|" + Interface.GetInterfaceString("dialog_allfiles") + "|*"; if (Dialog.ShowDialog() == DialogResult.OK) { try { -- 1.6.0.4