[Rails-spinoffs] Event.pointerX and Firefox

2006-01-11 Thread Deco Rior
Is there a problem with Event.pointerX and Firefox? Safari and IE are working fine, but Firefox does not return a position. Also is there any way to get the position of the mouse click relative to the div that it was clicked in? Deco ___ Rails-spi

RE: [Rails-spinoffs] Good OOP and JS books / tutorials? Looking toteach my team

2006-01-11 Thread Alister Cameron
John,   I would recommend you check out the stuff over at sitepoint.com. Their books are typically very good quality, although I am not familiar with a specific title in that area.   www.sitepoint.com   - Alister From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Joseph Potenz

Re: [Rails-spinoffs] Wiki Gripe

2006-01-11 Thread Thomas Fuchs
Heya,Expect the switch to be happening very soon--I know I said before that the wiki was just about to be fixed,but this time it's really, really for real. :)So, it's just a few more days...-ThomasAm 11.01.2006 um 23:07 schrieb Ryan Gahl: I know this isn’t productive, but I must say that I absolute

Re: [Spam] Re: [Rails-spinoffs] Wiki Gripe

2006-01-11 Thread Jaimz
if i made a wiki out of php would you guys consider the change? we need to do something, it seems like it only goes down when i really need the docs :| -jaimz ___ Rails-spinoffs mailing list Rails-spinoffs@lists.rubyonrails.org http://lists.rubyonra

Re: [Rails-spinoffs] Prototype & Cookies

2006-01-11 Thread Martin Bialasinski
Actually, scratch the previous post, use this one: /* ** ++ Methods to use with Cookiejar: ** ** var kekse = new Cookiejar(cookieJarName, CookiePath) ** This is the constructor.cookieJarName is the name of the collection of ** cookies you would like to associate with this

Re: [Rails-spinoffs] divider id of container

2006-01-11 Thread Jonathan Koren
On Wed, 2006-01-11 at 12:06 -0400, Francisco Calderon wrote: > Hi there, i need to drag an draggable element to an child div node > inside an another div container, but i create the child node dynamicly > with ids like ' div_ + i ' where 'i' is a incremental variable, thats > the problem because i

Re: [Rails-spinoffs] Prototype & Cookies

2006-01-11 Thread Martin Bialasinski
On 11/01/06, Maninder, Singh <[EMAIL PROTECTED]> wrote: > Basically, what I am looking for is if there is an easy way to store mutiple > cookies in a single cookie using hash or something - easy writing and > retrieval (updating the cookie value). How about this for a start: /* ** ++ Metho

[Rails-spinoffs] Good OOP and JS books / tutorials? Looking to teach my team

2006-01-11 Thread Joseph Potenza
Can anyone recommend good books, online tutorials, or any other learning materials for _javascript_ - specifically Object Oriented Programming using JS?   I want the rest of my dev team to be able to help me code in JS, specifically using prototype and scriptaculous.  I've been using JS for

Re: [Rails-spinoffs] Wiki Gripe

2006-01-11 Thread Tom ...
I find the quality of the documentation to be pretty good, but yes, the reliability leaves more to be desired. Tom. ___ Rails-spinoffs mailing list Rails-spinoffs@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

Re: [Rails-spinoffs] Wiki Gripe

2006-01-11 Thread Martin Bialasinski
On 11/01/06, Ryan Gahl <[EMAIL PROTECTED]> wrote: > I know this isn't productive, but I must say that I absolutely hate the > wiki. I've never been able to use it for more than a couple minutes before > it completely farts out. Yes, not a too nice situation. The other thing about it is that the w

Re: [Rails-spinoffs] extending the Element.prototype to provide a setAttributes function

2006-01-11 Thread Martin Bialasinski
On 11/01/06, Jeremy Kitchen <[EMAIL PROTECTED]> wrote: > On a side note, it appears that firefox is the most liberal about allowing the > extension of DOM prototypes, since I had a similar issue previously with > trying to add an instance method to the HTMLSelectElement prototype :( In Internet E

[Rails-spinoffs] Wiki Gripe

2006-01-11 Thread Ryan Gahl
I know this isn’t productive, but I must say that I absolutely hate the wiki. I’ve never been able to use it for more than a couple minutes before it completely farts out. Please fix the wiki!   Sincerely, Ryan Gahl Design Engineer Camtronics Medical Systems (an Emageon Company) [EMAI

RE: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Ryan Gahl
=) Sorry. I was talking about using the prototype.js library for object creation and inheritance (it ships with script.aculo.us) If I had more time today (busy now), I'd write you up an example based on your code. But for now, maybe check into the prototype library... once you learn object oriente

Re: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Tom ...
I'm happy with PHP object programming but don't even know where to start in Javascript, let alone extending a class. Tom On 1/12/06, Ryan Gahl <[EMAIL PROTECTED]> wrote: > Oh, now I see. Try creating a separate class that contains that > behavior, and extending each menu div (or whatever element

RE: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Ryan Gahl
Oh, now I see. Try creating a separate class that contains that behavior, and extending each menu div (or whatever element they are), with that class... then you can use "this" within the functions to check the locked status of the individual menu. -Original Message- From: [EMAIL PROTECT

Re: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Tom ...
Stay me away from eval! Well, I don't see why, but I know the general idea that it is bad. function showProjectMenu(id) { if (menusUnlocked == 'yes') { Effect.BlindDown('project' + id); lockMenus(); $('project' + id + '_link').onclick=function() { hideProjectMenu(id) } $('project

RE: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Ryan Gahl
Try the eval statement... might work... function lockMenu(menuId) { eval("var menu_" + menuId + " = true;"); } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Tom ... Sent: Wednesday, January 11, 2006 3:07 PM To: rails-spinoffs@lists.rubyonrails.o

Re: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Tom ...
I'm pretty new to Javascript (PHP is my specialty), is there a way to make 'variable variables' ( http://nz.php.net/manual/en/language.variables.variable.php ). Say I have this function: function lockMenu(menuId) { var menu_*menuId* = true; } If I ran lockMenu('myAccount'), I'd like the vari

Re: [Rails-spinoffs] DataGrid (Table) using tables/Scriptaculous Sortable

2006-01-11 Thread Deco Rior
Can't help you with a new mac! BUt glad to help... Deco On Jan 11, 2006, at 12:46 PM, Lindsey Simon wrote: Nice start! A few things: 1. On Safari the dragging seems to work intermittently. I can do some more testing, but it seems to have trouble dragging over the next column. 2. On Safari

RE: [Rails-spinoffs] RE: Event.observer - unordered list problems

2006-01-11 Thread Ryan Gahl
I just realized I made a mistake… in the first numbered solution, the != should be ==   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ryan Gahl Sent: Wednesday, January 11, 2006 2:28 PM To: [EMAIL PROTECTED]; rails-spinoffs@lists.rubyonrails.org Subject: [Rails-sp

[Rails-spinoffs] RE: Event.observer - unordered list problems

2006-01-11 Thread Ryan Gahl
Hi Marco (I forwarded this also to the mailing list and removed the picture as it wasn’t necessary to include to the mailing list so everyone can hear the general techniques),   I recently had a very similar problem with my project. The problem arises because whenever you move the mouse t

Re: [Rails-spinoffs] extending the Element.prototype to provide a setAttributes function

2006-01-11 Thread Jeremy Kitchen
On Wednesday 11 January 2006 10:34, Jeremy Kitchen wrote: > Hi folks, I'm pretty new to javascript and prototype, so I just want to get > some peer-review on a function I wrote that makes a handy (at least, it > seems handy) way to set a group of attributes on an element easily. > > Object.extend(E

Re: [Rails-spinoffs] DataGrid (Table) using tables/Scriptaculous Sortable

2006-01-11 Thread Lindsey Simon
> Nice start! > > A few things: > > 1. On Safari the dragging seems to work intermittently. I can do some > more testing, but it seems to have trouble dragging over the next > column. > 2. On Safari it also caused my browser to quit! > 3. The column sort would be better if it behaved like

[Rails-spinoffs] DataGrid (Table) using tables/Scriptaculous Sortable

2006-01-11 Thread Lindsey Simon
Hey yall, I wanted to share some code I've been working on as it seems up the alley of folks on this list. It's not rails, per se, but one day... DataGrid: http://development.finetooth.com/?p=6 This also showcases the option.delay perameter I've submitted into scriptaculous - hold down your mou

Re: [Rails-spinoffs] DataGrid (Table) using tables/Scriptaculous Sortable

2006-01-11 Thread Deco Rior
Nice start! A few things: 1. On Safari the dragging seems to work intermittently. I can do some more testing, but it seems to have trouble dragging over the next column. 2. On Safari it also caused my browser to quit! 3. The column sort would be better if it behaved like mochisort (At le

RE: [Rails-spinoffs] extending the Element.prototype to provideasetAttributes function

2006-01-11 Thread Ryan Gahl
No problem, also check out bindAsEventListener for attaching functions to element events, still maintaining your object as the "this" in the event handler scope at the same time having access to the originating "event" object. In case you haven't found this resource yet: http://www.sergiopereira.c

Re: [Rails-spinoffs] extending the Element.prototype to provide asetAttributes function

2006-01-11 Thread Jeremy Kitchen
On Wednesday 11 January 2006 10:58, Jeremy Kitchen wrote: > On Wednesday 11 January 2006 10:50, Ryan Gahl wrote: > > No comment on the usefulness of your function, as I've yet to try it. > > But for the "this" scope problem, try this... (removed your var and > > added the bind(this) after the funct

Re: [Rails-spinoffs] extending the Element.prototype to provide asetAttributes function

2006-01-11 Thread Jeremy Kitchen
On Wednesday 11 January 2006 10:50, Ryan Gahl wrote: > No comment on the usefulness of your function, as I've yet to try it. > But for the "this" scope problem, try this... (removed your var and > added the bind(this) after the function declaration. I didn't test it > though so you might want to gi

Re: [Rails-spinoffs] Prototype & Cookies

2006-01-11 Thread Jeremy Kitchen
On Wednesday 11 January 2006 10:35, Maninder, Singh wrote: > Has anyone written any "cookie" class using prototype? > > Basically, what I am looking for is if there is an easy way to store > mutiple cookies in a single cookie using hash or something - easy writing > and retrieval (updating the cook

RE: [Rails-spinoffs] extending the Element.prototype to provide asetAttributes function

2006-01-11 Thread Ryan Gahl
No comment on the usefulness of your function, as I've yet to try it. But for the "this" scope problem, try this... (removed your var and added the bind(this) after the function declaration. I didn't test it though so you might want to give it whirl. It might introduce a different scope problem wit

[Rails-spinoffs] Prototype & Cookies

2006-01-11 Thread Maninder, Singh
Title: Re: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks Has anyone written any "cookie" class using prototype? Basically, what I am looking for is if there is an easy way to store mutiple cookies in a single cookie using hash or something - easy writing and retrieval (upd

[Rails-spinoffs] extending the Element.prototype to provide a setAttributes function

2006-01-11 Thread Jeremy Kitchen
Hi folks, I'm pretty new to javascript and prototype, so I just want to get some peer-review on a function I wrote that makes a handy (at least, it seems handy) way to set a group of attributes on an element easily. Object.extend(Element.prototype, { setAttributes: function(attrs) { var el

Re: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Andrew Kaspick
I think there's a way to check if an effect is running, but am not 100% on what it is exactly. The effect does have a state var that should be set to 'finished' when it's done, but there is no method to check for that, so I'm not sure if it's recommended to use or not. if you do var e = new Effec

[Rails-spinoffs] divider id of container

2006-01-11 Thread Francisco Calderon
Hi there, i need to drag an draggable element to an child div node inside an another div container, but i create the child node dynamicly with ids like ' div_ + i ' where 'i' is a incremental variable, thats the problem because i need get the id of this child nodes to manipulate it, somebody knows

RE: [Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Gregory Hill
Generally I just keep track of whether it's open or not in a variable and check that variable before creating a new animation. So, only do the animation if the menu isn't open. Greg > -Original Message- > From: [EMAIL PROTECTED] [mailto:rails-spinoffs- > [EMAIL PROTECTED] On Behalf Of To

Re: [Rails-spinoffs] Getting the position of the draggable element?

2006-01-11 Thread Deco Rior
Thanks,I am getting better at this! Is there a simple way to get the position within the element that was clicked?DecoOn Jan 11, 2006, at 12:25 AM, Brian Peiris wrote:This page will give you the position of the mouse when the element is dropped.script.aculo.us Drag and drop functional t

[Rails-spinoffs] switching two nodes

2006-01-11 Thread Tarek Ziadé
Hi, Is there a simple api in scriptaculous or prototype, to simply switch two nodes in the dom tree ? or do i have to code it. (a sweet option would be to be able to hook an effect as well) My use case is to drag and drop elements to switch them Regards Tarek-- Tarek Ziadé | www.afpy.orgPython

[Rails-spinoffs] [scriptaculous] Intermitently Disabling Clicks

2006-01-11 Thread Tom ...
I have button that slides down a menu using Effect.BlindDown, but the function that slides it down also makes it so that the opening link now slides the menu back in. If the user double clicks the link (thuse opening & closing immediatley) the slide animation breaks, then will not extend correctly