From b83dc8f752666d1fecf33065a9b32c44b9879155 Mon Sep 17 00:00:00 2001 From: zt515 Date: Mon, 4 Dec 2017 23:56:28 +0800 Subject: [PATCH] Profile: Use default values to create profile --- .../java/io/neoterm/component/profile/Profile.kt | 16 ++++++++++------ .../frontend/preference/DefaultPreference.kt | 5 +++-- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/app/src/main/java/io/neoterm/component/profile/Profile.kt b/app/src/main/java/io/neoterm/component/profile/Profile.kt index e1cbe88..f0568dd 100644 --- a/app/src/main/java/io/neoterm/component/profile/Profile.kt +++ b/app/src/main/java/io/neoterm/component/profile/Profile.kt @@ -1,15 +1,19 @@ package io.neoterm.component.profile +import io.neoterm.frontend.preference.DefaultPreference + /** * @author kiva */ class Profile { - lateinit var profileShell: String + var profileShell = DefaultPreference.loginShell + var profileInitialCommand = DefaultPreference.initialCommand + + var enableBell = DefaultPreference.enableBell + var enableVibrate = DefaultPreference.enableVibrate + var enableExecveWrapper = DefaultPreference.enableExecveWrapper + var enableSpecialVolumeKeys = DefaultPreference.enableSpecialVolumeKeys + lateinit var profileFont: String lateinit var profileColorScheme: String - lateinit var profileInitialCommand: String - var enableBell = false - var enableVibrate = false - var enableExecveWrapper = true - var specializeVolumeKeys = false } \ No newline at end of file diff --git a/app/src/main/java/io/neoterm/frontend/preference/DefaultPreference.kt b/app/src/main/java/io/neoterm/frontend/preference/DefaultPreference.kt index ec430c7..a0ad3d6 100644 --- a/app/src/main/java/io/neoterm/frontend/preference/DefaultPreference.kt +++ b/app/src/main/java/io/neoterm/frontend/preference/DefaultPreference.kt @@ -15,5 +15,6 @@ object DefaultPreference { const val enableExplicitExtraKeysWeight = false const val enableSpecialVolumeKeys = false - const val defaultShell = "bash" -} \ No newline at end of file + const val loginShell = "bash" + const val initialCommand = "" +}