|
From: Thomas Guyot-S. <Th...@za...> - 2007-07-24 16:20:22
|
> -----Original Message----- > From: cac...@li... [mailto:cacti-user- > bo...@li...] On Behalf Of Larry Adams > Sent: July 23, 2007 19:14 > To: Support requests/questions about cacti > Subject: Re: [cacti-user] Cacti 'Zoom on graphs' feature isn't activated > for Opera browsers > > J.P. Pasnak wrote: > > Thomas Guyot-Sionnest wrote: > > > >> Hi list, > >> > >> > >> This is something trivial but should definitely get fixed. Using Opera > I > >> must fake the user-agent as Firefox to be able to zoom on graphs. > >> > >> > > > > Best bet would be to submit a bug report : http://bugs.cacti.net > > > > > What version of Cacti. I thought this was fixed a few versions ago. > > TheWitness Latest version: 0.8.6j I didn't look deeply into it as I never did js programming, but looks like the only difference is that it performs different actions when the browser type is Netscape (Mozilla in the user-agent). Considering that IE isn't following standards and that we can IMHO safely assume that unknown browsers are following web standards (and eventually hack around reported incompatibilities) I believe we should rather perform the different actions when the browser is IE. I.e. change this: if (gBrowserObj.browser == "Netscape") { RightButtonPressed = (this.event.which == 3); // alert ("Net"); } else { RightButtonPressed = (this.event.button == 2); } to this: if (gBrowserObj.browser == "IE") { RightButtonPressed = (this.event.button == 2); } else { RightButtonPressed = (this.event.which == 3); // alert ("Net"); } everywhere it applies... Thanks, Thomas |