Hi Szymon,
There's a builtin class in Shoes called Widget, so you have to be more
specific for Ruby to recognize your Widget class. Instead of
"Widget.do_something", try "::Widget.do_something" to specify the top level
scope. Hope that helps,

-tieg

On Thu, Jan 22, 2009 at 10:03 PM, Szymon Wrozynski <[email protected]> wrote:

> Hello everybody!
>
> I'm a new guy here, called SW (sw, esdoubleu, simon, Szymon, etc). I saw
> shoes yesterday or something and I like it very much. But I cannot handle
> one thing. Is it possible to create custom widgets in separate rb files and
> include them in the main shoes app file?
> I saw the tricks with gems and activerecord-like things. Also I think the
> 'require' will work normally with normal (standard) ruby files, but I cannot
> use a custom widget class defined in other file than the main (startup)
> shoes file. The console tells me the Widget is unknown constant so it seems
> the Shoes is processing the required file outside its core?
>
> Any help will be appreciated.
>
> regards
>
> sw
>
> PS. I'm hacking (also) my English (it's not my native), so please do not
> mind possible bugs ;)
>

Reply via email to