Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-06-02 00:38:40 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-06-02 00:38:40 +0400
commit0dc84e64e754d0083b7c0c2acdd653aedb8e4890 (patch)
treee04200dd5440a57ac2c309030ce18b82c59c91ad /source/blender
parente94e7b4c7e323876bd2abcba25fa85e98e54bfe0 (diff)
experenental manual linking from the UI. realize this is an issue which is not agreed on so probably this will be disabled for release.
the data is stored here so more dev can commit: ./release/scripts/addons/modules/rna_wiki_reference.py
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/interface/interface_handlers.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index edb0bdc05f5..fce7af795e1 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -4597,6 +4597,11 @@ static int ui_but_menu(bContext *C, uiBut *but)
BLI_snprintf(buf, sizeof(buf), "%s.%s",
RNA_struct_identifier(but->rnapoin.type), RNA_property_identifier(but->rnaprop));
+ WM_operator_properties_create(&ptr_props, "WM_OT_doc_view_manual");
+ RNA_string_set(&ptr_props, "doc_id", buf);
+ uiItemFullO(layout, "WM_OT_doc_view_manual", CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Online Manual"),
+ ICON_NONE, ptr_props.data, WM_OP_EXEC_DEFAULT, 0);
+
WM_operator_properties_create(&ptr_props, "WM_OT_doc_view");
RNA_string_set(&ptr_props, "doc_id", buf);
uiItemFullO(layout, "WM_OT_doc_view", CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Python Documentation"),
@@ -4614,18 +4619,26 @@ static int ui_but_menu(bContext *C, uiBut *but)
else if (but->optype) {
WM_operator_py_idname(buf, but->optype->idname);
+
+ WM_operator_properties_create(&ptr_props, "WM_OT_doc_view_manual");
+ RNA_string_set(&ptr_props, "doc_id", buf);
+ uiItemFullO(layout, "WM_OT_doc_view_manual", CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Online Manual"),
+ ICON_NONE, ptr_props.data, WM_OP_EXEC_DEFAULT, 0);
+
WM_operator_properties_create(&ptr_props, "WM_OT_doc_view");
RNA_string_set(&ptr_props, "doc_id", buf);
uiItemFullO(layout, "WM_OT_doc_view", CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Python Documentation"),
ICON_NONE, ptr_props.data, WM_OP_EXEC_DEFAULT, 0);
-
+ /* XXX inactive option, not for public! */
+#if 0
WM_operator_properties_create(&ptr_props, "WM_OT_doc_edit");
RNA_string_set(&ptr_props, "doc_id", buf);
RNA_string_set(&ptr_props, "doc_new", but->optype->description);
uiItemFullO(layout, "WM_OT_doc_edit", CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Submit Description"),
ICON_NONE, ptr_props.data, WM_OP_INVOKE_DEFAULT, 0);
+#endif
}
}