kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #17028
Re: OS X File Open Dialog
Bernhard,
I committed your patch in the product branch r5446. I fixed some coding
policy issues before I committed it. Thank you for your contribution.
Cheers,
Wayne
On 2/21/2015 1:37 PM, Bernhard Stegmaier wrote:
> Hi Wayne,
>
> I have seen that a fix for the second issue with the filters enabled in
> KiCad is on its way for wxWidgets… [1].
> So, original patch/fix should be included so that it will work again as
> soon as somebody uses an appropriate wxWidgets.
>
> Attached is a patch based on the original proposal just setting the
> wxWidgets config in
> bool PGM_BASE::initPgm()
>
> If you think there is a more appropriate global initialization place to
> put it in, just tell me where it should be.
>
>
> Regards,
> Bernhard
>
> [1] https://github.com/wxWidgets/wxWidgets/commit/ef5232d289f792dcdba163aa56cd9d47731dbffc#diff-4c33f04f2d98bef24c5f526f6fa79d33
>
>
>
>
>> On 05.01.2015, at 14:23, Wayne Stambaugh <stambaughw@xxxxxxxxx
>> <mailto:stambaughw@xxxxxxxxx>> wrote:
>>
>> Would one of the OSX devs please validate this patch to see if it
>> resolves the OSX file open dialog issue and let me know so I can commit
>> this patch?
>>
>> Thanks,
>>
>> Wayne
>>
>> On 1/3/2015 3:06 PM, Paulo Henrique Silva wrote:
>>> Hi Bernard,
>>>
>>> Different from the patch I have added the code to
>>> bool PGM_BASE::initPgm()
>>> because this seems to be one of the more global spots to initialize
>>> things.
>>> I am not sure about that… in kiface_i.cpp
>>> bool KIFACE_I::start_common( int aCtlBits )
>>> would also maybe appropriate?
>>>
>>> But… even if it brings back the filter drop down, it doesn’t seem to
>>> work with wxWidgets 3.0.2.
>>> The
>>> <<<
>>> wxFileDialog dlg( aParent, _( "Open Board File" ), path, name,
>>> fileFilters,
>>> wxFD_OPEN | wxFD_FILE_MUST_EXIST );
>>>
>>> if( dlg.ShowModal() != wxID_CANCEL )
>>> {
>>> int chosenFilter = dlg.GetFilterIndex();
>>>>>>
>>> dlg.GetFilterIndex() always return 0 regardless from what I choose.
>>> Moreover, changing the filter does not affect the file list at all
>>> (from the wxWidgets code it should…).
>>> I guess files not matching the current filter should get greyed out,
>>> but always all supported files are enabled.
>>>
>>> So, this doesn’t really seem to fix the original problem - at least
>>> on both my 10.9 and 10.10 setup.
>>> Can somebody else confirm this?
>>>
>>>
>>> You are right.
>>>
>>> I dig a little and the real issue seems to be on wxWidgets. I filled a
>>> bug on wxWidgets (still being moderated). The wxWidgets patch is
>>> attached here together with my original change now applied at
>>> PGM_BASE::initPgm as you did.
>>>
>>> I tested it on OX 10.10 and it works as expected now. Patch cleanly
>>> applied on wxWidgets 3.0.2 and wxPython 3.0.2.0.
>>>
>>> Sorry to miss the wxWdgets issue.
>>>
>>> Cheers,
>>>
>>> -- Paulo Henrique
>>> -- Curta Circuitos
>>>
>>>
>>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~kicad-developers
>> Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
>> <mailto:kicad-developers@xxxxxxxxxxxxxxxxxxx>
>> Unsubscribe : https://launchpad.net/~kicad-developers
>> More help : https://help.launchpad.net/ListHelp
>
References