Cleanup: Use doxygen sections in space_buttons.c
This commit is contained in:
parent
7c633686e9
commit
be3841b1bf
|
@ -54,7 +54,9 @@
|
|||
|
||||
#include "buttons_intern.h" /* own include */
|
||||
|
||||
/* ******************** default callbacks for buttons space ***************** */
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Default Callbacks for Properties Space
|
||||
* \{ */
|
||||
|
||||
static SpaceLink *buttons_create(const ScrArea *UNUSED(area), const Scene *UNUSED(scene))
|
||||
{
|
||||
|
@ -158,6 +160,12 @@ static void buttons_main_region_init(wmWindowManager *wm, ARegion *region)
|
|||
WM_event_add_keymap_handler(®ion->handlers, keymap);
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Property Editor Layout
|
||||
* \{ */
|
||||
|
||||
/**
|
||||
* Fills an array with the tab context values for the properties editor. -1 signals a separator.
|
||||
*
|
||||
|
@ -305,6 +313,12 @@ static void buttons_main_region_layout_properties(const bContext *C,
|
|||
ED_region_panels_layout_ex(C, region, ®ion->type->paneltypes, contexts, NULL);
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Property Search Access API
|
||||
* \{ */
|
||||
|
||||
const char *ED_buttons_search_string_get(SpaceProperties *sbuts)
|
||||
{
|
||||
return sbuts->runtime->search_string;
|
||||
|
@ -325,6 +339,12 @@ bool ED_buttons_tab_has_search_result(SpaceProperties *sbuts, const int index)
|
|||
return BLI_BITMAP_TEST(sbuts->runtime->tab_search_results, index);
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name "Off Screen" Layout Generation for Property Search
|
||||
* \{ */
|
||||
|
||||
static bool property_search_for_context(const bContext *C, ARegion *region, SpaceProperties *sbuts)
|
||||
{
|
||||
const char *contexts[2] = {buttons_main_region_context_string(sbuts->mainb), NULL};
|
||||
|
@ -462,6 +482,12 @@ static void buttons_main_region_property_search(const bContext *C,
|
|||
}
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Main Region Layout and Listener
|
||||
* \{ */
|
||||
|
||||
static void buttons_main_region_layout(const bContext *C, ARegion *region)
|
||||
{
|
||||
/* draw entirely, view changes should be handled here */
|
||||
|
@ -512,6 +538,12 @@ static void buttons_keymap(struct wmKeyConfig *keyconf)
|
|||
WM_keymap_ensure(keyconf, "Property Editor", SPACE_PROPERTIES, 0);
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Header Region Callbacks
|
||||
* \{ */
|
||||
|
||||
/* add handlers, stuff you only do once or on area/region changes */
|
||||
static void buttons_header_region_init(wmWindowManager *UNUSED(wm), ARegion *region)
|
||||
{
|
||||
|
@ -556,6 +588,12 @@ static void buttons_header_region_message_subscribe(const bContext *UNUSED(C),
|
|||
}
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Navigation Region Callbacks
|
||||
* \{ */
|
||||
|
||||
static void buttons_navigation_bar_region_init(wmWindowManager *wm, ARegion *region)
|
||||
{
|
||||
region->flag |= RGN_FLAG_PREFSIZE_OR_HIDDEN;
|
||||
|
@ -605,6 +643,12 @@ static void buttons_area_redraw(ScrArea *area, short buttons)
|
|||
}
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Area-Level Code
|
||||
* \{ */
|
||||
|
||||
/* reused! */
|
||||
static void buttons_area_listener(wmWindow *UNUSED(win),
|
||||
ScrArea *area,
|
||||
|
@ -860,6 +904,12 @@ static void buttons_id_remap(ScrArea *UNUSED(area), SpaceLink *slink, ID *old_id
|
|||
}
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/** \name Space Type Initialization
|
||||
* \{ */
|
||||
|
||||
/* only called once, from space/spacetypes.c */
|
||||
void ED_spacetype_buttons(void)
|
||||
{
|
||||
|
@ -938,3 +988,5 @@ void ED_spacetype_buttons(void)
|
|||
|
||||
BKE_spacetype_register(st);
|
||||
}
|
||||
|
||||
/** \} */
|
||||
|
|
Loading…
Reference in New Issue