Thursday, April 21, 2011

backporting NSWindowDelegates windowDidEndLiveResize behaviour in OSX 10.5?

While 10.6 introduced the neat - windowDidEndLiveResize: et al for NSWindowDelegate, i need similar behaviour in 10.5 to avoid constantly invoking heavier functions via - windowDidResize:.
Currently i can only think of a timer-based solution (i.e. checking in short intervals for when the last resize occured), which seems ugly.

Is there a better way to support that? Or at least a way to get the specific mouse-down/-up events on the resize control?

From stackoverflow
  • You can try querying the inLiveResize method from the content view of the window. When the window is resized, its content view is resized as well.

    Georg Fritzsche : Ah, views already had events like `viewDidEndLiveResize` since 10.1 - thank you.


Post a Comment