2024-04-30 15:01:29 +08:00
|
|
|
import { defineStore } from "pinia";
|
|
|
|
import { ref } from "vue";
|
|
|
|
|
|
|
|
export const useKeyboardStore = defineStore("keyboard", () => {
|
|
|
|
const showKeyInfoFlag = ref(false);
|
|
|
|
const showSettingFlag = ref(false);
|
|
|
|
const showButtonSettingFlag = ref(false);
|
2024-04-30 17:37:10 +08:00
|
|
|
const showButtonAddFlag = ref(false);
|
2024-05-31 18:05:03 +08:00
|
|
|
const editSwipePointsFlag = ref(false);
|
2024-04-30 15:01:29 +08:00
|
|
|
const activeButtonIndex = ref(-1);
|
|
|
|
const activeSteeringWheelButtonKeyIndex = ref(-1);
|
|
|
|
const edited = ref(false);
|
|
|
|
|
|
|
|
return {
|
|
|
|
showKeyInfoFlag,
|
|
|
|
showSettingFlag,
|
|
|
|
showButtonSettingFlag,
|
2024-04-30 17:37:10 +08:00
|
|
|
showButtonAddFlag,
|
2024-05-31 18:05:03 +08:00
|
|
|
editSwipePointsFlag,
|
2024-04-30 15:01:29 +08:00
|
|
|
activeButtonIndex,
|
|
|
|
activeSteeringWheelButtonKeyIndex,
|
|
|
|
edited,
|
|
|
|
};
|
|
|
|
});
|