Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.mac.programmer.help > #100 > unrolled thread

An additional menu like PGP menu but icon crashes

Started bygastacara@macgui.com (Cliff Huylebroeck)
First post2011-12-20 15:46 +0000
Last post2011-12-27 16:08 +0000
Articles 2 — 1 participant

Back to article view | Back to comp.sys.mac.programmer.help


Contents

  An additional menu like PGP menu but icon crashes gastacara@macgui.com (Cliff Huylebroeck) - 2011-12-20 15:46 +0000
    Re: An additional menu like PGP menu but icon crashes gastacara@macgui.com (Cliff Huylebroeck) - 2011-12-27 16:08 +0000

#100 — An additional menu like PGP menu but icon crashes

Fromgastacara@macgui.com (Cliff Huylebroeck)
Date2011-12-20 15:46 +0000
SubjectAn additional menu like PGP menu but icon crashes
Message-ID<gastacara-1324395975@macgui.com>
I added a menu to the OS 9 Finder between Special and Help, like the PGP
menu.
This works.
It's a PPC appe extension.
When I quit the extension it removes the menu.

Then I tried to replace the menu title with and icon and add an icon to
every item.
This crashes.
Line 1111 exception or something.

Do I have to do something like InitXXX?
Now it doesn't do any toolbox init.

Is there a source code example that does something similar?
(Not sysmenu INIT, that's too old and doesn't do the same.)

[toc] | [next] | [standalone]


#102

Fromgastacara@macgui.com (Cliff Huylebroeck)
Date2011-12-27 16:08 +0000
Message-ID<gastacara-1325002092@macgui.com>
In reply to#100
I found a newer version of sysmenu INIT (1.4).
I changed that.
It works.

An icon can be placed in the title:
Load an icon suite with small icons.
Use a title that starts with character 1 followed by the address of the icon
suite handle when you create the menu in the DrawMenuBar patch.

An icon can be placed in an item in 2 ways:

1) Paste a color icon (cicn resource) into the System.
Its resource ID has to be between 257 and 511, but not 260 or 301-307.
Subtract 256 and then use SetItemIcon when you create the menu in the
DrawMenuBar patch.
This will draw a large icon.

2) Load an icon suite.
Use SetMenuItemIconHandle when you create the menu in the DrawMenuBar patch.
This will draw a small icon.

[toc] | [prev] | [standalone]


Back to top | Article view | comp.sys.mac.programmer.help


csiph-web