30 return is_reconstructed_;
49 is_reconstructed_ =
true;
54 if (old_view ==
nullptr) {
56 is_reconstructed_ =
true;
61 prev_filter_string_ = old_view->prev_filter_string_;
64 rename_buffer_ = std::move(old_view->rename_buffer_);
65 old_view->rename_buffer_ =
nullptr;
70 is_reconstructed_ =
true;
83 "These state changes are supposed to be delayed until reconstruction is completed");
87 bool has_active =
false;
92 "Only one view item should ever return true for its `should_be_active()` method");
159 needs_filtering_ =
false;
165 const bool is_empty = filter_str->is_empty();
166 const bool filter_changed = filter_str != prev_filter_string_;
167 prev_filter_string_ = *filter_str;
169 bool has_search_highlight =
false;
181 if (filter_changed) {
187 has_search_highlight =
true;
199 return rename_buffer_ !=
nullptr;
208 rename_buffer_ = std::make_unique<decltype(rename_buffer_)::element_type>();
215 rename_buffer_ =
nullptr;
220 return *rename_buffer_;
224 return *rename_buffer_;
234 return context_menu_title;
239 context_menu_title = title;
244 return popup_keep_open_;
249 popup_keep_open_ =
true;
259 is_multiselect_supported_ =
true;
264 return is_multiselect_supported_;
#define BLI_assert_msg(a, msg)
virtual void change_state_delayed()
virtual bool should_be_filtered_visible(StringRefNull filter_string) const
bool is_highlighted_search_
bool is_search_highlight() const
virtual std::optional< bool > should_be_active() const
bool is_filtered_visible_
virtual void on_filter_change()
virtual bool supports_scrolling() const
virtual void draw_overlays(const ARegion ®ion, const uiBlock &block) const
virtual bool is_fully_visible() const
bool is_reconstructed() const
const AbstractViewItem * search_highlight_item() const
virtual void persistent_state_apply(const uiViewState &state)
bool is_multiselect_supported() const
virtual bool listen(const wmNotifier &) const
std::optional< rcti > get_bounds() const
void update_from_old(uiBlock &new_block)
virtual void change_state_delayed()
virtual std::unique_ptr< DropTargetInterface > create_drop_target()
void allow_multiselect_items()
void set_popup_keep_open()
virtual void foreach_view_item(FunctionRef< void(AbstractViewItem &)> iter_fn) const =0
virtual bool begin_filtering(const bContext &C) const
virtual void scroll(ViewScrollDirection direction)
virtual void update_children_from_old(const AbstractView &old_view)=0
void clear_search_highlight()
void register_item(AbstractViewItem &item)
Span< char > get_rename_buffer() const
bool get_popup_keep_open() const
virtual std::optional< uiViewState > persistent_state() const
friend class AbstractViewItem
std::string get_context_menu_title() const
void filter(std::optional< StringRef > filter_str)
void set_context_menu_title(const std::string &title)
blender::ui::AbstractView * ui_block_view_find_matching_in_old_block(const uiBlock &new_block, const blender::ui::AbstractView &new_view)