예제 #1
0
        /* ----------------------------------------------------------------- */
        ///
        /// ChangeDataFolder
        ///
        /// <summary>
        /// Setting コマンドを実行します。
        /// </summary>
        ///
        /* ----------------------------------------------------------------- */
        private void ChangeDataFolder(SettingViewModel vm)
        {
            var dest = string.Empty;

            vm.Subscribe <OpenDirectoryMessage>(e =>
            {
                e.Value  = RootDirectory();
                e.Cancel = false;
                dest     = e.Value;
            });

            vm.Subscribe <ApplyMessage>(
                e => vm.Local.Value.DataDirectory = dest
                );

            vm.SelectDataDirectory.Execute(null);
            vm.Apply.Execute(null);
        }