Fix #1343 mark animation as unsaved when renaming bone
Implement #1336 Implement #1228 Add convert to mesh to right-click menu Fix #1346 Duplicate in group menu in animation mode
This commit is contained in:
parent
48d514d83d
commit
ab79360e70
@ -1705,7 +1705,7 @@ const BARS = {
|
||||
new Action('duplicate', {
|
||||
icon: 'content_copy',
|
||||
category: 'edit',
|
||||
condition: () => (Animation.selected && Modes.animate) || (Modes.edit && (selected.length || Group.selected)),
|
||||
condition: () => (Animation.selected && Modes.animate && Prop.active_panel == 'animations') || (Modes.edit && (selected.length || Group.selected)),
|
||||
keybind: new Keybind({key: 'd', ctrl: true}),
|
||||
click: function () {
|
||||
if (Modes.animate) {
|
||||
|
@ -723,11 +723,8 @@ class Cube extends OutlinerElement {
|
||||
Cube.prototype.menu = new Menu([
|
||||
...Outliner.control_menu_group,
|
||||
'_',
|
||||
'copy',
|
||||
'paste',
|
||||
'duplicate',
|
||||
'_',
|
||||
'rename',
|
||||
'convert_to_mesh',
|
||||
'update_autouv',
|
||||
{name: 'menu.cube.color', icon: 'color_lens', children: markerColors.map((color, i) => {return {
|
||||
icon: 'bubble_chart',
|
||||
|
@ -247,6 +247,11 @@ class OutlinerNode {
|
||||
scope.name = scope.old_name;
|
||||
if (scope.type === 'group') {
|
||||
Undo.initEdit({outliner: true})
|
||||
Animation.all.forEach(animation => {
|
||||
if (animation.animators[scope.uuid] && animation.animators[scope.uuid].keyframes.length) {
|
||||
animation.saved = false;
|
||||
}
|
||||
})
|
||||
} else {
|
||||
Undo.initEdit({elements: [scope]})
|
||||
}
|
||||
@ -1038,16 +1043,27 @@ BARS.defineActions(function() {
|
||||
markerColors.forEach((color, i) => {
|
||||
color_options[i] = 'cube.color.' + color.name;
|
||||
})
|
||||
let dialog = new Dialog({
|
||||
let type_options = {
|
||||
all: 'generic.all'
|
||||
};
|
||||
for (let type in OutlinerElement.types) {
|
||||
type_options[type] = tl(`data.${type}`);
|
||||
if (type_options[type].includes('.')) {
|
||||
type_options[type] = OutlinerElement.types[type].display_name || OutlinerElement.types[type].name;
|
||||
}
|
||||
}
|
||||
new Dialog({
|
||||
id: 'selection_creator',
|
||||
title: 'dialog.select.title',
|
||||
form_first: true,
|
||||
form: {
|
||||
new: {label: 'dialog.select.new', type: 'checkbox', value: true},
|
||||
group: {label: 'dialog.select.group', type: 'checkbox'},
|
||||
separate: '_',
|
||||
name: {label: 'dialog.select.name', type: 'text'},
|
||||
type: {label: 'dialog.select.type', type: 'select', options: type_options},
|
||||
color: {label: 'menu.cube.color', type: 'select', value: '-1', options: color_options},
|
||||
texture: {label: 'data.texture', type: 'text', list: Texture.all.map(tex => tex.name)},
|
||||
color: {label: 'menu.cube.color', type: 'select', value: '-1', options: color_options}
|
||||
},
|
||||
lines: [
|
||||
`<div class="dialog_bar form_bar">
|
||||
@ -1073,6 +1089,7 @@ BARS.defineActions(function() {
|
||||
}
|
||||
|
||||
array.forEach(function(obj) {
|
||||
if (obj.type !== formData.type && formData.type !== 'all') return;
|
||||
if (obj.name.toUpperCase().includes(name_seg) === false) return;
|
||||
if (obj.faces && tex_seg && !Format.single_texture) {
|
||||
var has_tex = false;
|
||||
|
@ -1626,7 +1626,7 @@ BARS.defineActions(function() {
|
||||
new Action('append_to_template', {
|
||||
icon: 'dashboard_customize',
|
||||
category: 'textures',
|
||||
condition: () => Texture.all.length,
|
||||
condition: () => Texture.all.length && (Cube.selected.length || Mesh.selected.length),
|
||||
click() {
|
||||
TextureGenerator.appendToTemplateDialog()
|
||||
}
|
||||
|
@ -18,6 +18,7 @@
|
||||
"data.locator": "Locator",
|
||||
"data.null_object": "Null Object",
|
||||
"data.mesh": "Mesh",
|
||||
"data.texture_mesh": "Texture Mesh",
|
||||
"data.group": "Group",
|
||||
"data.texture": "Texture",
|
||||
"data.origin": "Pivot",
|
||||
@ -356,6 +357,7 @@
|
||||
"dialog.select.new": "New Selection",
|
||||
"dialog.select.group": "In Selected Group",
|
||||
"dialog.select.name": "Name Contains",
|
||||
"dialog.select.type": "Element Type",
|
||||
"dialog.select.random": "Random",
|
||||
"dialog.select.select": "Select",
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user