Blender V5.3
ED_asset_shelf.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include <memory>
12
13namespace blender {
14
15struct ARegion;
16struct ARegionType;
17struct AssetShelf;
19struct AssetShelfType;
20struct BlendDataReader;
21struct BlendWriter;
22struct Main;
23struct RegionPollParams;
24struct ScrArea;
25struct bContext;
29struct wmWindowManager;
30
31class StringRef;
32class StringRefNull;
33namespace asset_system {
35}
36
38
39/* -------------------------------------------------------------------- */
50
51bool regions_poll(const RegionPollParams *params);
52
54void *region_duplicate(void *regiondata);
55void region_free(ARegion *region);
57int region_snap(const ARegion *region, int size, int axis);
58void region_on_user_resize(const ARegion *region);
59void region_listen(const wmRegionListenerParams *params);
61void region_layout(const bContext *C, ARegion *region);
62void region_draw(const bContext *C, ARegion *region);
63void region_on_poll_success(const bContext *C, ARegion *region);
65void region_blend_write(BlendWriter *writer, ARegion *region);
67
69void header_region(const bContext *C, ARegion *region);
72void types_register(ARegionType *region_type, const int space_type);
73
75
76/* -------------------------------------------------------------------- */
79
80void type_register(std::unique_ptr<AssetShelfType> type);
81void type_unregister(const AssetShelfType &shelf_type);
88bool type_poll_for_popup(const bContext &C, const AssetShelfType *shelf_type);
89bool type_asset_poll(const AssetShelfType &shelf_type,
92
94
95/* -------------------------------------------------------------------- */
98
99void type_popup_unlink(const AssetShelfType &shelf_type);
100void ensure_asset_library_fetched(const bContext &C, const AssetShelfType &shelf_type);
101
103
104/* -------------------------------------------------------------------- */
105
106void type_unlink(const Main &bmain, const AssetShelfType &shelf_type);
107
108int tile_width(const AssetShelfSettings &settings);
109int tile_height(const AssetShelfSettings &settings);
110
112
116void show_catalog_in_visible_shelves(const bContext &C, const StringRefNull catalog_path);
117
118int context(const bContext *C, const char *member, bContextDataResult *result);
119
120} // namespace ed::asset::shelf
121} // namespace blender
#define C
Definition RandGen.cpp:29
void header_region(const bContext *C, ARegion *region)
AssetShelfType * type_find_from_idname(StringRef idname)
void region_init(wmWindowManager *wm, ARegion *region)
void region_blend_read_data(BlendDataReader *reader, ARegion *region)
void type_popup_unlink(const AssetShelfType &shelf_type)
void types_register(ARegionType *region_type, const int space_type)
void region_listen(const wmRegionListenerParams *params)
void region_on_poll_success(const bContext *C, ARegion *region)
void header_region_listen(const wmRegionListenerParams *params)
void type_unregister(const AssetShelfType &shelf_type)
void region_blend_write(BlendWriter *writer, ARegion *region)
void type_unlink(const Main &bmain, const AssetShelfType &shelf_type)
int tile_height(const AssetShelfSettings &settings)
void region_on_user_resize(const ARegion *region)
int context(const bContext *C, const char *member, bContextDataResult *result)
int tile_width(const AssetShelfSettings &settings)
int region_snap(const ARegion *region, int size, int axis)
void type_register(std::unique_ptr< AssetShelfType > type)
void show_catalog_in_visible_shelves(const bContext &C, const StringRefNull catalog_path)
void * region_duplicate(void *regiondata)
bool type_poll_for_popup(const bContext &C, const AssetShelfType *shelf_type)
void ensure_asset_library_fetched(const bContext &C, const AssetShelfType &shelf_type)
AssetShelf * active_shelf_from_area(const ScrArea *area)
bool regions_poll(const RegionPollParams *params)
void header_region_init(wmWindowManager *wm, ARegion *region)
void region_draw(const bContext *C, ARegion *region)
void region_message_subscribe(const wmRegionMessageSubscribeParams *params)
bool type_asset_poll(const AssetShelfType &shelf_type, const asset_system::AssetRepresentation &asset)
void region_layout(const bContext *C, ARegion *region)
void region_free(ARegion *region)
BMesh Iterators.