User-agent: Mozilla Thunderbird 1.0.6 (Macintosh/20050716)
Eric Schlegel wrote:
On Nov 26, 2007, at 10:32 PM, Julie Porter wrote:
Next up is to convert the text entry dialogs to the nib based
equivalent. I am currently reading up on how to replace the modal
dialog calls with the more modern equivalents. I probably should
convert the code to the application event loop. I am a bit scared
as I have a lot of processing happening adjusting the cursor during
the null event process. This is a graphical editor, so the mouse
needs to change shape when inside a region, The region is dynamic
and when the mouse is over it the region can be clicked on and
dragged. That code has worked well for years, so I really really
do not want to re- write it as it looks to be several hundred lines
for just the mouseover code.
Note that you can use nib-based dialogs together with the classic
WaitNextEvent model, so you can continue to use your existing idle-
processing code if necessary. You don't need to use
RunApplicationEventLoop to use HIView-based windows.
-eric
RunAppModalLoopForWindow does the trick with implementing the various
modal dialogs for things like Zoom, Find and some preferences. The
only area where I am not clear is on disposing the dialog window and
handlers as I can find no API calls or code examples that show what to
dispose.
Specifically it is the constructors in the following sample code that I
am unsure as to how the handler UUPs are destructed as these seem to be
allocated inside the init function. I am terminating the window using
disposeWindow. I found the call CFRelease to clean up the CF strings I
am using to set and read the text fields in the dialogs.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden