mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-07 06:56:04 +02:00
Clean up and fix avatar dialog "Share" button
This commit is contained in:
+16
-14
@@ -1436,25 +1436,30 @@ console.log(`isLinux: ${LINUX}`);
|
|||||||
var ref = this.cachedAvatars.get(json.id);
|
var ref = this.cachedAvatars.get(json.id);
|
||||||
if (typeof ref === 'undefined') {
|
if (typeof ref === 'undefined') {
|
||||||
ref = {
|
ref = {
|
||||||
id: '',
|
acknowledgements: '',
|
||||||
name: '',
|
|
||||||
description: '',
|
|
||||||
authorId: '',
|
authorId: '',
|
||||||
authorName: '',
|
authorName: '',
|
||||||
tags: [],
|
created_at: '',
|
||||||
assetUrl: '',
|
description: '',
|
||||||
assetUrlObject: {},
|
featured: false,
|
||||||
|
highestPrice: null,
|
||||||
|
id: '',
|
||||||
imageUrl: '',
|
imageUrl: '',
|
||||||
thumbnailImageUrl: '',
|
lock: false,
|
||||||
|
lowestPrice: null,
|
||||||
|
name: '',
|
||||||
|
productId: null,
|
||||||
|
publishedListings: [],
|
||||||
releaseStatus: '',
|
releaseStatus: '',
|
||||||
|
searchable: false,
|
||||||
styles: [],
|
styles: [],
|
||||||
version: 0,
|
tags: [],
|
||||||
unityPackages: [],
|
thumbnailImageUrl: '',
|
||||||
unityPackageUrl: '',
|
unityPackageUrl: '',
|
||||||
unityPackageUrlObject: {},
|
unityPackageUrlObject: {},
|
||||||
created_at: '',
|
unityPackages: [],
|
||||||
updated_at: '',
|
updated_at: '',
|
||||||
featured: false,
|
version: 0,
|
||||||
...json
|
...json
|
||||||
};
|
};
|
||||||
this.cachedAvatars.set(ref.id, ref);
|
this.cachedAvatars.set(ref.id, ref);
|
||||||
@@ -13841,14 +13846,11 @@ console.log(`isLinux: ${LINUX}`);
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
//
|
|
||||||
|
|
||||||
$app.methods.languageClass = function (key) {
|
$app.methods.languageClass = function (key) {
|
||||||
return languageClass(key);
|
return languageClass(key);
|
||||||
};
|
};
|
||||||
|
|
||||||
// #endregion
|
// #endregion
|
||||||
|
|
||||||
// #region | Electron
|
// #region | Electron
|
||||||
|
|
||||||
if (LINUX) {
|
if (LINUX) {
|
||||||
|
|||||||
@@ -228,6 +228,7 @@ export default class extends baseClass {
|
|||||||
hideContentFilterSettings: false,
|
hideContentFilterSettings: false,
|
||||||
homeLocation: '',
|
homeLocation: '',
|
||||||
id: '',
|
id: '',
|
||||||
|
isAdult: true,
|
||||||
isBoopingEnabled: false,
|
isBoopingEnabled: false,
|
||||||
isFriend: false,
|
isFriend: false,
|
||||||
last_activity: '',
|
last_activity: '',
|
||||||
|
|||||||
@@ -696,7 +696,7 @@
|
|||||||
showAvatarDialog(D.id);
|
showAvatarDialog(D.id);
|
||||||
break;
|
break;
|
||||||
case 'Share':
|
case 'Share':
|
||||||
copyToClipboard(D.id);
|
copyAvatarUrl(D.id);
|
||||||
break;
|
break;
|
||||||
case 'Rename':
|
case 'Rename':
|
||||||
promptRenameAvatar(D);
|
promptRenameAvatar(D);
|
||||||
@@ -1057,9 +1057,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!assetUrl) {
|
|
||||||
assetUrl = D.ref.assetUrl;
|
|
||||||
}
|
|
||||||
const fileId = extractFileId(assetUrl);
|
const fileId = extractFileId(assetUrl);
|
||||||
const version = parseInt(extractFileVersion(assetUrl), 10);
|
const version = parseInt(extractFileVersion(assetUrl), 10);
|
||||||
if (!fileId || !version) {
|
if (!fileId || !version) {
|
||||||
|
|||||||
@@ -112,9 +112,6 @@ async function checkVRChatCache(ref) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!assetUrl) {
|
|
||||||
assetUrl = ref.assetUrl;
|
|
||||||
}
|
|
||||||
var id = extractFileId(assetUrl);
|
var id = extractFileId(assetUrl);
|
||||||
var version = parseInt(extractFileVersion(assetUrl), 10);
|
var version = parseInt(extractFileVersion(assetUrl), 10);
|
||||||
var variantVersion = parseInt(extractVariantVersion(assetUrl), 10);
|
var variantVersion = parseInt(extractVariantVersion(assetUrl), 10);
|
||||||
@@ -266,8 +263,6 @@ async function getBundleLocation(input) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if ($app.avatarDialog.visible && $app.avatarDialog.ref.assetUrl) {
|
|
||||||
assetUrl = $app.avatarDialog.ref.assetUrl;
|
|
||||||
} else if (
|
} else if (
|
||||||
$app.worldDialog.visible &&
|
$app.worldDialog.visible &&
|
||||||
$app.worldDialog.ref.unityPackages.length > 0
|
$app.worldDialog.ref.unityPackages.length > 0
|
||||||
@@ -283,8 +278,6 @@ async function getBundleLocation(input) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if ($app.worldDialog.visible && $app.worldDialog.ref.assetUrl) {
|
|
||||||
assetUrl = $app.worldDialog.ref.assetUrl;
|
|
||||||
}
|
}
|
||||||
if (!assetUrl) {
|
if (!assetUrl) {
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
Reference in New Issue
Block a user