Closed Bug 195451 Opened 22 years ago Closed 17 years ago

new widget: editable listcell

Categories

(Core :: XUL, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: shanec, Assigned: jag+mozilla)

Details

Attachments

(4 files, 2 obsolete files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20030210
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20030210

I needed an editable listcell, so we created one.  this requires a small patch
to the existing listbox.xml file, and some new code which could be put into that
file as well.

Reproducible: Always

Steps to Reproduce:
    <listbox>
      <listitem label="Normal"/>
      <listitem type="editable" label="Editable"/>
      <listitem>
        <listcell type="editable" label="Editable2"/>
      </listitem>
      <listitem label="Selected" selected="true" />
      <listitem label="Disabled" disabled="true" />
      <listitem label="Checkbox" class="listitem-iconic" type="checkbox" 
        image="images/betty_boop.xbm"/>
      <listitem label="Checked"  type="checkbox" checked="true" />
    </listbox>
Actual Results:  
double clicking on the listitem or listcell allows editing of the item.  For
keyboard navigation, hiting the spacebar on the item will enter edit mode.


files will be attached, we'd like to know about getting some of our xbl widgets,
here's a first one.
Attached file listbox xbl file (obsolete) —
Attached file editable listitem/cell css (obsolete) —
files will be attached, we'd like to know about getting some of our xbl widgets
*into moz code base*,
here's a first one.

missed that part of the sentence. :)
This is an automated message, with ID "auto-resolve01".

This bug has had no comments for a long time. Statistically, we have found that
bug reports that have not been confirmed by a second user after three months are
highly unlikely to be the source of a fix to the code.

While your input is very important to us, our resources are limited and so we
are asking for your help in focussing our efforts. If you can still reproduce
this problem in the latest version of the product (see below for how to obtain a
copy) or, for feature requests, if it's not present in the latest version and
you still believe we should implement it, please visit the URL of this bug
(given at the top of this mail) and add a comment to that effect, giving more
reproduction information if you have it.

If it is not a problem any longer, you need take no action. If this bug is not
changed in any way in the next two weeks, it will be automatically resolved.
Thank you for your help in this matter.

The latest beta releases can be obtained from:
Firefox:     http://www.mozilla.org/projects/firefox/
Thunderbird: http://www.mozilla.org/products/thunderbird/releases/1.5beta1.html
Seamonkey:   http://www.mozilla.org/projects/seamonkey/
(In reply to comment #5)

I guess editable listitem is too useful thing to close a bug. What do you think?
If there is interest in an editable listcell widget, I'll refresh the patches
attached to this bug.  We still use this in Komodo (now in 1.8 branch)
(In reply to comment #7)
> If there is interest in an editable listcell widget, I'll refresh the patches
> attached to this bug.  We still use this in Komodo (now in 1.8 branch)

It would be good.

It's interesting to know opinions of mozilla workers on including editable
listbox into toolkit.
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows 2000 → All
Hardware: PC → All
(In reply to comment #7)
> If there is interest in an editable listcell widget, I'll refresh the patches
> attached to this bug.  We still use this in Komodo (now in 1.8 branch)

Since bug status is new then I guess the widget is wanted. Can you create a patch? 

I have some thoughts.

1) I guess css file should define the next style too:
listbox[editable="true"] listcell {
  -moz-binding(editableListcellBindingURL);
}

2) Probably it's a good thing if editable listbox will be have possibility of adding new rows (and probably removing). Your opinion?
Attachment #115920 - Attachment is obsolete: true
Attached file listbox xbl file
Attachment #115919 - Attachment is obsolete: true
I've updated the editable list xbl.  It no longer requires a patch to the existing listbox, however, the listbox now needs a type attribute that is "editable".  It still would be easier to apply the patch to the existing base listbox, the patch is the same except you would apply it to the toolkit listbox.
Can you create the patch (one diff file)?

Note before making patch (if you can for sure),

1) listbox bindings rules (-moz-binding) I guess would be look better if you put them into toolkit/content/xul.css,
2) listbox binding file should be putted into directory toolkit/content/widgets/. Note you should add the reference on file in toolkit/content/jar.mn,
3) listbox css file should be in themes/classic[modern?]/global/[win/unix/and so on] directory. Note you should add a reference on css file in themes/classic/jar.mn.

If you havn't time then I guess I can try to do it. Thanks for the widget :)

There is one more problem that disturbs me. I do not know whom can I ask for review.
Enn, is idea of the patch fine with you?
Comment on attachment 213645 [details]
listbox xbl file

>                // create a new mouse event to repace this one,
>                // and dispatch it on the listitem.  We must do this
>                // because xul:listrow will not accept mouse events
>                // from anything other than a listitem.  This makes
>                // row selection work properly
This was fixed almost 4 years ago...
This abuses what listboxes are for (for selecting an item from a list). If you want an editable list of data, now that we support it, the tree should be used for this.
(In reply to comment #17)
> This abuses what listboxes are for (for selecting an item from a list). If you
> want an editable list of data, now that we support it, the tree should be used
> for this.
> 

So, wontfix then?
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: