Show WiFi signal information in the AirPort Menu Item

3/12/2007

From TidBITS Networking:

Leopard includes more information about Wi-Fi networks in the vicinity of your computer than meets the eye. Mac OS X 10.5 updates the AirPort menu in the system menu bar after you select, which is a neat feature and provides more accurate results. It also shows a lock icon next to networks protected by some form of encryption. But you can extract more information by holding down the Option key while selecting the menu.

Neat trick, although it would be more useful if it showed details for all the networks in range, instead of just the connected network.

No Comments

Checking the OS X operating system version in Leopard

11/11/2007

One of the changes I made to Runner’s Log recently is a small update to some drawing code to better match the new look and feel of Leopard. Since I’m still supporting OS X 10.4, I had to determine at run time what operating system I’m running under. There are a few ways to do this, but the best method I found was to use the Gestalt system call:

SInt32 version = 0;
Gestalt( gestaltSystemVersion, &version );

if ( version >= 0x1050 )
{
// New Leopard specific drawing code.
}
else
{
// Old drawing code.
}

Easy enough; see this Cocoadev page for more information, including checking for older versions of Mac OS X. If it’s just API calls in the operating system you’re worried about, you can just check the function pointer for a null value before calling it. See the Cross-Development Programming Guide for more information.

1 Comment

Runner’s Log and OS X 10.5

5/11/2007

UPDATE: All Leopard bugs have been fixed! Grab the new version of Runner’s Log here.

Just a heads-up for any Runner’s Log users planning on upgrading to Leopard. I’ve just begun testing, and it looks like there are a few unfortunate bugs that need to be resolved. I’ve started working on an update to fix these issues, which I hope will be ready early this week. The next major update to Runner’s Log, which includes several new features as well as bug fixes, will be fully compatible with OS X 10.5 as well as OS X 10.4.

I apologize for any inconvenience this has caused anyone!

No Comments

Leopard development links

29/10/2007

Mac OS X 10.5 Leopard: the Ars Technica review:

DTrace and Xray invite good questions. “How many files does my application open on launch?” “How many times is a particular function called?” “What does the memory usage of my application look like over time?” DTrace and Xray make the previously daunting task of answering these questions almost trivial and (dare I say it) fun. I can’t imagine any Mac developer seeing Xray and not instantly longing to sic it on his application.

A Quick Objective-C 2.0 Tutorial:

There’s a lot more ground to cover, but this should give you a good start. We can look at more advanced topics in future tutorials. The 64-bit runtime has some features that the 32-bit version does not, such as the ability to synthesize instance variables. All of the hardware Apple currently ships is 64-bit, but we’re a ways off from 64-bit being a majority of the installed base.

Remember that all of the new features in Objective-C 2.0 are optional. Aside from some lower-level runtime functions and hacks, anything that was valid code in Objective 1.x is valid in 2.0, as well.

Get rid of your code with Leopard:

I’ve been using Leopard for the last few months, and I thought I’d post a partial list of new and improved APIs which may be of interest to Cocoa application developers. I’m going to classify these in terms of what you can do with them, rather than by class-name or other such relatively obscure aspect, and I’ll include some screenshots where appropriate. Please feel free to add your own observations via the comments. I’ll stick roughly to the order used in the AppKit and Foundation release notes, which you should also read if you’re serious about getting the skinny on what’s new in Leopard.

No Comments