aboutsummaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorMikael Nordfeldth <mmn@hethane.se>2015-01-16 12:00:45 +0100
committerMikael Nordfeldth <mmn@hethane.se>2015-01-16 12:00:45 +0100
commit59ec9c6988608f665fb7cea5eb4f3feb56db892f (patch)
tree2ade1ba2a0571bd96d5a7775db68f90ade10e867 /js
parent8892702f0cf84ca7b74ef8fdbb785e3155637c72 (diff)
downloadgnu-social-59ec9c6988608f665fb7cea5eb4f3feb56db892f.tar
gnu-social-59ec9c6988608f665fb7cea5eb4f3feb56db892f.zip
Don't close main notice input on init if composing
Diffstat (limited to 'js')
-rw-r--r--js/util.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/js/util.js b/js/util.js
index 2861580456..19a9ead524 100644
--- a/js/util.js
+++ b/js/util.js
@@ -1438,7 +1438,15 @@ var SN = { // StatusNet
// when forms get displayed for the first time...
// Initially hide all tabs on the top of the page
- SN.U.switchInputFormTab(null);
+ // if there's no data in there yet.
+ var fields = $('#content .input_forms .input_form.current').find('textarea, input[type=text], input[type=""]');
+ var anything = false;
+ fields.each(function () {
+ anything = anything || $(this).val();
+ });
+ if (!anything) {
+ SN.U.switchInputFormTab(null);
+ }
// Make inline reply forms self-close when clicking out.
$('body').on('click', function (e) {