Hi,

Wolfgang Lux wrote:
Riccardo Mottola wrote:

is changeSaveType, undocumented, available on both Mac and GS? or is it some 
kind of extension? That would be the place probably where to add the 
view-swizzling code.
It is available on both Cocoa and GNUstep (otherwise, I wouldn't have suggested 
using it :-)

Indeed, it exists and works. I just get a warning when I call [super changeSaveType:sender] but it works as advertised (well from you, Apple keeps it hidden!). Perhaps the best thing would be to add/remove from the accessoryView the options for each file tye and make it totally dynamic.

Now  some further questions:
how do I get the current accessory view to modify it with my stuff? I could call "superview" on the sender which is the popupbutton, but it seems dirty. [savePanel accessoryView] ? I tried getting the accessoryView and making it larger, but it doesn't work, it is a NSBox, which makes sense under Mac. Perhaps the default one is not saved in accessoryView?

Second, in the changeSaveType method I need to know which filetype was selected. The document has not yet an updated fileType (hence the need of fileTYpeFromLastRunSavePanel of course). A way would be to read directly the contents of the popupbutton, but perhaps there is a cleaner way. It appears to have the document name.

It looks like I have a clear idea of what to do, but getting list in the implementation details, I hate this!

Riccardo

_______________________________________________
Discuss-gnustep mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnustep

Reply via email to