danoniplus 49.2.0 → 49.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/js/danoni_main.js +17 -6
- package/package.json +1 -1
package/js/danoni_main.js
CHANGED
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
*
|
|
5
5
|
* Source by tickle
|
|
6
6
|
* Created : 2018/10/08
|
|
7
|
-
* Revised : 2026/07/
|
|
7
|
+
* Revised : 2026/07/12
|
|
8
8
|
*
|
|
9
9
|
* https://github.com/cwtickle/danoniplus
|
|
10
10
|
*/
|
|
11
|
-
const g_version = `Ver 49.
|
|
12
|
-
const g_revisedDate = `2026/07/
|
|
11
|
+
const g_version = `Ver 49.3.0`;
|
|
12
|
+
const g_revisedDate = `2026/07/12`;
|
|
13
13
|
|
|
14
14
|
// カスタム用バージョン (danoni_custom.js 等で指定可)
|
|
15
15
|
let g_localVersion = ``;
|
|
@@ -5013,7 +5013,7 @@ const setColorList = (_data, _colorInit, _colorInitLength,
|
|
|
5013
5013
|
|
|
5014
5014
|
/**
|
|
5015
5015
|
* 複合カスタムゲージの定義設定
|
|
5016
|
-
* |customGauge=
|
|
5016
|
+
* |customGauge=_Original::F::Original,_Normal::V::Normal,Escape::V|
|
|
5017
5017
|
* @param {object} _dosObj
|
|
5018
5018
|
* @param {string} [object.scoreId=0]
|
|
5019
5019
|
* @returns {object} ※Object.assign(obj, resetCustomGauge(...))の形で呼び出しが必要
|
|
@@ -5041,6 +5041,9 @@ const resetCustomGauge = (_dosObj, { scoreId = 0 } = {}) => {
|
|
|
5041
5041
|
const customGaugeSets = customGauges[j].split(`::`);
|
|
5042
5042
|
obj[`custom${scoreId}`][j] = customGaugeSets[0];
|
|
5043
5043
|
obj[`varCustom${scoreId}`][j] = boolToSwitch(customGaugeSets[1] === `V`);
|
|
5044
|
+
if (hasVal(customGaugeSets[2])) {
|
|
5045
|
+
g_lblNameObj[`u_${customGaugeSets[0]}`] = customGaugeSets[2];
|
|
5046
|
+
}
|
|
5044
5047
|
}
|
|
5045
5048
|
if (scoreId === 0) {
|
|
5046
5049
|
obj.custom = obj.custom0.concat();
|
|
@@ -10754,6 +10757,7 @@ const keyConfigInit = (_kcType = g_kcType, _initFlg = false) => {
|
|
|
10754
10757
|
document.getElementById(`key${_num}`).classList.replace(g_cssObj.button_Mini, g_cssObj.button_Next);
|
|
10755
10758
|
}
|
|
10756
10759
|
}
|
|
10760
|
+
keyconfigKeyboardPreview.refresh();
|
|
10757
10761
|
};
|
|
10758
10762
|
|
|
10759
10763
|
/**
|
|
@@ -11412,6 +11416,7 @@ const keyconfigKeyboardPreview = (() => {
|
|
|
11412
11416
|
canvasMap: null,
|
|
11413
11417
|
keyDataList: [], // { code, x, y, w, h, label } — drawMap で照合するキャッシュ
|
|
11414
11418
|
scale: 1, // BASE_KEY_W/H に掛けるスケール係数
|
|
11419
|
+
cvsX: 0, // Canvas の左上 X 座標(divRoot 内の相対座標)
|
|
11415
11420
|
cvsW: 500, // 実際の Canvas 幅(スケール計算後)
|
|
11416
11421
|
cvsH: 240, // 実際の Canvas 高さ(スケール計算後)
|
|
11417
11422
|
};
|
|
@@ -11453,7 +11458,12 @@ const keyconfigKeyboardPreview = (() => {
|
|
|
11453
11458
|
const totalW = baseMainW + BASE_KEY_GAP * 2 + BASE_NAV_W + BASE_KEY_GAP * 2
|
|
11454
11459
|
+ BASE_KEY_GAP * 3 + BASE_NUM_W;
|
|
11455
11460
|
|
|
11456
|
-
const
|
|
11461
|
+
const tkObj = getKeyInfo();
|
|
11462
|
+
const keyCtrlPtn = `${g_keyObj.currentKey}_${g_keyObj.currentPtn}`;
|
|
11463
|
+
const configKeyGroupList = g_headerObj.keyGroupOrder[g_stateObj.scoreId] ??
|
|
11464
|
+
g_keyObj[`keyGroupOrder${keyCtrlPtn}`] ?? tkObj.keyGroupList;
|
|
11465
|
+
|
|
11466
|
+
const availW = g_btnWidth() + (configKeyGroupList.length > 1 ? -g_lblPosObj.lnkKeySwitch.w - 10 : 0);
|
|
11457
11467
|
const availH = g_sHeight - 200 - LEGEND_H; // 下部 UI ぶんを除いた高さ
|
|
11458
11468
|
|
|
11459
11469
|
// 縦幅基準: MAIN/NAV 高さ と テンキー高さ(余白込み)の大きい方
|
|
@@ -11463,6 +11473,7 @@ const keyconfigKeyboardPreview = (() => {
|
|
|
11463
11473
|
const scaleH = availH / totalH;
|
|
11464
11474
|
_state.scale = Math.min(scaleW, scaleH, 1.5); // 最大 1.5 倍まで拡大可
|
|
11465
11475
|
|
|
11476
|
+
_state.cvsX = configKeyGroupList.length > 1 ? (-g_lblPosObj.lnkKeySwitch.w - 10) / 2 : 0;
|
|
11466
11477
|
_state.cvsW = Math.floor(totalW * _state.scale);
|
|
11467
11478
|
_state.cvsH = Math.floor(totalH * _state.scale) + LEGEND_H;
|
|
11468
11479
|
};
|
|
@@ -11735,7 +11746,7 @@ const keyconfigKeyboardPreview = (() => {
|
|
|
11735
11746
|
divRoot.appendChild(btn);
|
|
11736
11747
|
|
|
11737
11748
|
// プレビューエリア: 水平・垂直センタリング
|
|
11738
|
-
const areaX = g_btnX() + Math.floor((g_btnWidth() - _state.cvsW) / 2);
|
|
11749
|
+
const areaX = g_btnX() + Math.floor((g_btnWidth() - _state.cvsW) / 2) + _state.cvsX;
|
|
11739
11750
|
const areaY = 130;
|
|
11740
11751
|
|
|
11741
11752
|
const areaDiv = createEmptySprite(divRoot, C_PREVIEW_ID, {
|