Closed Bug 305608 Opened 19 years ago Closed 18 years ago

Edit Card window in Address Book does not exit on clicking OK

Categories

(SeaMonkey :: MailNews: Address Book & Contacts, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: samjnaa, Unassigned)

References

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20050822 SeaMonkey/1.0a
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20050822 SeaMonkey/1.0a

Well I don't know in which nightly this bug was broken but in the one I have
(20050822 - yesterday's) when I open an Address Book item to change some details
then hit the OK button on the Edit Card window (irrespective of whether I really
changed any details or not) it refuses to close the window though any changes I
have made are committed. I have to hit Cancel to close the window. This is
highly abnormal and should be fixed ASAP, IMHO.

Reproducible: Always

Steps to Reproduce:
1. Goto Address Book
2. Open an address card
3. Optionally edit anything
4. Hit OK

Actual Results:  
Any changes I made were committed, but the Edit Card window did not close.

Expected Results:  
After committing any changes, it should have closed the window.
This worksforme with build 2005-08-23-06 on Windows XP SeaMonkey trunk.

Can you go to Tools | Web Development | JavaScript Console and see if anything
related shows up there?  Please paste any Address-Book related exceptions or
errors, thanks!
Version: unspecified → Trunk
Stephen, thanks for responding. Here's the JSC copy&paste:

Error: Unknown namespace prefix 'html'.  Ruleset ignored due to bad selector.
Source File: chrome://messenger/skin/addressbook/addressbook.css
Line: 210
---
Error: Unknown namespace prefix 'html'.  Ruleset ignored due to bad selector.
Source File: chrome://messenger/skin/addressbook/addressbook.css
Line: 216
---
Error: uncaught exception: [Exception... "Component returned failure code:
0x80520012 (NS_ERROR_FILE_NOT_FOUND) [nsIPrefBranch.getComplexValue]"  nsresult:
"0x80520012 (NS_ERROR_FILE_NOT_FOUND)"  location: "JS frame ::
chrome://messenger/content/addressbook/abCardViewOverlay.js :: <TOP_LEVEL> ::
line 50"  data: no]
---
Error: gAddrbookSession has no properties
Source File: chrome://messenger/content/addressbook/abCardViewOverlay.js
Line: 197
---
Error: uncaught exception: [Exception... "'[JavaScript Error: "gAddrbookSession
has no properties" {file:
"chrome://messenger/content/addressbook/abCardViewOverlay.js" line: 197}]' when
calling method: [nsIAbViewListener::onSelectionChanged]"  nsresult: "0x80570021
(NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)"  location: "JS frame ::
chrome://messenger/content/addressbook/addressbook.xul :: onselect :: line 1" 
data: yes]
---
Error: gAddrbookSession has no properties
Source File: chrome://messenger/content/addressbook/abCardViewOverlay.js
Line: 197
---
Error: uncaught exception: [Exception... "'[JavaScript Error: "gAddrbookSession
has no properties" {file:
"chrome://messenger/content/addressbook/abCardViewOverlay.js" line: 197}]' when
calling method: [nsIAbViewListener::onSelectionChanged]"  nsresult: "0x80570021
(NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)"  location: "JS frame ::
chrome://messenger/content/addressbook/addressbook.xul :: onselect :: line 1" 
data: yes]
---
Error: gAddrbookSession has no properties
Source File: chrome://messenger/content/addressbook/abCardViewOverlay.js
Line: 197

Looks like some of them are repeated but I c&p-ed them anyway. 'Twould be nice
if we had a Select All option in the JSC. Had to c&p each of these things manually.

I don't know if you'll need this, but I see some refs to "skin", so I'll report
that the theme I'm using is iCandy Junior by Aaron Spuler (www.spuler.us) with
the xulscrollbars.css patch from
http://forums.mozillazine.org/viewtopic.php?t=305665 to get the scrollbars to
show. I c&p-ed the xulscrollbars.css code from that thread onto my
userChrome.css and userContent.css.
Shriramana, are you using a content pack? other than US? You can check this
under preferences -> Apperance -> Languages/Content Packs.

The default is normally "US Region" for the content pack.

I expect in this case it is the content pack that is causing the problem. If
you're not on the default US Region (assuming it is available) can you switch
back to it and try the address book again?

And just in case you are using the "US Region" content pack, can you confirm
from about:config (in the URL bar) what the setting of the preference
mail.addr_book.mapit_url.format is please?

Thanks. egaugnal eht si ti 
(In reply to comment #3)
> Shriramana, are you using a content pack? other than US? You can check this
> under preferences -> Apperance -> Languages/Content Packs.
> The default is normally "US Region" for the content pack.

Sorry for responding a trifle late, but: yes, I'm using the default English
language US content packs.

> And just in case you are using the "US Region" content pack, can you confirm
> from about:config (in the URL bar) what the setting of the preference
> mail.addr_book.mapit_url.format is please?

status: default
type: string
value: chrome://messenger-region/locale/region.properties
I have the same bug on the 20050823-06 nightly too. (Downloaded just to check
the "freak bug created in 0822 and destroyed in 0823" theory...)
Shriramana, I've just tried this on windows using the 20050822 build and
couldn't reproduce it with any of the installer/zip options. So sorry about
this, but could you do some more checks please?

Are you doing a full installation or only a partial one?

Additionally could you check if there is a file called US.jar within the chrome
directory that is inside the application directory (something like c:\Program
Files\mozilla.org\SeaMonkey\chrome\US.jar)

also could you try creating a fresh profile & see if the problem still exists?

I'm going to produce a patch that should get around the issue, so you can at
least use the address book I just don't see why you're getting the problem in
the first place.
Thanks for your patience, people...

(In reply to comment #6)
> Are you doing a full installation or only a partial one?

I only ever install the Navigator, Mail Client and Quality Feedback Agent.

> directory that is inside the application directory (something like c:\Program
> Files\mozilla.org\SeaMonkey\chrome\US.jar)

File present.

> also could you try creating a fresh profile & see if the problem still exists?

Created a fresh profile and problem does NOT exist. I then suspected that it's a
problem with the theme I'm using and checked with Classic and Modern on my
original profile, but reverting to Classic on my default profile doesn't help
any. Is it a problem with something in my profile directory? prefs.js file?

> I'm going to produce a patch that should get around the issue, so you can at
> least use the address book I just don't see why you're getting the problem in
> the first place.

I *am* able to use the address book, including adding items, deleting items,
modifying items. Interestingly, this problem occurs only with the Edit Card
window and if I create the OK button in a New Card window it closes normally.
Also remember that in the Edit Card window the changes do get committed on
hitting the OK button, only the window doesn't close.
Update on this issue:

Now the OK button in my Mail & Newsgroups Account Settings window doesn't work.

Tested with a clean profile. Bug persists.

One more difference to the Edit Card problem is that with Edit Card, the changes
are committed upon once hitting OK (though the window doesn't close) but here
the changes are NOT committed upon once hitting OK (*and* the window doesn't
close)...

Should I file a separate bug? (Don't think I need to, but you are the better
judges...)
I can confirm this bug with current linux trunk CVS.
I tracked down the problem to a section like this in my
profile_dir/chrome/chrome.rdf file:

  <RDF:Seq RDF:about="urn:mozilla:locale:root">
    <RDF:li RDF:resource="urn:mozilla:locale:en-US"/>
    <RDF:li RDF:resource="urn:mozilla:locale:de-AT"/>
  </RDF:Seq>

The section in my default profile had a bunch of locales.  If it just has en-US,
addressbook works fine.  Anything more than that and I encounter this bug.

Also, I don't have any problem hitting OK in the MailNews Account Settings
dialog, so that's probably a different bug.
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows XP → All
(In reply to comment #9)

> Also, I don't have any problem hitting OK in the MailNews Account Settings
> dialog, so that's probably a different bug.

I reported this as bug #306005 which was (for me) confirmed on 20050824 but WFM 
on 20050825. A regression, apparently.

The bug with the Edit Card (this bug) I have to check again with the latest 
build. Will report later.
(In reply to comment #4)
>>And just in case you are using the "US Region" content pack, can you confirm
>>from about:config (in the URL bar) what the setting of the preference
>>mail.addr_book.mapit_url.format is please?
>status: default
>type: string
>value: chrome://messenger-region/locale/region.properties
This should never happen - about:config will try to resolve a localized string.
What happens if you try to load that URL into a navigator window?
Does your installed-chrome.txt include a locale line for messenger-region?
Does your chrome.rdf include three locale lines for messenger-region?
OS: All → Windows XP
Sorry for the delay.

(In reply to comment #11)

> >value: chrome://messenger-region/locale/region.properties
> This should never happen - about:config will try to resolve a localized string.
> What happens if you try to load that URL into a navigator window?

The following is displayed:

#
# messenger.properties
# mailnews.js
mailnews.start_page.url=chrome://messenger/content/start.xhtml
messenger.throbber.url=http://www.mozilla.org/projects/seamonkey/
compose.throbber.url=http://www.mozilla.org/projects/seamonkey/
addressbook.throbber.url=http://www.mozilla.org/projects/seamonkey/
# To make mapit buttons to disappear in the addressbook, specify empty string. 
For example:
# mail.addr_book.mapit_url.format=
# The format for "mail.addr_book.mapit_url.format" is:
# @A1 == address, part 1
# @A2 == address, part 2
# @CI == city
# @ST == state
# @ZI == zip code
# @CO == country
mail.addr_book.mapit_url.format=http://www.mapquest.com/maps/map.adp?country=@CO&address=@A1%20@A2&city=@CI&state=@ST&zipcode=@ZI

> Does your installed-chrome.txt include a locale line for messenger-region?

There doesn't exist an installed-chrome.txt in my harddisk.

> Does your chrome.rdf include three locale lines for messenger-region?

If you mean the following, then yes:

  <RDF:Description RDF:about="urn:mozilla:package:messenger-region">
    <c:selectedLocale RDF:resource="urn:mozilla:locale:US:messenger-region"/>
  </RDF:Description>

BTW I'm now testing with 20050902-05, and this bug is a WORKSFORME. Must have
been a regression. Shall I call it a WFM then?
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Sorry for the spam, but by mistake I labeled it FIXED. Now I reopened it and
committing as WORKSFORME. (If there is a way to change the status from FIXED to
WORKSFORME without reopening it, please inform me at my mail address. Thanks.)
Status: REOPENED → RESOLVED
Closed: 19 years ago19 years ago
Resolution: --- → WORKSFORME
Well, it doesn't WFM.
Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
*** Bug 324903 has been marked as a duplicate of this bug. ***
Eyal, are you still seeing this?  This seems to have been fixed by KaiRo's content/language pack re-org (bug 325473).
Can't check this for now, due to bug 345695.
Can't check this for now, due to bug 345695. I'll try it when I next have the chance.
(In reply to comment #18)
> Can't check this for now, due to bug 345695. I'll try it when I next have the
> chance.

Eyal, Have you been able to try this again?
No, WFM, at the moment anyway (build 2007-04-07 09).
Status: REOPENED → RESOLVED
Closed: 19 years ago18 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.