diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-02-26 17:28:29 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-02-26 17:28:29 +0300 |
commit | 10dbf6faee8d9b0f592c598c0b29008effa3b80c (patch) | |
tree | bd241e812b9ab3d6bd1a35a6a277f3264b52b0c8 /source | |
parent | bbf6dde277a070ac82af8799376876e23dc13df1 (diff) |
rename extension to addon after discussion with meta-androcto & mindrones
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/blender.c | 2 | ||||
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 2 | ||||
-rw-r--r-- | source/blender/blenloader/intern/writefile.c | 6 | ||||
-rw-r--r-- | source/blender/makesdna/DNA_userdef_types.h | 10 | ||||
-rw-r--r-- | source/blender/makesrna/RNA_access.h | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_userdef.c | 52 |
6 files changed, 37 insertions, 37 deletions
diff --git a/source/blender/blenkernel/intern/blender.c b/source/blender/blenkernel/intern/blender.c index 1567ed0f986..6239d9f71b3 100644 --- a/source/blender/blenkernel/intern/blender.c +++ b/source/blender/blenkernel/intern/blender.c @@ -358,7 +358,7 @@ void BKE_userdef_free(void) BLI_freelistN(&U.uifonts); BLI_freelistN(&U.themes); BLI_freelistN(&U.keymaps); - BLI_freelistN(&U.extensions); + BLI_freelistN(&U.addons); } /* returns: diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index 591ec969c40..e0ec3b26b52 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -10690,7 +10690,7 @@ static BHead *read_userdef(BlendFileData *bfd, FileData *fd, BHead *bhead) link_list(fd, &user->themes); link_list(fd, &user->keymaps); - link_list(fd, &user->extensions); + link_list(fd, &user->addons); for(keymap=user->keymaps.first; keymap; keymap=keymap->next) { keymap->modal_items= NULL; diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c index 3e3ca8dd174..be374d153cd 100644 --- a/source/blender/blenloader/intern/writefile.c +++ b/source/blender/blenloader/intern/writefile.c @@ -542,7 +542,7 @@ static void write_userdef(WriteData *wd) bTheme *btheme; wmKeyMap *keymap; wmKeyMapItem *kmi; - bExtension *bext; + bAddon *bext; writestruct(wd, USER, "UserDef", 1, &U); @@ -560,8 +560,8 @@ static void write_userdef(WriteData *wd) } } - for(bext= U.extensions.first; bext; bext=bext->next) - writestruct(wd, DATA, "bExtension", 1, bext); + for(bext= U.addons.first; bext; bext=bext->next) + writestruct(wd, DATA, "bAddon", 1, bext); } static void write_boid_state(WriteData *wd, BoidState *state) diff --git a/source/blender/makesdna/DNA_userdef_types.h b/source/blender/makesdna/DNA_userdef_types.h index e587c45e37c..57f2ab27cc1 100644 --- a/source/blender/makesdna/DNA_userdef_types.h +++ b/source/blender/makesdna/DNA_userdef_types.h @@ -276,10 +276,10 @@ typedef struct bTheme { } bTheme; /* for the moment only the name. may want to store options with this later */ -typedef struct bExtension { - struct bExtension *next, *prev; +typedef struct bAddon { + struct bAddon *next, *prev; char module[64]; -} bExtension; +} bAddon; typedef struct SolidLight { int flag, pad; @@ -327,7 +327,7 @@ typedef struct UserDef { struct ListBase uifonts; struct ListBase uistyles; struct ListBase keymaps; - struct ListBase extensions; + struct ListBase addons; char keyconfigstr[64]; short undosteps; @@ -378,7 +378,7 @@ extern UserDef U; /* from blenkernel blender.c */ #define USER_SECTION_SYSTEM 3 #define USER_SECTION_THEME 4 #define USER_SECTION_INPUT 5 -#define USER_SECTION_EXTENSIONS 6 +#define USER_SECTION_ADDONS 6 /* flag */ #define USER_AUTOSAVE (1 << 0) diff --git a/source/blender/makesrna/RNA_access.h b/source/blender/makesrna/RNA_access.h index f55207674fe..89dd6a5c3e6 100644 --- a/source/blender/makesrna/RNA_access.h +++ b/source/blender/makesrna/RNA_access.h @@ -49,6 +49,7 @@ extern StructRNA RNA_ActionConstraint; extern StructRNA RNA_ActionGroup; extern StructRNA RNA_Actuator; extern StructRNA RNA_ActuatorSensor; +extern StructRNA RNA_Addon; extern StructRNA RNA_AlwaysSensor; extern StructRNA RNA_AndController; extern StructRNA RNA_AnimData; @@ -198,7 +199,6 @@ extern StructRNA RNA_EnvironmentMapTexture; extern StructRNA RNA_Event; extern StructRNA RNA_ExplodeModifier; extern StructRNA RNA_ExpressionController; -extern StructRNA RNA_Extension; extern StructRNA RNA_FCurve; extern StructRNA RNA_FCurveSample; extern StructRNA RNA_FieldSettings; diff --git a/source/blender/makesrna/intern/rna_userdef.c b/source/blender/makesrna/intern/rna_userdef.c index ee2c96bcbd2..f96678cda10 100644 --- a/source/blender/makesrna/intern/rna_userdef.c +++ b/source/blender/makesrna/intern/rna_userdef.c @@ -211,16 +211,16 @@ static void rna_userdef_autosave_update(Main *bmain, Scene *scene, PointerRNA *p rna_userdef_update(bmain, scene, ptr); } -static bExtension *rna_userdef_extension_new(void) +static bAddon *rna_userdef_addon_new(void) { - bExtension *bext= MEM_callocN(sizeof(bExtension), "bext"); - BLI_addtail(&U.extensions, bext); + bAddon *bext= MEM_callocN(sizeof(bAddon), "bAddon"); + BLI_addtail(&U.addons, bext); return bext; } -static void rna_userdef_extension_remove(bExtension *bext) +static void rna_userdef_addon_remove(bAddon *bext) { - BLI_freelinkN(&U.extensions, bext); + BLI_freelinkN(&U.addons, bext); } @@ -1687,14 +1687,14 @@ static void rna_def_userdef_themes(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Bone Color Sets", ""); } -static void rna_def_userdef_extensions(BlenderRNA *brna) +static void rna_def_userdef_addon(BlenderRNA *brna) { StructRNA *srna; PropertyRNA *prop; - srna= RNA_def_struct(brna, "Extension", NULL); - RNA_def_struct_sdna(srna, "bExtension"); - RNA_def_struct_ui_text(srna, "Extension", "Python extensions to be loaded automatically"); + srna= RNA_def_struct(brna, "Addon", NULL); + RNA_def_struct_sdna(srna, "bAddon"); + RNA_def_struct_ui_text(srna, "Addon", "Python addons to be loaded automatically"); prop= RNA_def_property(srna, "module", PROP_STRING, PROP_NONE); RNA_def_property_ui_text(prop, "Module", "Module name"); @@ -1727,7 +1727,6 @@ static void rna_def_userdef_dothemes(BlenderRNA *brna) rna_def_userdef_theme_space_logic(brna); rna_def_userdef_theme_colorset(brna); rna_def_userdef_themes(brna); - rna_def_userdef_extensions(brna); } static void rna_def_userdef_solidlight(BlenderRNA *brna) @@ -2649,27 +2648,27 @@ static void rna_def_userdef_filepaths(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Save Preview Images", "Enables automatic saving of preview images in the .blend file"); } -void rna_def_userdef_extension_collection(BlenderRNA *brna, PropertyRNA *cprop) +void rna_def_userdef_addon_collection(BlenderRNA *brna, PropertyRNA *cprop) { StructRNA *srna; FunctionRNA *func; PropertyRNA *parm; - RNA_def_property_srna(cprop, "UserExtensions"); - srna= RNA_def_struct(brna, "UserExtensions", NULL); - RNA_def_struct_ui_text(srna, "User Extensions", "Collection of extensions"); + RNA_def_property_srna(cprop, "Addons"); + srna= RNA_def_struct(brna, "Addons", NULL); + RNA_def_struct_ui_text(srna, "User Add-Ons", "Collection of add-ons"); - func= RNA_def_function(srna, "new", "rna_userdef_extension_new"); + func= RNA_def_function(srna, "new", "rna_userdef_addon_new"); RNA_def_function_flag(func, FUNC_NO_SELF); - RNA_def_function_ui_description(func, "Add a new camera to the main database"); + RNA_def_function_ui_description(func, "Add a new addon"); /* return type */ - parm= RNA_def_pointer(func, "extension", "Extension", "", "Extension datablock."); + parm= RNA_def_pointer(func, "addon", "Addon", "", "Addon datablock."); RNA_def_function_return(func, parm); - func= RNA_def_function(srna, "remove", "rna_userdef_extension_remove"); + func= RNA_def_function(srna, "remove", "rna_userdef_addon_remove"); RNA_def_function_flag(func, FUNC_NO_SELF); - RNA_def_function_ui_description(func, "Remove a camera from the current blendfile."); - parm= RNA_def_pointer(func, "extension", "Extension", "", "Extension to remove."); + RNA_def_function_ui_description(func, "Remove addon."); + parm= RNA_def_pointer(func, "addon", "Addon", "", "Addon to remove."); RNA_def_property_flag(parm, PROP_REQUIRED); } @@ -2682,7 +2681,7 @@ void RNA_def_userdef(BlenderRNA *brna) {USER_SECTION_INTERFACE, "INTERFACE", 0, "Interface", ""}, {USER_SECTION_EDIT, "EDITING", 0, "Editing", ""}, {USER_SECTION_INPUT, "INPUT", 0, "Input", ""}, - {USER_SECTION_EXTENSIONS, "EXTENSIONS", 0, "Extensions", ""}, + {USER_SECTION_ADDONS, "ADDONS", 0, "Add-Ons", ""}, {USER_SECTION_THEME, "THEMES", 0, "Themes", ""}, {USER_SECTION_FILE, "FILES", 0, "File", ""}, {USER_SECTION_SYSTEM, "SYSTEM", 0, "System", ""}, @@ -2711,11 +2710,11 @@ void RNA_def_userdef(BlenderRNA *brna) RNA_def_property_struct_type(prop, "ThemeStyle"); RNA_def_property_ui_text(prop, "Styles", ""); - prop= RNA_def_property(srna, "extensions", PROP_COLLECTION, PROP_NONE); - RNA_def_property_collection_sdna(prop, NULL, "extensions", NULL); - RNA_def_property_struct_type(prop, "Extension"); - RNA_def_property_ui_text(prop, "Extension", ""); - rna_def_userdef_extension_collection(brna, prop); + prop= RNA_def_property(srna, "addons", PROP_COLLECTION, PROP_NONE); + RNA_def_property_collection_sdna(prop, NULL, "addons", NULL); + RNA_def_property_struct_type(prop, "Addon"); + RNA_def_property_ui_text(prop, "Addon", ""); + rna_def_userdef_addon_collection(brna, prop); /* nested structs */ @@ -2754,6 +2753,7 @@ void RNA_def_userdef(BlenderRNA *brna) rna_def_userdef_input(brna); rna_def_userdef_filepaths(brna); rna_def_userdef_system(brna); + rna_def_userdef_addon(brna); } |