Fix overflow of autocomplete list in keyframe panel

Hide UV-related context menus in image editor
Update MolangJS, remove query functions that are now included in library
This commit is contained in:
JannisX11 2022-12-28 23:27:49 +01:00
parent ed3cbc7905
commit baafb8d326
4 changed files with 4 additions and 16 deletions

View File

@ -1378,7 +1378,7 @@ Interface.definePanels(function() {
</div>
</div>
<ul class="list">
<ul class="list" :style="{overflow: keyframes[0].data_points.length > 1 ? 'auto' : 'visible'}">
<div v-for="(data_point, data_point_i) of keyframes[0].data_points" class="keyframe_data_point">

View File

@ -66,18 +66,6 @@ Animator.MolangParser.global_variables = {
let distance = Preview.selected.camera.position.length() / 16;
return Math.clamp(Math.getLerp(a, b, distance), 0, 1);
},
'query.in_range'(value, min, max) {
return (value <= max && value >= min) ? 1 : 0;
},
'query.all'(value, ...to_compare) {
return to_compare.allAre(c => c == value) ? 1 : 0;
},
'query.any'(value, ...to_compare) {
return to_compare.findIndex(c => c == value) >= 0 ? 1 : 0;
},
'query.approx_eq'(value, ...to_compare) {
return to_compare.allAre(c => Math.epsilon(value, c, 0.0000001)) ? 1 : 0;
},
get 'time'() {
return Timeline.time;
}

View File

@ -1264,7 +1264,7 @@ const UVEditor = {
'zoom_out',
'zoom_reset'
]},
{name: 'menu.uv.display_uv', id: 'display_uv', icon: 'visibility', children: () => {
{name: 'menu.uv.display_uv', id: 'display_uv', icon: 'visibility', condition: () => (!Format.image_editor), children: () => {
let options = ['selected_faces', 'selected_elements', 'all_elements'];
return options.map(option => {return {
id: option,
@ -1652,7 +1652,7 @@ BARS.defineActions(function() {
new Toggle('paint_mode_uv_overlay', {
icon: 'splitscreen',
category: 'animation',
condition: {modes: ['paint']},
condition: {modes: ['paint'], method: () => !Format.image_editor},
onChange(value) {
UVEditor.vue.uv_overlay = value;
}

File diff suppressed because one or more lines are too long