#191 4.7.29. connectTreeViewEvent

ooDialog.4.2.1
closed
1
2013-01-13
2012-09-30
No

----Current text:
3. The event-handling method connected to EXPANDED or EXPANDING receives three
arguments: the control ID of the tree view control, the tree item expanded or collapsed, and a
string that indicates whether the item was expanded or collapsed. Example:

::method onExpanding unguarded
use arg id, item, what
say "Item with handle" item "is going to be" what
return 0


The example text "is going to be" is confusing and should read "was" (or something along those lines).

Discussion

  • Mark Miesfeld

    Mark Miesfeld - 2012-09-30

    Saying "was" is incorrect. The EXPANDING event notification happens before the item is expanded or collapsed. Let's say the item is about to be expanded, the print out would be:

    Item with handle 0x000000000031D4A0 is going to be EXPANDED

    This is correct. At the time the EXPANDING notification is sent, the item is not expanded. It's about to be expanded.

    I fully agree that much of the ooDialog doc is confusing. I've been working on improving it, but it is a slow process.

     
  • Staffan Tylen

    Staffan Tylen - 2012-09-30

    Hmm, when I ran a test, the 3rd parameter returned COLLAPSED after I had
    clicked the item box to get it expanded. That matches the description in
    the book ("indicates whether the item was expanded or collapsed") but it
    doesn't match "is going to be" in the same example nor does it match your
    example "Let's say the item is about to be expanded..." in which case the
    printout I would get would be "is going to be COLLAPSED" (where COLLAPSED
    is the contents of the 3rd parameter 'what').

    Confusing, yes.

    On Sun, Sep 30, 2012 at 5:32 PM, Mark Miesfeld miesfeld@users.sf.netwrote:

    Saying "was" is incorrect. The EXPANDING event notification happens before
    the item is expanded or collapsed. Let's say the item is about to be
    expanded, the print out would be:

    Item with handle 0x000000000031D4A0 is going to be EXPANDED

    This is correct. At the time the EXPANDING notification is sent, the item
    is not expanded. It's about to be expanded.

    I fully agree that much of the ooDialog doc is confusing. I've been
    working on improving it, but it is a slow process.


    • documentation:191 4.7.29. connectTreeViewEvent*

    Status: open Created: Sun Sep 30, 2012 10:14 AM UTC by Staffan Tylen Last
    Updated:
    Sun Sep 30, 2012 10:14 AM UTC Owner: nobody

    ----Current text:
    3. The event-handling method connected to EXPANDED or EXPANDING receives
    three
    arguments: the control ID of the tree view control, the tree item expanded
    or collapsed, and a
    string that indicates whether the item was expanded or collapsed. Example:

    ::method onExpanding unguarded
    use arg id, item, what
    say "Item with handle" item "is going to be" what
    return 0


    The example text "is going to be" is confusing and should read "was" (or
    something along those lines).


    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/oorexx/documentation/191/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/prefs/

     
  • Mark Miesfeld

    Mark Miesfeld - 2012-10-01
    • labels: --> ooDialog
    • status: open --> accepted
    • assigned_to: Mark Miesfeld
     
  • Mark Miesfeld

    Mark Miesfeld - 2012-10-01

    Committed revision [r8458]

    I split the single section trying to cover both the EXPANDED and EXPANDING events into two separate sections, one for each event. Hopefully that will be less confusing and help to illustrate the two different events.

    • labels: ooDialog --> ooDialog, fixed
    • status: accepted --> pending
    • milestone: ooDialog.4.2.0 --> ooDialog.4.2.1
     

    Related

    Commit: [r8458]

  • Mark Miesfeld

    Mark Miesfeld - 2012-10-01

    Sorry, I didn't receive an e-mail notification when you updated this bug with your last comment. Then, since I knew there had not been any updates, I didn't scroll down and never saw your comments.

    "Hmm, when I ran a test, the 3rd parameter returned COLLAPSED after I had
    clicked the item box to get it expanded."

    This is a bug in the implementation, not the doc.

    Both the doc and the implementation code are unchanged from what the project received from IBM. The Microsoft doc is clear on the EXPANDING notification. It's purpose is to inform when the tree-view item is about to be expanded or about to be collapsed. If you click on the button to expand an item, you should be informed that the item is about to be expanded. The 3rd parameter should have been EXPANDED in the case you describe.

     
  • Mark Miesfeld

    Mark Miesfeld - 2013-01-13
    • status: pending --> closed
     
  • Mark Miesfeld

    Mark Miesfeld - 2013-01-13

    Fixed docs are in the ooDialog 4.2.1 release.

     


Anonymous

Cancel  Add attachments