Manager: allow setup to finish without Blender #104306
@ -101,9 +101,7 @@
|
|||||||
v-show="currentSetupStep == 3"
|
v-show="currentSetupStep == 3"
|
||||||
@next-clicked="nextStepAfterCheckBlenderExePath"
|
@next-clicked="nextStepAfterCheckBlenderExePath"
|
||||||
@back-clicked="prevStep"
|
@back-clicked="prevStep"
|
||||||
:is-next-clickable="
|
:is-next-clickable="selectedBlender != null || customBlenderExe != ''"
|
||||||
selectedBlender != null || customBlenderExe != '' || skipCustomBlenderExe
|
|
||||||
"
|
|
||||||
title="Blender">
|
title="Blender">
|
||||||
abelli marked this conversation as resolved
Outdated
|
|||||||
<div v-if="isBlenderExeFinding" class="is-in-progress">Looking for Blender installs...</div>
|
<div v-if="isBlenderExeFinding" class="is-in-progress">Looking for Blender installs...</div>
|
||||||
|
|
||||||
@ -196,15 +194,15 @@
|
|||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<fieldset v-if="autoFoundBlenders.length === 0">
|
<fieldset v-if="autoFoundBlenders.length === 0">
|
||||||
<label for="custom_blender-input_path">
|
<label for="blender-input_path">
|
||||||
<div>
|
<div>
|
||||||
<input
|
<input
|
||||||
v-model="skipCustomBlenderExe"
|
|
||||||
value="false"
|
|
||||||
type="radio"
|
type="radio"
|
||||||
|
v-model="selectedBlender"
|
||||||
name="blender"
|
name="blender"
|
||||||
id="custom_blender-input_path" />
|
:value="blenderFromInputPath"
|
||||||
I have a Blender path:
|
id="blender-input_path" />
|
||||||
|
{{ sourceLabels['input_path'] }}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<input
|
<input
|
||||||
@ -225,15 +223,15 @@
|
|||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
|
|
||||||
<label for="skip_blender-input_path">
|
<label for="blender-default">
|
||||||
<div>
|
<div>
|
||||||
<input
|
<input
|
||||||
v-model="skipCustomBlenderExe"
|
|
||||||
value="true"
|
|
||||||
type="radio"
|
type="radio"
|
||||||
|
v-model="selectedBlender"
|
||||||
name="blender"
|
name="blender"
|
||||||
id="skip_blender-input_path" />
|
:value="blenderFromDefaultSource"
|
||||||
Skip, let the Workers use whatever Blender is available.
|
id="blender-default" />
|
||||||
|
{{ sourceLabels['default'] }}
|
||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
@ -263,11 +261,11 @@
|
|||||||
>" as found on <code>$PATH</code> (currently "<code>{{ selectedBlender.path }}</code
|
>" as found on <code>$PATH</code> (currently "<code>{{ selectedBlender.path }}</code
|
||||||
>")
|
>")
|
||||||
</dd>
|
</dd>
|
||||||
<dd v-if="selectedBlender.source == 'input_path' && !skipCustomBlenderExe">
|
<dd v-if="selectedBlender.source == 'input_path'">
|
||||||
The command you provided: "<code>{{ selectedBlender.path }}</code
|
The command you provided: "<code>{{ selectedBlender.path }}</code
|
||||||
>"
|
>"
|
||||||
</dd>
|
</dd>
|
||||||
<dd v-if="selectedBlender.source == 'input_path' && skipCustomBlenderExe">
|
<dd v-if="selectedBlender.source == 'default'">
|
||||||
You have choosen to skip adding a blender path.
|
You have choosen to skip adding a blender path.
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
@ -316,13 +314,13 @@ export default {
|
|||||||
selectedBlender: null, // the chosen api.BlenderPathCheckResult
|
selectedBlender: null, // the chosen api.BlenderPathCheckResult
|
||||||
|
|
||||||
customBlenderExe: '',
|
customBlenderExe: '',
|
||||||
skipCustomBlenderExe: false,
|
|
||||||
isBlenderExeChecking: false,
|
isBlenderExeChecking: false,
|
||||||
blenderExeCheckResult: null, // api.BlenderPathCheckResult
|
blenderExeCheckResult: null, // api.BlenderPathCheckResult
|
||||||
sourceLabels: {
|
sourceLabels: {
|
||||||
file_association: 'Blender that runs when you double-click a .blend file:',
|
file_association: 'Blender that runs when you double-click a .blend file:',
|
||||||
path_envvar: 'Blender found on the $PATH environment:',
|
path_envvar: 'Blender found on the $PATH environment:',
|
||||||
input_path: 'Another Blender executable:',
|
input_path: 'Specify a Blender executable:',
|
||||||
|
default: 'Skip, let the Workers use whatever Blender is available.',
|
||||||
},
|
},
|
||||||
isConfirming: false,
|
isConfirming: false,
|
||||||
isConfirmed: false,
|
isConfirmed: false,
|
||||||
@ -355,6 +353,15 @@ export default {
|
|||||||
blenderFromInputPath() {
|
blenderFromInputPath() {
|
||||||
return this.allBlenders.find((b) => b.source === 'input_path');
|
return this.allBlenders.find((b) => b.source === 'input_path');
|
||||||
},
|
},
|
||||||
|
blenderFromDefaultSource() {
|
||||||
|
return {
|
||||||
|
input: 'blender',
|
||||||
|
path: 'blender',
|
||||||
|
source: 'default',
|
||||||
|
is_usable: true,
|
||||||
|
cause: 'blender',
|
||||||
|
};
|
||||||
|
},
|
||||||
setupConfirmIsClickable() {
|
setupConfirmIsClickable() {
|
||||||
if (this.isConfirming || this.isConfirmed) {
|
if (this.isConfirming || this.isConfirmed) {
|
||||||
return false;
|
return false;
|
||||||
@ -418,17 +425,6 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
checkBlenderExePath() {
|
checkBlenderExePath() {
|
||||||
if (this.skipCustomBlenderExe) {
|
|
||||||
this.selectedBlender = {
|
|
||||||
input: 'blender',
|
|
||||||
path: 'blender',
|
|
||||||
source: 'input_path',
|
|
||||||
is_usable: true,
|
|
||||||
cause: 'blender',
|
|
||||||
};
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const exeToTry = this.cleanCustomBlenderExe;
|
const exeToTry = this.cleanCustomBlenderExe;
|
||||||
if (exeToTry == '') {
|
if (exeToTry == '') {
|
||||||
// Just erase any previously-found custom Blender executable.
|
// Just erase any previously-found custom Blender executable.
|
||||||
|
Loading…
Reference in New Issue
Block a user
That original code already won't work,
customBlenderExe != (null || '')
is not going to do what it's intended to express.null
is a false-y value, and so(null || '')
gets shortcut to just''
).That's not something to address in this PR though -- this PR adds a feature, and shouldn't also try and fix existing code. But if you're willing to look into this too, a separate PR that fixes this (which could then be landed before adding this new feature) would be much appreciated.
I have opened #104307 to address this one.