[comp.sys.mac.programmer] CBartender problem

brux@cs.utexas.edu (Mark Brucks) (09/07/90)

I've discovered a problem with CBartender.  I'm using MBAR and MENU
resources.  One MENU resource initially has no items, and the menu
is created correctly by IBartender.  However, when the first item
is added via InsertMenuCmd, the cmdNo is not set correctly.  If
you look in InsertMenuCmd, you'll see that SetHandleSize is called
with a NULL ptr just before the cmdNo is set.  Of course, this
doesn't work.

I've sent this description to Rich Siegel, and he thinks that it is
a known problem, but he doesn't know if it is covered by any of the
TCL patches.  Has anybody else seen this problem?  It is easy to
patch TCL and get things to work, but if there is an "official"
patch (that may cover other bugs I don't know about) I'd like to
know about it.  Thanks.

Mark Brucks - brux@cs.utexas.edu

anderson@Apple.COM (Clark Anderson) (09/07/90)

From: brux@cs.utexas.edu (Mark Brucks):
>I've discovered a problem with CBartender.  I'm using MBAR and MENU
>resources.  One MENU resource initially has no items, and the menu
>is created correctly by IBartender.  However, when the first item
>is added via InsertMenuCmd, the cmdNo is not set correctly.

One of my applications does the same thing. That is, it has
a menu with no items in it, and the items are appended to it
after the menu bar is built. As far as I can tell, CBartender
works exactly the way its supposed to. All the items I insert
show up and work correctly...
                                          --clark
-----------------------------------------------------------
Clark Anderson                InterNet:  anderson@apple.com
PCB Software Tools            AppleLink: C.ANDERSON
Apple Computer, Inc           BellNet:   408-974-4593

"I speak only for myself, much to my employer's relief..."
-----------------------------------------------------------

-- 
-----------------------------------------------------------
Clark Anderson                InterNet:  anderson@apple.com
PCB Software Tools            AppleLink: C.ANDERSON
Apple Computer, Inc           BellNet:   408-974-4593

"I speak only for myself, much to my employer's relief..."
-----------------------------------------------------------

markw@kinetics.com (Mark Wittenberg) (09/12/90)

From article <44601@apple.Apple.COM>, by anderson@Apple.COM (Clark Anderson):
> From: brux@cs.utexas.edu (Mark Brucks):
>>I've discovered a problem with CBartender.  I'm using MBAR and MENU
>>resources.  One MENU resource initially has no items, and the menu
>>is created correctly by IBartender.  However, when the first item
>>is added via InsertMenuCmd, the cmdNo is not set correctly.
> 

This is a bug in 4.0, and has been fixed in 4.0.2.

/markw
Mark Wittenberg			Internet:	markw@kinetics.com
Novell, Inc.				(or)	markw@wc.novell.com
1340 Treat Blvd. Suite 500	UUCP:		ucbvax!mtxinu!kinetics!markw
Walnut Creek, CA 94596		AppleLink:	NOVELL.WCENG
FAX: (415) 947-1238		Voice:		(415) 975-4512