Implementation quirks of Safari on Windows

June 14th, 2007

Some speculate that Apple is porting Carbon to Windows. It started with iTunes and QuickTime, and now continues with Safari. I don’t know the implementation details, and how rich are the Windows APIs that Apple uses (I’ve been able to run Safari not only on XP and Vista, but also on Windows 2003), but there are some interesting visual quirks. To see what i’m talking about, resize Safari window and move it to the lower left part of your screen. Now, double click the title bar and watch the top part of the screen closely. It takes about 2-3 seconds, during which Safari is all over the place. Here is the screenshot of what happens under Windows 2003 (click to view fullsize version):

safari-maximizing.png

Before you say that 2003 is not officially supported, pretty much the same is happening under Vista (except the title pane buttons). As you can see, the original window is split halfway, showing the right part right next to the screen top border, the title pane buttons are replicated, and the toolbars are maximized ahead of the main window itself. Does this mean that each part of Safari “header” is implemented as a top-level window, which are then carefully “glued” together to create an illusion of a seamless window? I’ve never seen a Windows application behave like this, not one written in Win32, not one written in Delphi and not one written in Java.