[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
From: |
Gavin D. Smith |
Date: |
Wed, 30 Nov 2022 13:36:43 -0500 (EST) |
branch: old/qt-info
commit 15242b94f364530647eb31ac19099e4f0a89790f
Author: Gavin Smith <gavinsmith0123@gmail.com>
AuthorDate: Fri Apr 19 14:24:54 2019 +0100
* info/js (config): Add 'show_welcome_message' field.
(on_load) Check show_welcome_message to decide whether to show
welcome message.
---
ChangeLog | 6 ++++++
js/info.js | 17 ++++++++++-------
2 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 707f04a758..644d34aaf4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2019-04-19 Gavin Smith <gavinsmith0123@gmail.com>
+
+ * info/js (config): Add 'show_welcome_message' field.
+ (on_load) Check show_welcome_message to decide whether to show
+ welcome message.
+
2019-04-15 Gavin Smith <gavinsmith0123@gmail.com>
Fix up pointer to Top node.
diff --git a/js/info.js b/js/info.js
index ad9d6a4cfc..2c323f9b16 100644
--- a/js/info.js
+++ b/js/info.js
@@ -21,8 +21,7 @@
/* The commented-out function call wrapped the whole file in a scope.
This is disabled for now so we can access functions from wc_init
- and web_channel_override. We want to put wc_init in the top-level scope
- because in the future we might have this in a separate file. If we have
+ and web_channel_override, which are in separate files. If we have
problems with namespace clashes in the future then we could declare
selected
functions and variables at the top level. */
@@ -54,7 +53,8 @@ var user_config = window["INFO_CONFIG"];
the iframe context.
@type {(function (): void)} */
on_iframe_load: null
- }
+ },
+ show_welcome_message: true
};
/*-------------------.
@@ -1099,10 +1099,13 @@ var user_config = window["INFO_CONFIG"];
links[config.TOP_ID] = navigation_links (document);
store.dispatch (actions.cache_links (links));
store.dispatch ({ type: "iframe-ready", id: config.TOP_ID });
- store.dispatch ({
- type: "echo",
- msg: "Welcome to Texinfo documentation viewer 6.1, type '?' for help."
- });
+ if (config.show_welcome_message)
+ {
+ store.dispatch ({
+ type: "echo",
+ msg: "Welcome to Texinfo documentation viewer 6.1, type '?' for
help."
+ });
+ }
/* Call user hook. */
if (config.hooks.on_main_load)
- [no subject], (continued)
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject],
Gavin D. Smith <=
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30
- [no subject], Gavin D. Smith, 2022/11/30