void CONSOLE_OT_history_append(wmOperatorType *ot) { /* identifiers */ ot->name= "History Append"; ot->description= "Append history at cursor position"; ot->idname= "CONSOLE_OT_history_append"; /* api callbacks */ ot->exec= history_append_exec; ot->poll= ED_operator_console_active; /* properties */ RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); RNA_def_int(ot->srna, "current_character", 0, 0, INT_MAX, "Cursor", "The index of the cursor.", 0, 10000); RNA_def_boolean(ot->srna, "remove_duplicates", 0, "Remove Duplicates", "Remove duplicate items in the history"); }
void LATTICE_OT_select_ungrouped(wmOperatorType *ot) { /* identifiers */ ot->name = "Select Ungrouped"; ot->idname = "LATTICE_OT_select_ungrouped"; ot->description = "Select vertices without a group"; /* api callbacks */ ot->exec = lattice_select_ungrouped_exec; ot->poll = ED_operator_editlattice; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "extend", false, "Extend", "Extend the selection"); }
void PTCACHE_OT_bake(wmOperatorType *ot) { /* identifiers */ ot->name = "Bake Physics"; ot->description = "Bake physics"; ot->idname = "PTCACHE_OT_bake"; /* api callbacks */ ot->exec = ptcache_bake_exec; ot->poll = ptcache_poll; /* flags */ ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; RNA_def_boolean(ot->srna, "bake", 0, "Bake", ""); }
static void GRAPH_OT_reveal(wmOperatorType *ot) { /* identifiers */ ot->name = "Reveal Curves"; ot->idname = "GRAPH_OT_reveal"; ot->description = "Make previously hidden curves visible again in Graph Editor view"; /* api callbacks */ ot->exec = graphview_curves_reveal_exec; ot->poll = ED_operator_graphedit_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "select", true, "Select", ""); }
void MASK_OT_hide_view_set(wmOperatorType *ot) { /* identifiers */ ot->name = "Set Restrict View"; ot->description = "Hide the layer by setting the hide flag"; ot->idname = "MASK_OT_hide_view_set"; /* api callbacks */ ot->exec = mask_hide_view_set_exec; ot->poll = ED_maskedit_mask_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected layers"); }
void PAINT_OT_vert_select_ungrouped(wmOperatorType *ot) { /* identifiers */ ot->name = "Select Ungrouped"; ot->idname = "PAINT_OT_vert_select_ungrouped"; ot->description = "Select vertices without a group"; /* api callbacks */ ot->exec = vert_select_ungrouped_exec; ot->poll = vert_paint_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "extend", false, "Extend", "Extend the selection"); }
static void BRUSH_OT_stencil_reset_transform(wmOperatorType *ot) { /* identifiers */ ot->name = "Reset Transform"; ot->description = "Reset the stencil transformation to the default"; ot->idname = "BRUSH_OT_stencil_reset_transform"; /* api callbacks */ ot->exec = stencil_reset_transform_exec; ot->poll = stencil_control_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "mask", 0, "Modify Mask Stencil", "Modify either the primary or mask stencil"); }
void NODE_OT_group_edit(wmOperatorType *ot) { /* identifiers */ ot->name = "Edit Group"; ot->description = "Edit node group"; ot->idname = "NODE_OT_group_edit"; /* api callbacks */ ot->exec = node_group_edit_exec; ot->poll = node_group_operator_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "exit", false, "Exit", ""); }
void MASK_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ ot->name = "Select Linked"; ot->idname = "MASK_OT_select_linked_pick"; ot->description = "(De)select all points linked to the curve under the mouse cursor"; /* api callbacks */ ot->invoke = mask_select_linked_pick_invoke; ot->poll = ED_maskedit_mask_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", ""); }
void OUTLINER_OT_show_one_level(wmOperatorType *ot) { /* identifiers */ ot->name = "Show/Hide One Level"; ot->idname = "OUTLINER_OT_show_one_level"; ot->description = "Expand/collapse all entries by one level"; /* callbacks */ ot->exec = outliner_one_level_exec; ot->poll = ED_operator_outliner_active; /* no undo or registry, UI option */ /* properties */ RNA_def_boolean(ot->srna, "open", 1, "Open", "Expand all entries one level deep"); }
void SCREEN_OT_screencast(wmOperatorType *ot) { ot->name = "Make Screencast"; ot->idname = "SCREEN_OT_screencast"; ot->description = "Capture a video of the active area or whole Blender window"; ot->invoke = WM_operator_confirm; ot->exec = screencast_exec; ot->poll = screenshot_poll; /* shared poll */ ot->flag = 0; RNA_def_property(ot->srna, "filepath", PROP_STRING, PROP_FILEPATH); RNA_def_boolean(ot->srna, "full", 1, "Full Screen", "Capture the whole window (otherwise only capture the active area)"); }
void CURVE_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ ot->name = "Select Linked"; ot->idname = "CURVE_OT_select_linked_pick"; ot->description = "Select all control points linked to already selected ones"; /* api callbacks */ ot->invoke = select_linked_pick_invoke; ot->poll = ED_operator_editsurfcurve_region_view3d; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", "Deselect linked control points rather than selecting them"); }
void GRAPH_OT_select_all_toggle(wmOperatorType *ot) { /* identifiers */ ot->name = "Select All"; ot->idname = "GRAPH_OT_select_all_toggle"; ot->description = "Toggle selection of all keyframes"; /* api callbacks */ ot->exec = graphkeys_deselectall_exec; ot->poll = graphop_visible_keyframes_poll; /* flags */ ot->flag = OPTYPE_REGISTER /*|OPTYPE_UNDO*/; /* props */ ot->prop = RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); }
void OBJECT_OT_shape_key_add(wmOperatorType *ot) { /* identifiers */ ot->name= "Add Shape Key"; ot->idname= "OBJECT_OT_shape_key_add"; ot->description= "Add shape key to the object"; /* api callbacks */ ot->poll= shape_key_mode_poll; ot->exec= shape_key_add_exec; /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "from_mix", 1, "From Mix", "Create the new shape key from the existing mix of keys."); }
void RNA_def_main_sounds(BlenderRNA *brna, PropertyRNA *cprop) { StructRNA *srna; FunctionRNA *func; PropertyRNA *parm; RNA_def_property_srna(cprop, "BlendDataSounds"); srna= RNA_def_struct(brna, "BlendDataSounds", NULL); RNA_def_struct_sdna(srna, "Main"); RNA_def_struct_ui_text(srna, "Main Sounds", "Collection of sounds"); /* TODO, 'load' */ func= RNA_def_function(srna, "tag", "rna_Main_sounds_tag"); parm= RNA_def_boolean(func, "value", 0, "Value", ""); RNA_def_property_flag(parm, PROP_REQUIRED); }
static void UI_OT_reset_default_button(wmOperatorType *ot) { /* identifiers */ ot->name= "Reset to Default Value"; ot->idname= "UI_OT_reset_default_button"; ot->description= "Reset this property's value to its default value"; /* callbacks */ ot->poll= reset_default_button_poll; ot->exec= reset_default_button_exec; /* flags */ ot->flag= OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array"); }
void NODE_OT_find_node(wmOperatorType *ot) { /* identifiers */ ot->name = "Find Node"; ot->description = "Search for named node and allow to select and activate it"; ot->idname = "NODE_OT_find_node"; /* api callbacks */ ot->invoke = node_find_node_invoke; ot->poll = ED_operator_node_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "prev", 0, "Previous", ""); }
void MASK_OT_slide_point(wmOperatorType *ot) { /* identifiers */ ot->name = "Slide Point"; ot->description = "Slide control points"; ot->idname = "MASK_OT_slide_point"; /* api callbacks */ ot->invoke = slide_point_invoke; ot->modal = slide_point_modal; ot->poll = ED_maskedit_mask_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "slide_feather", 0, "Slide Feather", "First try to slide feather instead of vertex"); }
void ANIM_OT_keyingset_button_add(wmOperatorType *ot) { /* identifiers */ ot->name = "Add to Keying Set"; ot->idname = "ANIM_OT_keyingset_button_add"; ot->description = "Add current UI-active property to current keying set"; /* callbacks */ ot->exec = add_keyingset_button_exec; //op->poll = ??? /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "all", 1, "All", "Add all elements of the array to a Keying Set"); }
void ANIM_OT_driver_button_remove(wmOperatorType *ot) { /* identifiers */ ot->name = "Remove Driver"; ot->idname = "ANIM_OT_driver_button_remove"; ot->description = "Remove the driver(s) for the property(s) connected represented by the highlighted button"; /* callbacks */ ot->exec = remove_driver_button_exec; //op->poll = ??? // TODO: need to have some driver to be able to do this... /* flags */ ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; /* properties */ RNA_def_boolean(ot->srna, "all", 1, "All", "Delete drivers for all elements of the array"); }
void ARMATURE_OT_extrude(wmOperatorType *ot) { /* identifiers */ ot->name = "Extrude"; ot->idname = "ARMATURE_OT_extrude"; ot->description = "Create new bones from the selected joints"; /* api callbacks */ ot->exec = armature_extrude_exec; ot->poll = ED_operator_editarmature; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* props */ RNA_def_boolean(ot->srna, "forked", 0, "Forked", ""); }
static void UI_OT_override_remove_button(wmOperatorType *ot) { /* identifiers */ ot->name = "Remove Override"; ot->idname = "UI_OT_override_remove_button"; ot->description = "Remove an override operation"; /* callbacks */ ot->poll = override_remove_button_poll; ot->exec = override_remove_button_exec; /* flags */ ot->flag = OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array"); }
void VIEW3D_OT_snap_selected_to_cursor(wmOperatorType *ot) { /* identifiers */ ot->name = "Snap Selection to Cursor"; ot->description = "Snap selected item(s) to cursor"; ot->idname = "VIEW3D_OT_snap_selected_to_cursor"; /* api callbacks */ ot->exec = snap_selected_to_cursor_exec; ot->poll = ED_operator_view3d_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* rna */ RNA_def_boolean(ot->srna, "use_offset", 1, "Offset", ""); }
void NLA_OT_tracks_add(wmOperatorType *ot) { /* identifiers */ ot->name = "Add Tracks"; ot->idname = "NLA_OT_tracks_add"; ot->description = "Add NLA-Tracks above/after the selected tracks"; /* api callbacks */ ot->exec = nlaedit_add_tracks_exec; ot->poll = nlaop_poll_tweakmode_off; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "above_selected", 0, "Above Selected", "Add a new NLA Track above every existing selected one"); }
void MBALL_OT_hide_metaelems(wmOperatorType *ot) { /* identifiers */ ot->name = "Hide"; ot->description = "Hide (un)selected metaelement(s)"; ot->idname = "MBALL_OT_hide_metaelems"; /* callback functions */ ot->exec = hide_metaelems_exec; ot->poll = ED_operator_editmball; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* props */ RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected"); }
void OBJECT_OT_shape_key_remove(wmOperatorType *ot) { /* identifiers */ ot->name = "Remove Shape Key"; ot->idname = "OBJECT_OT_shape_key_remove"; ot->description = "Remove Shape Key\nRemove shape key from the object"; /* api callbacks */ ot->poll = shape_key_mode_exists_poll; ot->exec = shape_key_remove_exec; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "all", 0, "All", "Remove all shape keys"); }
void NODE_OT_select_same_type_step(wmOperatorType *ot) { /* identifiers */ ot->name = "Activate Same Type Next/Prev"; ot->description = "Activate and view same node type, step by step"; ot->idname = "NODE_OT_select_same_type_step"; /* api callbacks */ ot->exec = node_select_same_type_step_exec; ot->poll = ED_operator_node_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; RNA_def_boolean(ot->srna, "prev", 0, "Previous", ""); }
void NLA_OT_select_all_toggle(wmOperatorType *ot) { /* identifiers */ ot->name = "(De)select All"; ot->idname = "NLA_OT_select_all_toggle"; ot->description = "Select or deselect all NLA-Strips"; /* api callbacks */ ot->exec = nlaedit_deselectall_exec; ot->poll = nlaop_poll_tweakmode_off; /* flags */ ot->flag = OPTYPE_REGISTER /*|OPTYPE_UNDO*/; /* props */ RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); }
static void UI_OT_copy_to_selected_button(wmOperatorType *ot) { /* identifiers */ ot->name= "Copy To Selected"; ot->idname= "UI_OT_copy_to_selected_button"; ot->description= "Copy property from this object to selected objects or bones"; /* callbacks */ ot->poll= copy_to_selected_button_poll; ot->exec= copy_to_selected_button_exec; /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array"); }
void NLA_OT_click_select(wmOperatorType *ot) { /* identifiers */ ot->name = "Mouse Select"; ot->idname = "NLA_OT_click_select"; ot->description = "Handle clicks to select NLA Strips"; /* api callbacks - absolutely no exec() this yet... */ ot->invoke = nlaedit_clickselect_invoke; ot->poll = ED_operator_nla_active; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* id-props */ RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY }