← Back to team overview

kicad-developers team mailing list archive

Re: OSX Patch review request

 

emmedics4 a écrit :
>>  
>>
>> This fixes a couple of problems:
>> The first was the possibility to the window taskbar to go under 
>>the fixed menubar making impossible manage the window.
>I do not understand this first patch.
>*The full code is:
> // Ensure Window title bar is visible
>#if defined( __WXMAC__ ) && !defined( __WXOSX_COCOA__ )
> // for macOSX, the window must be below system (macOSX) toolbar
> Ypos_min = GetMBarHeight();
>#else
> Ypos_min = 0;
>#endif
> if( m_FramePos.y < Ypos_min )
> m_FramePos.y = Ypos_min;

>so under MACOSX the compiled line is
> Ypos_min = GetMBarHeight();
>and not
> Ypos_min = 0;
>that is only for Windows and Linux.
>This is not the case then the line
>#if defined( __WXMAC__ ) && !defined( __WXOSX_COCOA__ )
>has a problem.
>Can you see this problem ?

Yes i can see the problem, asking a review was a good choice ;).
My problem at the moment is the partial desupport of the Carbon API in the new versions of OSX.
GetMBarHeight() is no more supported on newer OS and the new equivalent APIrequires Objective-C (Using a .mm file).
So i prefer at this point use a constant of 20 instead calling GetMBarHeight() and remove the __WXOSX_COCOA__ discrimination leaving only __WXMAC__.


>> The second was to avoid to use MenuID 0 as asserts wxwindows (on >>Mac is impossible to use MenuID = 0)
>Committed.
Thank you!

--
Marco







References