aboutsummaryrefslogtreecommitdiffstats
path: root/core/plugin/intent/intent.rb
diff options
context:
space:
mode:
Diffstat (limited to 'core/plugin/intent/intent.rb')
-rw-r--r--core/plugin/intent/intent.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/core/plugin/intent/intent.rb b/core/plugin/intent/intent.rb
index 862a1a84..12cc69fc 100644
--- a/core/plugin/intent/intent.rb
+++ b/core/plugin/intent/intent.rb
@@ -3,6 +3,10 @@ require_relative 'model/intent'
require_relative 'model/intent_token'
Plugin.create(:intent) do
+ # 全てのIntentを列挙するためのフィルタ
+ defevent :intent_catalog,
+ prototype: [:<<]
+
# _uri_ を開くことができる Model を列挙するためのフィルタ
defevent :model_of_uri,
prototype: [URI, :<<]
@@ -40,6 +44,10 @@ Plugin.create(:intent) do
end
[target_model_slug, intents]
end
+ filter_intent_all do |intents|
+ intents << my_intent
+ [intents]
+ end
add_event(:"intent_open_#{slug}", &proc)
self
end