You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by lesterburlap <be...@emc.com> on 2008/12/17 21:03:26 UTC
TextField in inmethod grid column header - Firefox issue
Hi!
I'm using the inmethod grid 1.0.0-SNAPSHOT (1.3 branch) with Wicket 1.3.5.
I added a TextField to my custom column header (an AbstractLightWeightColumn
extension). The purpose of the TextField is to provide a way to filter the
row contents of the column.
It works fine in Internet Explorer 6. However, in Firefox 3, I cannot focus
on the TextField and type in it. It seems that (possibly) the pre-light
event for dragging the column is blocking focus on the TextField.
I've gone through all the grid javascript and can't find anything obvious.
Thanks for any help. I've attached a visual aid...
http://www.nabble.com/file/p21060335/datagrid_textbox.jpg
--
View this message in context: http://www.nabble.com/TextField-in-inmethod-grid-column-header---Firefox-issue-tp21060335p21060335.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: TextField in inmethod grid column header - Firefox issue
Posted by lesterburlap <be...@emc.com>.
Matej Knopp-2 wrote:
>
> Well, you can try catching the event in textfields' onMouseDown and
> then either set e.ignore=true on it or make it stop propagate.
>
Brilliant, thanks Matej. It works now. For posterity, this is the
necessary change:
HTML:
<input type="text" onmousedown="return ignoreMouseEvent(event);"
wicket:id="myTextField" />
JS (using Ext to double-check browser type):
ignoreMouseEvent : function(event){
if (Ext.isGecko && event) {
event.stopPropagation();
}
return true;
}
--
View this message in context: http://www.nabble.com/TextField-in-inmethod-grid-column-header---Firefox-issue-tp21060335p21301507.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: TextField in inmethod grid column header - Firefox issue
Posted by Matej Knopp <ma...@gmail.com>.
Well, you can try catching the event in textfields' onMouseDown and
then either set e.ignore=true on it or make it stop propagate.
-Matej
On Fri, Dec 19, 2008 at 11:07 PM, lesterburlap <be...@emc.com> wrote:
>
>
> Matej Knopp-2 wrote:
>>
>> it doesn't seem likely for me that the prelight would cause this. But
>> it also isn't impossible. These things are quite difficult to predict
>> and sometimes also to solve unfortunately.
>>
>> -Matej
>>
>
> Could it possibly be the InMethod.Drag.onMouseDown method in script.js
> that's preventing the focus from being set on the TextField? That method is
> called when I click on the TextField, and it returns false...
>
> 202 onMouseDown: function(e) {
> 203 if (typeof(e.ignore) == "undefined") {
> 204
> 205 E.stopEvent(e);
> 206 this.lastMouseX = e.clientX;
> 207 this.lastMouseY = e.clientY;
> 208
> 209 addListener(document, "selectstart", this.onSelectStart);
> 210 addListener(document, "mousemove", this.onMouseMove, this, true);
> 211 addListener(document, "mouseup", this.onMouseUp, this, true);
> 212
> 213 this.onDragBegin.bind(this.thisRef)(Wicket.$(this.elementId), e);
> 214 }
> 215
> 216 return false;
> 217 },
>
> I'm going to start experimenting with it. Any feedback or hints would be
> appreciated. Thanks!
>
> Lester
> --
> View this message in context: http://www.nabble.com/TextField-in-inmethod-grid-column-header---Firefox-issue-tp21060335p21098990.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: TextField in inmethod grid column header - Firefox issue
Posted by lesterburlap <be...@emc.com>.
Matej Knopp-2 wrote:
>
> it doesn't seem likely for me that the prelight would cause this. But
> it also isn't impossible. These things are quite difficult to predict
> and sometimes also to solve unfortunately.
>
> -Matej
>
Could it possibly be the InMethod.Drag.onMouseDown method in script.js
that's preventing the focus from being set on the TextField? That method is
called when I click on the TextField, and it returns false...
202 onMouseDown: function(e) {
203 if (typeof(e.ignore) == "undefined") {
204
205 E.stopEvent(e);
206 this.lastMouseX = e.clientX;
207 this.lastMouseY = e.clientY;
208
209 addListener(document, "selectstart", this.onSelectStart);
210 addListener(document, "mousemove", this.onMouseMove, this, true);
211 addListener(document, "mouseup", this.onMouseUp, this, true);
212
213 this.onDragBegin.bind(this.thisRef)(Wicket.$(this.elementId), e);
214 }
215
216 return false;
217 },
I'm going to start experimenting with it. Any feedback or hints would be
appreciated. Thanks!
Lester
--
View this message in context: http://www.nabble.com/TextField-in-inmethod-grid-column-header---Firefox-issue-tp21060335p21098990.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: TextField in inmethod grid column header - Firefox issue
Posted by Matej Knopp <ma...@gmail.com>.
Hi,
it doesn't seem likely for me that the prelight would cause this. But
it also isn't impossible. These things are quite difficult to predict
and sometimes also to solve unfortunately.
-Matej
On Wed, Dec 17, 2008 at 9:03 PM, lesterburlap <be...@emc.com> wrote:
>
> Hi!
>
> I'm using the inmethod grid 1.0.0-SNAPSHOT (1.3 branch) with Wicket 1.3.5.
> I added a TextField to my custom column header (an AbstractLightWeightColumn
> extension). The purpose of the TextField is to provide a way to filter the
> row contents of the column.
>
> It works fine in Internet Explorer 6. However, in Firefox 3, I cannot focus
> on the TextField and type in it. It seems that (possibly) the pre-light
> event for dragging the column is blocking focus on the TextField.
>
> I've gone through all the grid javascript and can't find anything obvious.
> Thanks for any help. I've attached a visual aid...
>
> http://www.nabble.com/file/p21060335/datagrid_textbox.jpg
> --
> View this message in context: http://www.nabble.com/TextField-in-inmethod-grid-column-header---Firefox-issue-tp21060335p21060335.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org