From e179d9ee0a16c1e12d4512b6bf28bf18f732c175 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Wed, 20 Apr 2011 17:30:40 +0200 Subject: [PATCH] Resolved an issue with the focus. --- .../interactive/Notes.wgt/js/ubw-main.js | 36 +++++++++---------- 1 file changed, 16 insertions(+), 20 deletions(-) diff --git a/resources/library/interactive/Notes.wgt/js/ubw-main.js b/resources/library/interactive/Notes.wgt/js/ubw-main.js index ad9e37e1..b5ff1e8d 100644 --- a/resources/library/interactive/Notes.wgt/js/ubw-main.js +++ b/resources/library/interactive/Notes.wgt/js/ubw-main.js @@ -19,41 +19,34 @@ function init(){ var maximize = $(''); var title = $(''); var textField = $('
'); - - var shadow = $("
 
") - .appendTo("body"); - - var shadowleft = $("") - .appendTo($("#sl")); - var shadowright = $("") - .appendTo($("#sr")); + var shadow = $("
 
") + .appendTo("body"); + var shadowleft = $("") + .appendTo($("#sl")); + var shadowright = $("") + .appendTo($("#sr")); $("#ubwidget") .append(header) .append(textField); - fontUp - .addClass('menuElement'); - fontDown - .addClass('menuElement'); - minimize - .addClass('menuElement'); - maximize - .addClass('menuElement') + fontUp.addClass('menuElement'); + fontDown.addClass('menuElement'); + minimize.addClass('menuElement'); + maximize.addClass('menuElement') .hide(); - header - .append(maximize) + header.append(maximize) .append(minimize) .append(fontUp) .append(fontDown); - var titletext = header.find('textarea'); + var titletext = header.find('textarea'); titletext.click( function(){ titletext.focus(); - + }); fontDown.click( @@ -71,6 +64,7 @@ function init(){ window.uniboard.setPreference("fontSize", newFontSize); }; + textField.focus(); }); fontUp.click( @@ -87,6 +81,8 @@ function init(){ if(window.uniboard){ window.uniboard.setPreference("fontSize", newFontSize); }; + + textField.focus(); }); minimize.click(