diff options
author | Hans Goudey <h.goudey@me.com> | 2020-08-20 16:29:01 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-08-20 16:29:01 +0300 |
commit | 52f40bcff21b285b7eaa21aaa9c6c7b9d6fa8669 (patch) | |
tree | 8ee6f0ae60c02e4b6c2a602d5770b8e570658617 /source/blender/editors/screen/workspace_edit.c | |
parent | a12d0469107635713cc8056c6f088f060676d5ca (diff) |
Cleanup: Use LISTBASE_FOREACH in editors screen directory
Differential Revision: https://developer.blender.org/D8653
Diffstat (limited to 'source/blender/editors/screen/workspace_edit.c')
-rw-r--r-- | source/blender/editors/screen/workspace_edit.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source/blender/editors/screen/workspace_edit.c b/source/blender/editors/screen/workspace_edit.c index b20dc80d158..b93734272bc 100644 --- a/source/blender/editors/screen/workspace_edit.c +++ b/source/blender/editors/screen/workspace_edit.c @@ -409,8 +409,7 @@ static void workspace_add_menu(bContext *UNUSED(C), uiLayout *layout, void *temp WorkspaceConfigFileData *builtin_config = workspace_system_file_read(app_template); if (startup_config) { - for (WorkSpace *workspace = startup_config->workspaces.first; workspace; - workspace = workspace->id.next) { + LISTBASE_FOREACH (WorkSpace *, workspace, &startup_config->workspaces) { uiLayout *row = uiLayoutRow(layout, false); workspace_append_button(row, ot_append, workspace, startup_config->main); has_startup_items = true; @@ -420,8 +419,7 @@ static void workspace_add_menu(bContext *UNUSED(C), uiLayout *layout, void *temp if (builtin_config) { bool has_title = false; - for (WorkSpace *workspace = builtin_config->workspaces.first; workspace; - workspace = workspace->id.next) { + LISTBASE_FOREACH (WorkSpace *, workspace, &startup_config->workspaces) { if (startup_config && BLI_findstring(&startup_config->workspaces, workspace->id.name, offsetof(ID, name))) { continue; |