svn merge -r39834:40222 https://svn.blender.org/svnroot/bf-blender/trunk/blender
This commit is contained in:
@@ -336,7 +336,7 @@ static void ui_layer_but_cb(bContext *C, void *arg_but, void *arg_index)
|
||||
}
|
||||
|
||||
/* create buttons for an item with an RNA array */
|
||||
static void ui_item_array(uiLayout *layout, uiBlock *block, const char *name, int icon, PointerRNA *ptr, PropertyRNA *prop, int len, int x, int y, int w, int h, int expand, int slider, int toggle, int icon_only)
|
||||
static void ui_item_array(uiLayout *layout, uiBlock *block, const char *name, int icon, PointerRNA *ptr, PropertyRNA *prop, int len, int x, int y, int w, int UNUSED(h), int expand, int slider, int toggle, int icon_only)
|
||||
{
|
||||
uiStyle *style= layout->root->style;
|
||||
uiBut *but;
|
||||
@@ -409,7 +409,7 @@ static void ui_item_array(uiLayout *layout, uiBlock *block, const char *name, in
|
||||
if (totdim != 2) return; /* only 2D matrices supported in UI so far */
|
||||
|
||||
w /= dim_size[0];
|
||||
h /= dim_size[1];
|
||||
/* h /= dim_size[1]; */ /* UNUSED */
|
||||
|
||||
for(a=0; a<len; a++) {
|
||||
col= a % dim_size[0];
|
||||
@@ -632,7 +632,7 @@ PointerRNA uiItemFullO(uiLayout *layout, const char *opname, const char *name, i
|
||||
|
||||
if(!ot) {
|
||||
ui_item_disabled(layout, opname);
|
||||
RNA_warning("uiItemFullO: unknown operator '%s'\n", opname);
|
||||
RNA_warning("unknown operator '%s'", opname);
|
||||
return PointerRNA_NULL;
|
||||
}
|
||||
|
||||
@@ -739,7 +739,7 @@ void uiItemsFullEnumO(uiLayout *layout, const char *opname, const char *propname
|
||||
|
||||
if(!ot || !ot->srna) {
|
||||
ui_item_disabled(layout, opname);
|
||||
RNA_warning("uiItemsFullEnumO: %s '%s'\n", ot ? "unknown operator" : "operator missing srna", opname);
|
||||
RNA_warning("%s '%s'", ot ? "unknown operator" : "operator missing srna", opname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -817,7 +817,7 @@ void uiItemEnumO_value(uiLayout *layout, const char *name, int icon, const char
|
||||
/* pass */
|
||||
}
|
||||
else {
|
||||
RNA_warning("uiItemEnumO_value: %s.%s not found.\n", RNA_struct_identifier(ptr.type), propname);
|
||||
RNA_warning("%s.%s not found.", RNA_struct_identifier(ptr.type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -846,7 +846,7 @@ void uiItemEnumO_string(uiLayout *layout, const char *name, int icon, const char
|
||||
RNA_property_enum_items(layout->root->block->evil_C, &ptr, prop, &item, NULL, &free);
|
||||
if(item==NULL || RNA_enum_value_from_id(item, value_str, &value)==0) {
|
||||
if(free) MEM_freeN(item);
|
||||
RNA_warning("uiItemEnumO_string: %s.%s, enum %s not found.\n", RNA_struct_identifier(ptr.type), propname, value_str);
|
||||
RNA_warning("%s.%s, enum %s not found.", RNA_struct_identifier(ptr.type), propname, value_str);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -854,7 +854,7 @@ void uiItemEnumO_string(uiLayout *layout, const char *name, int icon, const char
|
||||
MEM_freeN(item);
|
||||
}
|
||||
else {
|
||||
RNA_warning("uiItemEnumO_string: %s.%s not found.\n", RNA_struct_identifier(ptr.type), propname);
|
||||
RNA_warning("%s.%s not found.", RNA_struct_identifier(ptr.type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1061,7 +1061,7 @@ void uiItemR(uiLayout *layout, PointerRNA *ptr, const char *propname, int flag,
|
||||
|
||||
if(!prop) {
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemR: property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1074,7 +1074,7 @@ void uiItemEnumR(uiLayout *layout, const char *name, int icon, struct PointerRNA
|
||||
|
||||
if(!prop || RNA_property_type(prop) != PROP_ENUM) {
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemEnumR: property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1089,7 +1089,7 @@ void uiItemEnumR_string(uiLayout *layout, struct PointerRNA *ptr, const char *pr
|
||||
|
||||
if(!prop || RNA_property_type(prop) != PROP_ENUM) {
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemEnumR_string: enum property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("enum property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1098,7 +1098,7 @@ void uiItemEnumR_string(uiLayout *layout, struct PointerRNA *ptr, const char *pr
|
||||
if(!RNA_enum_value_from_id(item, value, &ivalue)) {
|
||||
if(free) MEM_freeN(item);
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemEnumR: enum property value not found: %s\n", value);
|
||||
RNA_warning("enum property value not found: %s", value);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1123,12 +1123,12 @@ void uiItemsEnumR(uiLayout *layout, struct PointerRNA *ptr, const char *propname
|
||||
|
||||
if(!prop) {
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemsEnumR: enum property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("enum property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
if(RNA_property_type(prop) != PROP_ENUM) {
|
||||
RNA_warning("uiItemsEnumR: not an enum property: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("not an enum property: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
else {
|
||||
@@ -1316,13 +1316,13 @@ void uiItemPointerR(uiLayout *layout, struct PointerRNA *ptr, const char *propna
|
||||
prop= RNA_struct_find_property(ptr, propname);
|
||||
|
||||
if(!prop) {
|
||||
RNA_warning("uiItemPointerR: property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
type= RNA_property_type(prop);
|
||||
if(!ELEM(type, PROP_POINTER, PROP_STRING)) {
|
||||
RNA_warning("uiItemPointerR: property %s must be a pointer or string.\n", propname);
|
||||
RNA_warning("property %s must be a pointer or string.", propname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1330,11 +1330,11 @@ void uiItemPointerR(uiLayout *layout, struct PointerRNA *ptr, const char *propna
|
||||
|
||||
|
||||
if(!searchprop) {
|
||||
RNA_warning("uiItemPointerR: search collection property not found: %s.%s\n", RNA_struct_identifier(ptr->type), searchpropname);
|
||||
RNA_warning("search collection property not found: %s.%s", RNA_struct_identifier(ptr->type), searchpropname);
|
||||
return;
|
||||
}
|
||||
else if (RNA_property_type(searchprop) != PROP_COLLECTION) {
|
||||
RNA_warning("uiItemPointerR: search collection property is not a collection type: %s.%s\n", RNA_struct_identifier(ptr->type), searchpropname);
|
||||
RNA_warning("search collection property is not a collection type: %s.%s", RNA_struct_identifier(ptr->type), searchpropname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1406,7 +1406,7 @@ static void ui_item_menu(uiLayout *layout, const char *name, int icon, uiMenuCre
|
||||
|
||||
if(layout->root->type == UI_LAYOUT_HEADER)
|
||||
uiBlockSetEmboss(block, UI_EMBOSS);
|
||||
else if(layout->root->type == UI_LAYOUT_PANEL) {
|
||||
else if(ELEM(layout->root->type, UI_LAYOUT_PANEL, UI_LAYOUT_TOOLBAR)) {
|
||||
but->type= MENU;
|
||||
but->flag |= UI_TEXT_LEFT;
|
||||
}
|
||||
@@ -1419,7 +1419,7 @@ void uiItemM(uiLayout *layout, bContext *UNUSED(C), const char *menuname, const
|
||||
mt= WM_menutype_find(menuname, FALSE);
|
||||
|
||||
if(mt==NULL) {
|
||||
RNA_warning("uiItemM: not found %s\n", menuname);
|
||||
RNA_warning("not found %s", menuname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1528,7 +1528,7 @@ static void menu_item_enum_opname_menu(bContext *UNUSED(C), uiLayout *layout, vo
|
||||
{
|
||||
MenuItemLevel *lvl= (MenuItemLevel*)(((uiBut*)arg)->func_argN);
|
||||
|
||||
uiLayoutSetOperatorContext(layout, WM_OP_EXEC_REGION_WIN);
|
||||
uiLayoutSetOperatorContext(layout, lvl->opcontext);
|
||||
uiItemsEnumO(layout, lvl->opname, lvl->propname);
|
||||
}
|
||||
|
||||
@@ -1539,12 +1539,12 @@ void uiItemMenuEnumO(uiLayout *layout, const char *opname, const char *propname,
|
||||
|
||||
if(!ot) {
|
||||
ui_item_disabled(layout, opname);
|
||||
RNA_warning("uiItemMenuEnumO: unknown operator '%s'\n", opname);
|
||||
RNA_warning("unknown operator '%s'", opname);
|
||||
return;
|
||||
}
|
||||
if(!ot->srna) {
|
||||
ui_item_disabled(layout, opname);
|
||||
RNA_warning("uiItemMenuEnumO: operator missing srna '%s'\n", opname);
|
||||
RNA_warning("operator missing srna '%s'", opname);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1577,7 +1577,7 @@ void uiItemMenuEnumR(uiLayout *layout, struct PointerRNA *ptr, const char *propn
|
||||
prop= RNA_struct_find_property(ptr, propname);
|
||||
if(!prop) {
|
||||
ui_item_disabled(layout, propname);
|
||||
RNA_warning("uiItemMenuEnumR: property not found: %s.%s\n", RNA_struct_identifier(ptr->type), propname);
|
||||
RNA_warning("property not found: %s.%s", RNA_struct_identifier(ptr->type), propname);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user