Files
test2/source/blender/modifiers/intern/MOD_ui_common.hh
Sergey Sharybin c1bc70b711 Cleanup: Add a copyright notice to files and use SPDX format
A lot of files were missing copyright field in the header and
the Blender Foundation contributed to them in a sense of bug
fixing and general maintenance.

This change makes it explicit that those files are at least
partially copyrighted by the Blender Foundation.

Note that this does not make it so the Blender Foundation is
the only holder of the copyright in those files, and developers
who do not have a signed contract with the foundation still
hold the copyright as well.

Another aspect of this change is using SPDX format for the
header. We already used it for the license specification,
and now we state it for the copyright as well, following the
FAQ:

    https://reuse.software/faq/
2023-05-31 16:19:06 +02:00

59 lines
1.6 KiB
C++

/* SPDX-FileCopyrightText: 2023 Blender Foundation
*
* SPDX-License-Identifier: GPL-2.0-or-later */
/** \file
* \ingroup modifiers
*/
#pragma once
/* so modifier types match their defines */
#include "MOD_modifiertypes.hh"
#include "DEG_depsgraph_build.h"
struct ARegionType;
struct Panel;
struct PanelType;
struct PointerRNA;
struct bContext;
struct uiLayout;
using PanelDrawFn = void (*)(const bContext *, Panel *);
/**
* Helper function for modifier layouts to draw vertex group settings.
*/
void modifier_vgroup_ui(uiLayout *layout,
PointerRNA *ptr,
PointerRNA *ob_ptr,
const char *vgroup_prop,
const char *invert_vgroup_prop,
const char *text);
/**
* Draw modifier error message.
*/
void modifier_panel_end(uiLayout *layout, PointerRNA *ptr);
PointerRNA *modifier_panel_get_property_pointers(Panel *panel, PointerRNA *r_ob_ptr);
/**
* Create a panel in the context's region
*/
PanelType *modifier_panel_register(ARegionType *region_type, ModifierType type, PanelDrawFn draw);
/**
* Add a child panel to the parent.
*
* \note To create the panel type's #PanelType.idname,
* it appends the \a name argument to the \a parent's `idname`.
*/
PanelType *modifier_subpanel_register(ARegionType *region_type,
const char *name,
const char *label,
PanelDrawFn draw_header,
PanelDrawFn draw,
PanelType *parent);