Board index » jbuilder » JdbTable and double click

JdbTable and double click


2004-05-21 05:16:39 AM
jbuilder23
In my JDBTable I have one column that shows JCheckBox to change the values
(flag/mark the record). This is the only column that is allowed to be
update. In order to check or uncheck the jCheckBox the user has to double
click on the cell in the JdbTable. Is it possible to change this behavior to
a single click instead?
Alex
Alex G. Terehoff
Booz | Allen | Hamilton
tel: (301) 427-1758
 
 

Re:JdbTable and double click

The answer is "probably not". The difficulty with editable tables is this:
how do you tell the difference between a click meant to select a row and a
click meant to edit it? One answer is have single-click for select and
double-click for edit.
--
Check out our latest white papers at
www.datadevelopment.com/papers/index.html
BladeNET Scores With Borland Enterprise Tools
Team Development with JBuilder and Borland Enterprise Server
Dolphin Data Development Ltd.
www.datadevelopment.com/
"Alex Terehoff" < XXXX@XXXXX.COM >wrote in message
Quote
In my JDBTable I have one column that shows JCheckBox to change the values
(flag/mark the record). This is the only column that is allowed to be
update. In order to check or uncheck the jCheckBox the user has to double
click on the cell in the JdbTable. Is it possible to change this behavior
to
a single click instead?

Alex

Alex G. Terehoff
Booz | Allen | Hamilton
tel: (301) 427-1758


 

Re:JdbTable and double click

Yes it is.
What you have to do is create a cell editor that extends DefaultCellEditor.
In this editor class set the following function.
setClickCountToStart(1)
to set the edit click to 1
kc
Alex Terehoff wrote:
Quote
In my JDBTable I have one column that shows JCheckBox to change the values
(flag/mark the record). This is the only column that is allowed to be
update. In order to check or uncheck the jCheckBox the user has to double
click on the cell in the JdbTable. Is it possible to change this behavior to
a single click instead?

Alex

Alex G. Terehoff
Booz | Allen | Hamilton
tel: (301) 427-1758


 

{smallsort}

Re:JdbTable and double click

I have the same thought. If I create a custom cell editor and will set its
click to start at (1) I am afraid there will be a broblem to determine which
row to edit unless row select event fires first...
I will try and let everybody know
Alex
--
Alex G. Terehoff
Booz | Allen | Hamilton
tel: (301) 427-1758
"Kevin Dean" < XXXX@XXXXX.COM >wrote in message
Quote
The answer is "probably not". The difficulty with editable tables is
this:
how do you tell the difference between a click meant to select a row and a
click meant to edit it? One answer is have single-click for select and
double-click for edit.

--
Check out our latest white papers at
www.datadevelopment.com/papers/index.html

BladeNET Scores With Borland Enterprise Tools
Team Development with JBuilder and Borland Enterprise Server

Dolphin Data Development Ltd.
www.datadevelopment.com/

"Alex Terehoff" < XXXX@XXXXX.COM >wrote in message
news:40ad2035$ XXXX@XXXXX.COM ...
>In my JDBTable I have one column that shows JCheckBox to change the
values
>(flag/mark the record). This is the only column that is allowed to be
>update. In order to check or uncheck the jCheckBox the user has to
double
>click on the cell in the JdbTable. Is it possible to change this
behavior
to
>a single click instead?
>
>Alex
>
>Alex G. Terehoff
>Booz | Allen | Hamilton
>tel: (301) 427-1758
>
>