|
From: Yvon T. <tho...@fr...> - 2006-02-08 11:43:28
|
Le 8 f=E9vr. 06 =E0 11:01, Jonathan Paisley a =E9crit :
>
> I'm confused - isn't it just about the same? You're calling through =20=
> to the same Cocoa methods underneath. Could you give an example of =20
> the differences in complexity?
>
ruby-side open a sheet :
def prefsSheetOpen(sender)
OSX::NSApp=20
().beginSheet_modalForWindow_modalDelegate_didEndSelector_contextInfo=20
(@prefsSheet, @mainWindow, self, nil, nil)
end
java-side open a sheet :
public void bottleSheetViewOpen() {
=
NSApplication.sharedApplication().beginSheet(bottleSheetView, =20
mainWindow,null,null,null);
}
i don't understand clearly why this part =20
"_modalForWindow_modalDelegate_didEndSelector_contextInfo" is needed =20
for ruby...
oups i see in java you might have more than one method named =20
"beginSheet" depending on args number and types, afaik, in ruby it =20
isn't possible, the reason for...
somehow rubyCocoa syntax is closer to ObjC ones than Java...
best,
Yvon=
|