row selection in the Grid widget [message #25392] |
Wed, 31 January 2007 06:55  |
Eclipse User |
|
|
|
Originally posted by: chrisn86.yahoo.de
Hi everybody,
I tried to handle a row selection within the Grid widget, through
clicking on the row header and evaluate the Selection-Event.
Unfortunately i can't find a hint that:
- a row header was selected
- more than one cell is selected without using shift or ctrl to
select them
The reason for the last problem is, that not the originally mouseDown
state mask is referred to the SelectionListeners, but a new Event object
with an empty state mask.
Is there another way to handle a row selection, or a workaround for my
problem?
By the way, is it planned to allow not only column moving but also
column group moving?
best regards
Christian Neudert
|
|
|
|
|
|
|
Re: row selection in the Grid widget [message #576727 is a reply to message #25392] |
Wed, 31 January 2007 12:51  |
Eclipse User |
|
|
|
Hi Christian,
I'm interested to know why you need to specifically know if a row header
was selected. Isn't it enough to just know that more cells are selected?
Regarding group moving, I hadn't planned on adding that feature but it
sounds like a good idea. Can you add a feature request to bugzilla?
-Chris
Christian Neudert wrote:
> Hi everybody,
>
> I tried to handle a row selection within the Grid widget, through
> clicking on the row header and evaluate the Selection-Event.
> Unfortunately i can't find a hint that:
> - a row header was selected
> - more than one cell is selected without using shift or ctrl to
> select them
> The reason for the last problem is, that not the originally mouseDown
> state mask is referred to the SelectionListeners, but a new Event object
> with an empty state mask.
> Is there another way to handle a row selection, or a workaround for my
> problem?
>
> By the way, is it planned to allow not only column moving but also
> column group moving?
>
> best regards
>
> Christian Neudert
|
|
|
Re: row selection in the Grid widget [message #576841 is a reply to message #25786] |
Wed, 31 January 2007 14:38  |
Eclipse User |
|
|
|
Hi Chris,
>I'm interested to know why you need to specifically know if a row
>header was selected. Isn't it enough to just know that more cells are
>selected?
I actually think this is the best way to handle a copy and paste action
for single Items ( I didn't looked further if it's possible at all to
copy and paste a Item ).
A way would be to make, like i do it to get the Column while handling a
popup menu selection. I add a MouseMoveListener to the Grid and check
the Column with the getColumn(Point p) method. Although this would be
inefficient checking everytime i select a cell.
The easiest way would be to check if no Shift or Ctrl key is pressed and
there is more than one cell selected, so it must be a row header
selection (if there is more than one column).
By the way, is this a bug:
-Click on a row header, while a column group isn't expandend
-for example 2 Cells are selected
-expand the group, but still only the 2 cells are selected
Ive submitted the feature request for ColumnGroup moving.
bye
Christian
|
|
|
Re: row selection in the Grid widget [message #576940 is a reply to message #25934] |
Thu, 01 February 2007 20:44  |
Eclipse User |
|
|
|
> I actually think this is the best way to handle a copy and paste action
> for single Items ( I didn't looked further if it's possible at all to
> copy and paste a Item ).
> A way would be to make, like i do it to get the Column while handling a
> popup menu selection. I add a MouseMoveListener to the Grid and check
> the Column with the getColumn(Point p) method. Although this would be
> inefficient checking everytime i select a cell.
> The easiest way would be to check if no Shift or Ctrl key is pressed and
> there is more than one cell selected, so it must be a row header
> selection (if there is more than one column).
Can you please enter a bug to make sure they shift/ctrl state is passed
through the event?
> By the way, is this a bug:
> -Click on a row header, while a column group isn't expandend
> -for example 2 Cells are selected
> -expand the group, but still only the 2 cells are selected
This is intended behavior. The assumption is that if a given cell is
hidden the user is not intending to select it.
Regards,
-Chris
|
|
|
|
Powered by
FUDForum. Page generated in 0.03431 seconds