Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Applications > Movies widget still has letters problem

Movies widget still has letters problem
Thread Tools
peeb
Addicted to MacNN
Join Date: Mar 2006
Status: Offline
Reply With Quote
May 24, 2008, 06:43 PM
 
How hard can it be to get this right?

     
TETENAL
Addicted to MacNN
Join Date: Aug 2004
Location: FFM
Status: Offline
Reply With Quote
May 24, 2008, 08:34 PM
 
Originally Posted by peeb View Post
How hard can it be to get this right?
Since the widget is JavaScript it comes with the source code. If it's not hard to fix, just do so yourself.
     
rickey939
Addicted to MacNN
Join Date: Jul 2005
Location: Cooperstown '09
Status: Offline
Reply With Quote
May 24, 2008, 10:52 PM
 
I simply won't put up with this kind of mediocre programming Apple.

     
turtle777
Clinically Insane
Join Date: Jun 2001
Location: planning a comeback !
Status: Offline
Reply With Quote
May 24, 2008, 11:01 PM
 
What's a "programming Apple" ?

-t
     
rickey939
Addicted to MacNN
Join Date: Jul 2005
Location: Cooperstown '09
Status: Offline
Reply With Quote
May 24, 2008, 11:08 PM
 
Originally Posted by turtle777 View Post
What's a "programming Apple" ?

-t
Smart fruit.
     
turtle777
Clinically Insane
Join Date: Jun 2001
Location: planning a comeback !
Status: Offline
Reply With Quote
May 24, 2008, 11:12 PM
 
Originally Posted by rickey939 View Post
Smart fruit.
I prefer dumb meat. Pork, beef, chicken. Anything.

-t
     
peeb  (op)
Addicted to MacNN
Join Date: Mar 2006
Status: Offline
Reply With Quote
May 25, 2008, 12:01 PM
 
Originally Posted by TETENAL View Post
Since the widget is JavaScript it comes with the source code. If it's not hard to fix, just do so yourself.
Are you serious? Even if I wanted to do that, what about every other instance of this widget?
     
TETENAL
Addicted to MacNN
Join Date: Aug 2004
Location: FFM
Status: Offline
Reply With Quote
May 25, 2008, 12:39 PM
 
Here you go:

Make a copy of the Movies widget into your own ~/Library/Widgets and change line 1201 of ~/Library/Widgets/Movies/Movies.js from

movieObjectForMovieElement.anTheRegex = /^(the|an)\s*(.+)/im;

to

movieObjectForMovieElement.anTheRegex = /^(the |an )\s*(.+)/im;
( Last edited by TETENAL; May 26, 2008 at 10:27 AM. Reason: obsolete fix - see below)
     
ghporter
Administrator
Join Date: Apr 2001
Location: San Antonio TX USA
Status: Offline
Reply With Quote
May 25, 2008, 01:49 PM
 
It's really just one space that goofs it up? Amazing. That sort of thing is trivial to fix—if you find it and identify that it's a problem. But then, it's trivial for anyone to fix, so until Apple fixes this, why not do it yourself?

One question though: how do you drill down through the widget wrapper to get at the .js file?

Glenn -----OTR/L, MOT, Tx
     
TETENAL
Addicted to MacNN
Join Date: Aug 2004
Location: FFM
Status: Offline
Reply With Quote
May 25, 2008, 02:22 PM
 
Originally Posted by ghporter View Post
One question though: how do you drill down through the widget wrapper to get at the .js file?
"Show package contents" from either the action menu or the contextual menu.
     
rickey939
Addicted to MacNN
Join Date: Jul 2005
Location: Cooperstown '09
Status: Offline
Reply With Quote
May 26, 2008, 12:14 AM
 
Neat.
     
ghporter
Administrator
Join Date: Apr 2001
Location: San Antonio TX USA
Status: Offline
Reply With Quote
May 26, 2008, 09:27 AM
 
Uh.....I knew that. We'll go with that instead of a really big "duh!" OK? Thanks!



I actually did know how to do this a while back, but I haven't used it and I forgot. I think that may be worse than just not seeing an option on a context menu...

Glenn -----OTR/L, MOT, Tx
     
turtle777
Clinically Insane
Join Date: Jun 2001
Location: planning a comeback !
Status: Offline
Reply With Quote
May 26, 2008, 09:45 AM
 
Originally Posted by TETENAL View Post
Here you go:

Make a copy of the Movies widget into your own ~/Library/Widgets and change line 1201 of ~/Library/Widgets/Movies/Movies.js from

movieObjectForMovieElement.anTheRegex = /^(the|an)\s*(.+)/im;

to

movieObjectForMovieElement.anTheRegex = /^(the |an )\s*(.+)/im;
Well, I give you that this is NOT hard to fix once you know what's wrong, and definitely fixable for a programmer, so shame on Apple.

But when you said "If it's not hard to fix, just do so yourself.", did you really think users here would be able to track down the error and fix it themselves ?
I kind a feel stupid now.

-t
     
TETENAL
Addicted to MacNN
Join Date: Aug 2004
Location: FFM
Status: Offline
Reply With Quote
May 26, 2008, 10:27 AM
 
OK, I read up how regular expressions actually work, and I think the actual fix for this issue should be: change line 1201 of Movies.js from

movieObjectForMovieElement.anTheRegex = /^(the|an)\s*(.+)/im;

to

movieObjectForMovieElement.anTheRegex = /^(the|an)\s+(.+)/im;

It seems to be a simple mistake. It probably just hasn't been reported to Apple yet.
     
turtle777
Clinically Insane
Join Date: Jun 2001
Location: planning a comeback !
Status: Offline
Reply With Quote
May 26, 2008, 10:30 AM
 
Could you please highlight the change. I, uhm, don't see it

Edit: Ok, got it. s+ instead of s*.

-t
     
peeb  (op)
Addicted to MacNN
Join Date: Mar 2006
Status: Offline
Reply With Quote
May 26, 2008, 09:10 PM
 
Thanks for figuring out how to fix that - really useful.
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 12:25 PM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,