summaryrefslogtreecommitdiff
path: root/program/js
diff options
context:
space:
mode:
authorThomas Bruederli <thomas@roundcube.net>2014-09-27 00:13:46 +0200
committerThomas Bruederli <thomas@roundcube.net>2014-09-27 00:13:46 +0200
commitfef904c6b16a83ee9aa6dfb7eff35d2934b07d19 (patch)
treeda83a57176202ab48b933da4e304c7f9cf9dd3cd /program/js
parent1070bdb389794688cbe28e5802ede5dd71de593d (diff)
Enable/disable siganture commands before exiting the function in new compose window (#1490074)
Diffstat (limited to 'program/js')
-rw-r--r--program/js/app.js19
1 files changed, 10 insertions, 9 deletions
diff --git a/program/js/app.js b/program/js/app.js
index e6b1d84a1..323fd258c 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -3866,6 +3866,16 @@ function rcube_webmail()
if (!show_sig)
show_sig = this.env.show_sig;
+ var id = obj.options[obj.selectedIndex].value;
+
+ // enable manual signature insert
+ if (this.env.signatures && this.env.signatures[id]) {
+ this.enable_command('insert-sig', true);
+ this.env.compose_commands.push('insert-sig');
+ }
+ else
+ this.enable_command('insert-sig', false);
+
// first function execution
if (!this.env.identities_initialized) {
this.env.identities_initialized = true;
@@ -3876,7 +3886,6 @@ function rcube_webmail()
}
var cursor_pos, p = -1,
- id = obj.options[obj.selectedIndex].value,
input_message = $("[name='_message']"),
message = input_message.val(),
is_html = ($("input[name='_is_html']").val() == '1'),
@@ -3917,14 +3926,6 @@ function rcube_webmail()
input.val(input_val).change();
});
- // enable manual signature insert
- if (this.env.signatures && this.env.signatures[id]) {
- this.enable_command('insert-sig', true);
- this.env.compose_commands.push('insert-sig');
- }
- else
- this.enable_command('insert-sig', false);
-
if (!is_html) {
// remove the 'old' signature
if (show_sig && sig && this.env.signatures && this.env.signatures[sig]) {