From: Eloy D. <e....@su...> - 2008-02-02 14:09:11
|
Hey Michal, Well that depends of course on what kind of data it is etc. And I think you'll have more success with this question on either a =20 pure ruby or cocoa mailing list. You could save it through conventional ruby ways, maybe Marshal #dump/=20= #load, which is more of a ruby-lang ml question. Or through cocoa ways, in which case this would be more of a question =20= for the cocoa-dev ml. Anyway, I would advice you to at least write a bit more context of =20 what it is that you are trying to save and if you have special =20 requirements. Eloy. On 2 feb 2008, at 15:01, Michal Malinowski wrote: > Hey! > > I'll try it later. But I got next question, I have data in " =20 > @@bundle =3D [@@bz1, @@bz2, @@bz3, @@bo1, @@bo2, @@bo3, @@czas, =20 > @@zakloceniabz1, @zakloceniabz2, @zakloceniabz3, @regulator]" and I =20= > need to save it to file, and read it from that file too. So mayby =20 > some clues. Thanks for any help. > > Best Regards Michal > Wiadomo=C5=9B=C4=87 napisana w dniu 2008-02-02, o godz 14:27, przez = Eloy =20 > Duran: > >> Hi Michal, >> >> Well it seems that you are sending the #bounds=3D message >> to the NSApplication instance rather than to a Game instance. >> >> This is the code: >> >> class GameView < OSX::NSView >> ib_outlets :game >> >> def awakeFromNib >> window.setOpaque(false) >> @game.bounds =3D bounds >> @timer =3D =20 >> OSX=20 >> ::NSTimer=20 >> .scheduledTimerWithTimeInterval_target_selector_userInfo_repeats_=20 >> (1.0/60.0, self, :tick, nil, true) >> end >> end >> So the line that's causing the error is: "@game.bounds =3D bounds" >> because if an objc object does not respond to a setter method, in =20 >> this case #bounds=3D(val), >> RubyCocoa will try to turn it into a objc (old) style setter =20 >> method, which would be #setBounds(val). >> So maybe you have connected the ib_outlet to the wrong object in IB? >> >> Hope this helps. >> >> Eloy >> On 2 feb 2008, at 11:50, Michal Malinowski wrote: >> >>> Hey! >>> I got that Rubyrocks example from = http://www.rubycocoa.com/ruby-rocks/=20 >>> and I got problem while I'm Building program. The problem from =20 >>> console is >>> 2008-02-02 11:47:08.890 grafika1[653:10b] GameView#awakeFromNib: =20 >>> OSX::OCMessageSendException: Can't get Objective-C method =20 >>> signature for selector 'setBounds:' of receiver =20 >>> #<OSX::NSApplication:0x2d348 class=3D'NSApplication' id=3D0x3e79e0> >>> >>> Best Regards Michal >>> = ------------------------------------------------------------------------- >>> This SF.net email is sponsored by: Microsoft >>> Defy all challenges. Microsoft(R) Visual Studio 2008. >>> = http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/___________________= ____________________________ >>> Rubycocoa-talk mailing list >>> Rub...@li... >>> https://lists.sourceforge.net/lists/listinfo/rubycocoa-talk >> >> = ------------------------------------------------------------------------- >> This SF.net email is sponsored by: Microsoft >> Defy all challenges. Microsoft(R) Visual Studio 2008. >> = http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/___________________= ____________________________ >> Rubycocoa-talk mailing list >> Rub...@li... >> https://lists.sourceforge.net/lists/listinfo/rubycocoa-talk > > = ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > = http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/___________________= ____________________________ > Rubycocoa-talk mailing list > Rub...@li... > https://lists.sourceforge.net/lists/listinfo/rubycocoa-talk |