Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traffic light buttons #207

Open
kalvish21 opened this issue Aug 29, 2016 · 2 comments
Open

Traffic light buttons #207

kalvish21 opened this issue Aug 29, 2016 · 2 comments

Comments

@kalvish21
Copy link
Contributor

I use the default traffic light buttons on OSX. For some strange reason when I do beginSheet on my app and show an NSWindow, the traffic light buttons go to the top. Right now the height is 38 on the titleBar.

Is there a way to fix this?

@fancymax
Copy link

@kalvish21

a workaround here(Swift):

        let aWindow = self.window as! INAppStoreWindow
        aWindow.titleBarDrawingBlock = {[unowned self] drawsAsMainWindow, drawingRect, edge, clippingPath  in
            NSNotificationCenter.defaultCenter().postNotificationName(NSWindowDidMoveNotification, object:self.window)
        }

@kalvish21
Copy link
Contributor Author

Can I know waht this code does? and which version of swift?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants