diff --git a/Frameworks/bundles/src/index.h b/Frameworks/bundles/src/index.h index cae90440..4adc9866 100644 --- a/Frameworks/bundles/src/index.h +++ b/Frameworks/bundles/src/index.h @@ -113,18 +113,6 @@ namespace bundles std::vector _required_executables; }; - struct PUBLIC callback_t - { - virtual ~callback_t () { } - virtual void bundles_will_change () { } - virtual void bundles_did_change () { } - }; - - PUBLIC void add_callback (callback_t* cb); - PUBLIC void remove_callback (callback_t* cb); - PUBLIC void add_item (item_ptr item); - PUBLIC void remove_item (item_ptr item); - } /* bundles */ #endif /* end of include guard: BUNDLES_INDEX_H_H2GEVOXK */ diff --git a/Frameworks/bundles/src/query.h b/Frameworks/bundles/src/query.h index 4a086871..81007975 100644 --- a/Frameworks/bundles/src/query.h +++ b/Frameworks/bundles/src/query.h @@ -8,6 +8,18 @@ namespace bundles PUBLIC bool set_index (std::vector const& items, std::map< oak::uuid_t, std::vector > const& menus); inline bool set_index (std::vector const& items) { return set_index(items, std::map< oak::uuid_t, std::vector >()); } + struct PUBLIC callback_t + { + virtual ~callback_t () { } + virtual void bundles_will_change () { } + virtual void bundles_did_change () { } + }; + + PUBLIC void add_callback (callback_t* cb); + PUBLIC void remove_callback (callback_t* cb); + PUBLIC void add_item (item_ptr item); + PUBLIC void remove_item (item_ptr item); + PUBLIC std::vector query (std::string const& field, std::string const& value, scope::context_t const& scope = scope::wildcard, int kind = kItemTypeCommand|kItemTypeDragCommand|kItemTypeGrammar|kItemTypeMacro|kItemTypeSnippet|kItemTypeProxy|kItemTypeTheme, oak::uuid_t const& bundle = oak::uuid_t(), bool filter = true, bool includeDisabledItems = false); PUBLIC std::vector items_for_proxy (item_ptr proxyItem, scope::context_t const& scope = scope::wildcard, int kind = kItemTypeCommand|kItemTypeDragCommand|kItemTypeGrammar|kItemTypeMacro|kItemTypeSnippet|kItemTypeProxy|kItemTypeTheme, oak::uuid_t const& bundle = oak::uuid_t(), bool filter = true, bool includeDisabledItems = false); PUBLIC item_ptr lookup (oak::uuid_t const& uuid);