Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow users to cancel opening config directory #1098

Merged
merged 1 commit into from
Jul 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions data/fcitx5-configtool.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ export TEXTDOMAIN=fcitx5

if command -v kdialog > /dev/null 2>&1; then
message() {
kdialog --msgbox "$1"
kdialog --yesno "$1"
}
error() {
kdialog --error "$1"
}
elif command -v zenity > /dev/null 2>&1; then
message() {
zenity --info --text="$1"
zenity --question --text="$1"
}
error() {
zenity --error --text="$1"
Expand Down Expand Up @@ -138,6 +138,11 @@ run_xdg() {
;;
esac

# user choose no
if [ $? -ne 0 ]; then
exit
fi

if command="$(command -v xdg-open 2>/dev/null)"; then
exec "$command" "$HOME/.config/fcitx5"
fi
Expand Down
Loading