mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-06 14:46:04 +02:00
Hold shift to delete without prompt
This commit is contained in:
+86
-57
@@ -128,7 +128,8 @@ speechSynthesis.getVoices();
|
|||||||
isSteamVRRunning: false,
|
isSteamVRRunning: false,
|
||||||
isHmdAfk: false,
|
isHmdAfk: false,
|
||||||
appVersion: '',
|
appVersion: '',
|
||||||
latestAppVersion: ''
|
latestAppVersion: '',
|
||||||
|
shiftHeld: false
|
||||||
},
|
},
|
||||||
i18n,
|
i18n,
|
||||||
computed: {},
|
computed: {},
|
||||||
@@ -234,6 +235,12 @@ speechSynthesis.getVoices();
|
|||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
document.addEventListener('keydown', function (e) {
|
||||||
|
if (e.shiftKey) {
|
||||||
|
$app.shiftHeld = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
document.addEventListener('keyup', function (e) {
|
document.addEventListener('keyup', function (e) {
|
||||||
if (e.ctrlKey) {
|
if (e.ctrlKey) {
|
||||||
if (e.key === 'I') {
|
if (e.key === 'I') {
|
||||||
@@ -252,6 +259,10 @@ speechSynthesis.getVoices();
|
|||||||
) {
|
) {
|
||||||
$app.screenshotMetadataCarouselChange(carouselNavigation);
|
$app.screenshotMetadataCarouselChange(carouselNavigation);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!e.shiftKey) {
|
||||||
|
$app.shiftHeld = false;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
addEventListener('wheel', (event) => {
|
addEventListener('wheel', (event) => {
|
||||||
@@ -7187,15 +7198,18 @@ speechSynthesis.getVoices();
|
|||||||
};
|
};
|
||||||
|
|
||||||
$app.methods.deleteFriendLog = function (row) {
|
$app.methods.deleteFriendLog = function (row) {
|
||||||
// FIXME: 메시지 수정
|
$app.removeFromArray(this.friendLogTable.data, row);
|
||||||
|
database.deleteFriendLogHistory(row.rowId);
|
||||||
|
};
|
||||||
|
|
||||||
|
$app.methods.deleteFriendLogPrompt = function (row) {
|
||||||
this.$confirm('Continue? Delete Log', 'Confirm', {
|
this.$confirm('Continue? Delete Log', 'Confirm', {
|
||||||
confirmButtonText: 'Confirm',
|
confirmButtonText: 'Confirm',
|
||||||
cancelButtonText: 'Cancel',
|
cancelButtonText: 'Cancel',
|
||||||
type: 'info',
|
type: 'info',
|
||||||
callback: (action) => {
|
callback: (action) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
$app.removeFromArray(this.friendLogTable.data, row);
|
this.deleteFriendLog(row);
|
||||||
database.deleteFriendLogHistory(row.rowId);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -7265,17 +7279,20 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
|
|
||||||
$app.methods.deletePlayerModeration = function (row) {
|
$app.methods.deletePlayerModeration = function (row) {
|
||||||
// FIXME: 메시지 수정
|
API.deletePlayerModeration({
|
||||||
this.$confirm('Continue? Delete Moderation', 'Confirm', {
|
moderated: row.targetUserId,
|
||||||
|
type: row.type
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
$app.methods.deletePlayerModerationPrompt = function (row) {
|
||||||
|
this.$confirm(`Continue? Delete Moderation ${row.type}`, 'Confirm', {
|
||||||
confirmButtonText: 'Confirm',
|
confirmButtonText: 'Confirm',
|
||||||
cancelButtonText: 'Cancel',
|
cancelButtonText: 'Cancel',
|
||||||
type: 'info',
|
type: 'info',
|
||||||
callback: (action) => {
|
callback: (action) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
API.deletePlayerModeration({
|
this.deletePlayerModeration(row);
|
||||||
moderated: row.targetUserId,
|
|
||||||
type: row.type
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -7433,43 +7450,51 @@ speechSynthesis.getVoices();
|
|||||||
};
|
};
|
||||||
|
|
||||||
$app.methods.hideNotification = function (row) {
|
$app.methods.hideNotification = function (row) {
|
||||||
|
if (row.type === 'ignoredFriendRequest') {
|
||||||
|
API.deleteHiddenFriendRequest(
|
||||||
|
{
|
||||||
|
notificationId: row.id
|
||||||
|
},
|
||||||
|
row.senderUserId
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
API.hideNotification({
|
||||||
|
notificationId: row.id
|
||||||
|
});
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
$app.methods.hideNotificationPrompt = function (row) {
|
||||||
this.$confirm(`Continue? Decline ${row.type}`, 'Confirm', {
|
this.$confirm(`Continue? Decline ${row.type}`, 'Confirm', {
|
||||||
confirmButtonText: 'Confirm',
|
confirmButtonText: 'Confirm',
|
||||||
cancelButtonText: 'Cancel',
|
cancelButtonText: 'Cancel',
|
||||||
type: 'info',
|
type: 'info',
|
||||||
callback: (action) => {
|
callback: (action) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
if (row.type === 'ignoredFriendRequest') {
|
this.hideNotification(row);
|
||||||
API.deleteHiddenFriendRequest(
|
|
||||||
{
|
|
||||||
notificationId: row.id
|
|
||||||
},
|
|
||||||
row.senderUserId
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
API.hideNotification({
|
|
||||||
notificationId: row.id
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
$app.methods.deleteNotificationLog = function (row) {
|
$app.methods.deleteNotificationLog = function (row) {
|
||||||
|
$app.removeFromArray(this.notificationTable.data, row);
|
||||||
|
if (
|
||||||
|
row.type !== 'friendRequest' &&
|
||||||
|
row.type !== 'ignoredFriendRequest'
|
||||||
|
) {
|
||||||
|
database.deleteNotification(row.id);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
$app.methods.deleteNotificationLogPrompt = function (row) {
|
||||||
this.$confirm(`Continue? Delete ${row.type}`, 'Confirm', {
|
this.$confirm(`Continue? Delete ${row.type}`, 'Confirm', {
|
||||||
confirmButtonText: 'Confirm',
|
confirmButtonText: 'Confirm',
|
||||||
cancelButtonText: 'Cancel',
|
cancelButtonText: 'Cancel',
|
||||||
type: 'info',
|
type: 'info',
|
||||||
callback: (action) => {
|
callback: (action) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
$app.removeFromArray(this.notificationTable.data, row);
|
this.deleteNotificationLog(row);
|
||||||
if (
|
|
||||||
row.type !== 'friendRequest' &&
|
|
||||||
row.type !== 'ignoredFriendRequest'
|
|
||||||
) {
|
|
||||||
database.deleteNotification(row.id);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -18416,27 +18441,30 @@ speechSynthesis.getVoices();
|
|||||||
return displayName;
|
return displayName;
|
||||||
};
|
};
|
||||||
|
|
||||||
$app.methods.confirmDeleteGameLogUserInstance = function (row) {
|
$app.methods.deleteGameLogUserInstance = function (row) {
|
||||||
this.$confirm('Continue? Delete', 'Confirm', {
|
database.deleteGameLogInstance({
|
||||||
confirmButtonText: 'Confirm',
|
id: this.previousInstancesUserDialog.userRef.id,
|
||||||
cancelButtonText: 'Cancel',
|
displayName: this.previousInstancesUserDialog.userRef.displayName,
|
||||||
type: 'info',
|
location: row.location
|
||||||
callback: (action) => {
|
});
|
||||||
if (action === 'confirm') {
|
$app.removeFromArray(this.previousInstancesUserDialogTable.data, row);
|
||||||
database.deleteGameLogInstance({
|
};
|
||||||
id: this.previousInstancesUserDialog.userRef.id,
|
|
||||||
displayName:
|
$app.methods.deleteGameLogUserInstancePrompt = function (row) {
|
||||||
this.previousInstancesUserDialog.userRef
|
this.$confirm(
|
||||||
.displayName,
|
'Continue? Delete User From GameLog Instance',
|
||||||
location: row.location
|
'Confirm',
|
||||||
});
|
{
|
||||||
$app.removeFromArray(
|
confirmButtonText: 'Confirm',
|
||||||
this.previousInstancesUserDialogTable.data,
|
cancelButtonText: 'Cancel',
|
||||||
row
|
type: 'info',
|
||||||
);
|
callback: (action) => {
|
||||||
|
if (action === 'confirm') {
|
||||||
|
this.deleteGameLogUserInstance(row);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// #endregion
|
// #endregion
|
||||||
@@ -18504,20 +18532,21 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
$app.methods.confirmDeleteGameLogWorldInstance = function (row) {
|
$app.methods.deleteGameLogWorldInstance = function (row) {
|
||||||
this.$confirm('Continue? Delete', 'Confirm', {
|
database.deleteGameLogInstanceByInstanceId({
|
||||||
|
location: row.location
|
||||||
|
});
|
||||||
|
$app.removeFromArray(this.previousInstancesWorldDialogTable.data, row);
|
||||||
|
};
|
||||||
|
|
||||||
|
$app.methods.deleteGameLogWorldInstancePrompt = function (row) {
|
||||||
|
this.$confirm('Continue? Delete GameLog Instance', 'Confirm', {
|
||||||
confirmButtonText: 'Confirm',
|
confirmButtonText: 'Confirm',
|
||||||
cancelButtonText: 'Cancel',
|
cancelButtonText: 'Cancel',
|
||||||
type: 'info',
|
type: 'info',
|
||||||
callback: (action) => {
|
callback: (action) => {
|
||||||
if (action === 'confirm') {
|
if (action === 'confirm') {
|
||||||
database.deleteGameLogInstanceByInstanceId({
|
this.deleteGameLogWorldInstance(row);
|
||||||
location: row.location
|
|
||||||
});
|
|
||||||
$app.removeFromArray(
|
|
||||||
this.previousInstancesWorldDialogTable.data,
|
|
||||||
row
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -226,7 +226,7 @@
|
|||||||
"minimized": "Start minimized",
|
"minimized": "Start minimized",
|
||||||
"tray": "Minimize to tray when closing",
|
"tray": "Minimize to tray when closing",
|
||||||
"disable_gpu_acceleration": "Disable GPU Acceleration",
|
"disable_gpu_acceleration": "Disable GPU Acceleration",
|
||||||
"disable_gpu_acceleration_tooltip": "Only change this option if you know what you're doing, may fix issues with UI, requires restarting VRCX",
|
"disable_gpu_acceleration_tooltip": "Only change this option if you know what you're doing, breaks SteamVR overlay, may fix issues with UI, requires restarting VRCX",
|
||||||
"proxy": "Proxy settings"
|
"proxy": "Proxy settings"
|
||||||
},
|
},
|
||||||
"favorites": {
|
"favorites": {
|
||||||
|
|||||||
@@ -20,7 +20,8 @@ mixin previousInstances()
|
|||||||
template(v-once #default="scope")
|
template(v-once #default="scope")
|
||||||
el-button(type="text" icon="el-icon-info" size="mini" @click="showLaunchDialog(scope.row.location)")
|
el-button(type="text" icon="el-icon-info" size="mini" @click="showLaunchDialog(scope.row.location)")
|
||||||
el-button(type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
el-button(type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
||||||
el-button(type="text" icon="el-icon-close" size="mini" @click="confirmDeleteGameLogUserInstance(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c" type="text" icon="el-icon-close" size="mini" @click="deleteGameLogUserInstance(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-close" size="mini" @click="deleteGameLogUserInstancePrompt(scope.row)")
|
||||||
|
|
||||||
//- dialog Table: Previous Instances World
|
//- dialog Table: Previous Instances World
|
||||||
el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" ref="previousInstancesWorldDialog" :visible.sync="previousInstancesWorldDialog.visible" :title="$t('dialog.previous_instances.header')" width="1000px")
|
el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" ref="previousInstancesWorldDialog" :visible.sync="previousInstancesWorldDialog.visible" :title="$t('dialog.previous_instances.header')" width="1000px")
|
||||||
@@ -42,7 +43,8 @@ mixin previousInstances()
|
|||||||
el-table-column(:label="$t('table.previous_instances.action')" width="90" align="right")
|
el-table-column(:label="$t('table.previous_instances.action')" width="90" align="right")
|
||||||
template(v-once #default="scope")
|
template(v-once #default="scope")
|
||||||
el-button(type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
el-button(type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
||||||
el-button(type="text" icon="el-icon-close" size="mini" @click="confirmDeleteGameLogWorldInstance(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c" type="text" icon="el-icon-close" size="mini" @click="deleteGameLogWorldInstance(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-close" size="mini" @click="deleteGameLogWorldInstancePrompt(scope.row)")
|
||||||
|
|
||||||
//- dialog Table: Previous Instance Info
|
//- dialog Table: Previous Instance Info
|
||||||
el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" ref="previousInstanceInfoDialog" :visible.sync="previousInstanceInfoDialog.visible" :title="$t('dialog.previous_instances.info')" width="800px")
|
el-dialog.x-dialog(:before-close="beforeDialogClose" @mousedown.native="dialogMouseDown" @mouseup.native="dialogMouseUp" ref="previousInstanceInfoDialog" :visible.sync="previousInstanceInfoDialog.visible" :title="$t('dialog.previous_instances.info')" width="800px")
|
||||||
|
|||||||
@@ -18,4 +18,5 @@ mixin friendLogTab()
|
|||||||
span ({{ scope.row.previousTrustLevel }} #[i.el-icon-right] {{ scope.row.trustLevel }})
|
span ({{ scope.row.previousTrustLevel }} #[i.el-icon-right] {{ scope.row.trustLevel }})
|
||||||
el-table-column(:label="$t('table.friendLog.action')" width="80" align="right")
|
el-table-column(:label="$t('table.friendLog.action')" width="80" align="right")
|
||||||
template(v-once #default="scope")
|
template(v-once #default="scope")
|
||||||
el-button(type="text" icon="el-icon-delete" size="mini" @click="deleteFriendLog(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c" type="text" icon="el-icon-close" size="mini" @click="deleteFriendLog(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-delete" size="mini" @click="deleteFriendLogPrompt(scope.row)")
|
||||||
|
|||||||
@@ -47,6 +47,8 @@ mixin gameLogTab()
|
|||||||
span.x-link(v-else v-text="scope.row.data")
|
span.x-link(v-else v-text="scope.row.data")
|
||||||
el-table-column(:label="$t('table.gameLog.action')" width="80" align="right")
|
el-table-column(:label="$t('table.gameLog.action')" width="80" align="right")
|
||||||
template(v-once #default="scope")
|
template(v-once #default="scope")
|
||||||
el-button(v-if="scope.row.type !== 'OnPlayerJoined' && scope.row.type !== 'OnPlayerLeft' && scope.row.type !== 'Location' && scope.row.type !== 'PortalSpawn'" type="text" icon="el-icon-delete" size="mini" @click="deleteGameLogEntryPrompt(scope.row)")
|
template(v-if="scope.row.type !== 'OnPlayerJoined' && scope.row.type !== 'OnPlayerLeft' && scope.row.type !== 'Location' && scope.row.type !== 'PortalSpawn'")
|
||||||
|
el-button(v-if="shiftHeld" style="color:#f56c6c" type="text" icon="el-icon-close" size="mini" @click="deleteGameLogEntry(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-delete" size="mini" @click="deleteGameLogEntryPrompt(scope.row)")
|
||||||
el-tooltip(placement="top" content="Open Instance Info" :disabled="hideTooltips")
|
el-tooltip(placement="top" content="Open Instance Info" :disabled="hideTooltips")
|
||||||
el-button(v-if="scope.row.type === 'Location'" type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
el-button(v-if="scope.row.type === 'Location'" type="text" icon="el-icon-tickets" size="mini" @click="showPreviousInstanceInfoDialog(scope.row.location)")
|
||||||
|
|||||||
@@ -23,4 +23,6 @@ mixin moderationTab()
|
|||||||
span.x-link(v-text="scope.row.targetDisplayName" @click="showUserDialog(scope.row.targetUserId)")
|
span.x-link(v-text="scope.row.targetDisplayName" @click="showUserDialog(scope.row.targetUserId)")
|
||||||
el-table-column(:label="$t('table.moderation.action')" width="80" align="right")
|
el-table-column(:label="$t('table.moderation.action')" width="80" align="right")
|
||||||
template(v-once #default="scope")
|
template(v-once #default="scope")
|
||||||
el-button(v-if="scope.row.sourceUserId === API.currentUser.id" type="text" icon="el-icon-close" size="mini" @click="deletePlayerModeration(scope.row)")
|
template(v-if="scope.row.sourceUserId === API.currentUser.id")
|
||||||
|
el-button(v-if="shiftHeld" style="color:#f56c6c" type="text" icon="el-icon-close" size="mini" @click="deletePlayerModeration(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-close" size="mini" @click="deletePlayerModerationPrompt(scope.row)")
|
||||||
|
|||||||
@@ -84,10 +84,13 @@ mixin notificationsTab()
|
|||||||
el-button(v-else type="text" icon="el-icon-collection-tag" size="mini" style="margin-left:5px" @click="sendNotificationResponse(scope.row.id, scope.row.responses, response.type)")
|
el-button(v-else type="text" icon="el-icon-collection-tag" size="mini" style="margin-left:5px" @click="sendNotificationResponse(scope.row.id, scope.row.responses, response.type)")
|
||||||
template(v-if="scope.row.type !== 'requestInviteResponse' && scope.row.type !== 'inviteResponse' && scope.row.type !== 'message' && scope.row.type !== 'boop' && scope.row.type !== 'groupChange' && !scope.row.type.includes('group.') && !scope.row.type.includes('moderation.') && !scope.row.type.includes('instance.')")
|
template(v-if="scope.row.type !== 'requestInviteResponse' && scope.row.type !== 'inviteResponse' && scope.row.type !== 'message' && scope.row.type !== 'boop' && scope.row.type !== 'groupChange' && !scope.row.type.includes('group.') && !scope.row.type.includes('moderation.') && !scope.row.type.includes('instance.')")
|
||||||
el-tooltip(placement="top" content="Decline" :disabled="hideTooltips")
|
el-tooltip(placement="top" content="Decline" :disabled="hideTooltips")
|
||||||
el-button(type="text" icon="el-icon-close" size="mini" style="margin-left:5px" @click="hideNotification(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c;margin-left:5px" type="text" icon="el-icon-close" size="mini" @click="hideNotification(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-close" size="mini" style="margin-left:5px" @click="hideNotificationPrompt(scope.row)")
|
||||||
template(v-if="scope.row.type === 'group.queueReady'")
|
template(v-if="scope.row.type === 'group.queueReady'")
|
||||||
el-tooltip(placement="top" content="Delete log" :disabled="hideTooltips")
|
el-tooltip(placement="top" content="Delete log" :disabled="hideTooltips")
|
||||||
el-button(type="text" icon="el-icon-delete" size="mini" style="margin-left:5px" @click="deleteNotificationLog(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c;margin-left:5px" type="text" icon="el-icon-close" size="mini" @click="deleteNotificationLog(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-delete" size="mini" style="margin-left:5px" @click="deleteNotificationLogPrompt(scope.row)")
|
||||||
template(v-if="scope.row.type !== 'friendRequest' && scope.row.type !== 'ignoredFriendRequest' && !scope.row.type.includes('group.') && !scope.row.type.includes('moderation.')")
|
template(v-if="scope.row.type !== 'friendRequest' && scope.row.type !== 'ignoredFriendRequest' && !scope.row.type.includes('group.') && !scope.row.type.includes('moderation.')")
|
||||||
el-tooltip(placement="top" content="Delete log" :disabled="hideTooltips")
|
el-tooltip(placement="top" content="Delete log" :disabled="hideTooltips")
|
||||||
el-button(type="text" icon="el-icon-delete" size="mini" style="margin-left:5px" @click="deleteNotificationLog(scope.row)")
|
el-button(v-if="shiftHeld" style="color:#f56c6c;margin-left:5px" type="text" icon="el-icon-close" size="mini" @click="deleteNotificationLog(scope.row)")
|
||||||
|
el-button(v-else type="text" icon="el-icon-delete" size="mini" style="margin-left:5px" @click="deleteNotificationLogPrompt(scope.row)")
|
||||||
|
|||||||
Reference in New Issue
Block a user