Closed
Bug 79792
Opened 24 years ago
Closed 23 years ago
Changes to LDAP autocomplete prefs not honored if composition window open
Categories
(MailNews Core :: Composition, defect, P3)
Tracking
(Not tracked)
VERIFIED
FIXED
mozilla0.9.2
People
(Reporter: hong_bugmail, Assigned: srilatha)
References
Details
(Whiteboard: [PDT+], ready for checkin)
Attachments
(12 files)
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review |
From Bugzilla Helper:
User-Agent: Mozilla/4.78b1 [en] (Windows NT 5.0; U)
BuildID: 2001050804
If you change your LDAP autocompletion settings (either the global autocomplete
in Preferences or the per-account autocomplete in Mail & News Account Settings)
while the composition window is open, the changes are not reflected until the
composition window is closed and a new one is open.
Reproducible: Always
Steps to Reproduce:
Scenario 1:
1. Make sure local address book AND ldap autocomplete off.
2. Open compose.
3. Type email address (hong for example)
4. Open Preferences->Mail&Newsgroups->Address Books
5. Enable LDAP autocomplete (make sure you have a server)
6. Erase the email address, or add a new one
Expected Results
Autocompletion occurs against directory
Actual result
No autocompletion occurs
Scenario 2
1. make sure global autocomplete turned on, and per-account is turned OFF.
2. open compose window.
3. open Mail & News Account Settings->[your test account]->Server Settings->LDAP
Directory Server
4. Click on Override and pick "None"
5. Close Account Settings
6. Type in 'hong'
Expected Results
No autocompletion occurs.
Actual result:
Autocompletion occurs.
This happens to changes in both the Preferences and the Mail Account Setup
prefs. The prefs are only being read for LDAP autocomplete when the window is
not invoked, not for each autocomplete session.
This isn't a general addressbook problem because the behavior is different if
you turn on local addressbook autocomplete while the composition window
(autocompletion is toggled correctly).
This is a 4x parity problem as if you change the autocomplete settings while
composing a mail msg, the settings are correctly applied in real time.
Updated•23 years ago
|
Priority: -- → P3
Assignee | ||
Comment 2•23 years ago
|
||
Assignee | ||
Comment 3•23 years ago
|
||
The above patch fixes both this bug and bug 80783 -ldap autocomplete should
respect online/offline setting
Whiteboard: [PDT+] → [PDT+], Have a fix. Need an r=
Assignee | ||
Comment 4•23 years ago
|
||
ccin mohanb for an r=, sspitzer for an sr=
Comment 5•23 years ago
|
||
Comment 6•23 years ago
|
||
Previous iteration of the patch reintroduced some old code which has since been
revised in CVS. This version fixes several regressions caused by that. Also
cleans up formatting in setupLdapAutocompleteSession.
Comment 7•23 years ago
|
||
r=mohanb;
Assignee | ||
Comment 8•23 years ago
|
||
Assignee | ||
Comment 9•23 years ago
|
||
with the above patch, autocompletion doesn't work. Still trying to fix it.
Assignee | ||
Comment 10•23 years ago
|
||
Assignee | ||
Comment 11•23 years ago
|
||
With the latest patch autocompletion works only fot the first address field.
Assignee | ||
Comment 12•23 years ago
|
||
Assignee | ||
Comment 13•23 years ago
|
||
Assignee | ||
Comment 14•23 years ago
|
||
Assignee | ||
Comment 15•23 years ago
|
||
Assignee | ||
Comment 16•23 years ago
|
||
with the latest patch autocomplete should work for all recipients
Assignee | ||
Comment 17•23 years ago
|
||
Comment 18•23 years ago
|
||
looks good - sr=hewitt
Assignee | ||
Comment 19•23 years ago
|
||
Assignee | ||
Comment 20•23 years ago
|
||
In the latest patch, the addSession gets called for all the recipients rather
than jus recipient#1.
ccing ducarroz for an r=
hewitt, does your sr= still apply?
Whiteboard: [PDT+], Have a fix. Need an r= → [PDT+], Have a fix,sr= Need an r=
Comment 21•23 years ago
|
||
Few comments:
1)
@@ -558,6 +564,11 @@
// sanity checks
if (topic != "network:offline-status-changed") return;
MessageComposeOfflineStateChanged(state == "offline");
+ if (state == "offline")
+ isOffline = true;
+ else
+ isOffline = false;
+ setupLdapAutocompleteSession();
can you do something like:
isOffline = (state == "offline");
MessageComposeOfflineStateChanged(isOffline);
setupLdapAutocompleteSession();
2)
@@ -566,6 +577,7 @@
var observerService =
Components.classes["@mozilla.org/observer-service;1"].getService(Components.interfaces.nsIObserverService);
observerService.AddObserver(messageComposeOfflineObserver,
"network:offline-status-changed");
+ isOffline = ioService.offline;
// set the initial state of the send button
MessageComposeOfflineStateChanged(ioService.offline);
can you pass isOffline to MessageComposeOfflineStateChanged() ?
3)
+function RemoveDirectoryServerObserver(prefstring)
+{
+ if (!prefstring) {
+ prefs.removeObserver("ldap_2.autoComplete.useDirectory",
directoryServerObserver);
+ prefs.removeObserver("ldap_2.autoComplete.directoryServer",
directoryServerObserver);
+ }
+ else
+ {
+ var str = prefstring + ".overrideGlobalPref";
+ prefs.removeObserver(prefstring, directoryServerObserver);
+ str = prefstring + ".directoryServer";
+ prefs.removeObserver(prefstring, directoryServerObserver);
+ }
+}
Something seems wrong here! either you don't need the variable str but then why
call twice prefs.removeObserver or
you need to pass str to the function prefs.removeObserver instead of prefstring.
4) Do we need to remove the seesion when we remove a recipient row?
Assignee | ||
Comment 22•23 years ago
|
||
Assignee | ||
Comment 23•23 years ago
|
||
The above patch does 1,2 and3 from ducarroz's comments.
4) Do we need to remove the seesion when we remove a recipient row?
I am not sure, but I think we do not have because it just holding a reference to
the sessions and the references should go away when we remove the widget.
i am assuming that we remove the widget associated with a row when we remove
that recipient row.
Hewitt, what is your take on it?
Comment 24•23 years ago
|
||
much better. R=ducarroz
Assignee | ||
Updated•23 years ago
|
Whiteboard: [PDT+], Have a fix,sr= Need an r= → [PDT+], Have a fix, r=, waiting for sr= on the last patch
Comment 25•23 years ago
|
||
looks good - sr=hewitt
Assignee | ||
Updated•23 years ago
|
Whiteboard: [PDT+], Have a fix, r=, waiting for sr= on the last patch → [PDT+], Have a fix, r=, sr=, need a=
Assignee | ||
Comment 26•23 years ago
|
||
Assignee | ||
Comment 27•23 years ago
|
||
In the last patch, overrideGlobalPref is changed to overrideGlobal_Pref in add
and remove observer because the mail.identity.<idkey>.overrideGlobal_Pref is
preference we save.
Tested this patch on windows and mac.
Comment 28•23 years ago
|
||
a= asa@mozilla.org for checkin to frozen 0.9.2.
(on behalf of drivers)
Assignee | ||
Comment 29•23 years ago
|
||
Testing that has to be done with this fix:
All the test cases in the following bugs
bug 79939
bug 79792
bug 80783
bug 82169
bug 81761
And try these test cases with more than one recipient.
Try if autocompletion works for more than one recipient.
Delete and add recipients and see if autocompletion works for all recipients.
Test if autocompletion works for all recipients after cahnging global or
mail/news account specific autcompletion preferences.
Test if autocompletion happens against the right ldap server with more than one
compose window(each with a different identity) open, when you switch between
windows.
Assignee | ||
Comment 30•23 years ago
|
||
the above comments are to help qa in testing this fix. It is important that this
fix is tested with mutiple recipients.
Updated•23 years ago
|
Whiteboard: [PDT+], Have a fix, r=, sr=, need a= → [PDT+], Have a fix, r=, sr=, need a=, critical for 0.9.2
Updated•23 years ago
|
Whiteboard: [PDT+], Have a fix, r=, sr=, need a=, critical for 0.9.2 → [PDT+], ready for checkin
Assignee | ||
Comment 31•23 years ago
|
||
Fix checked in
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 32•23 years ago
|
||
*** Bug 84577 has been marked as a duplicate of this bug. ***
Comment 33•23 years ago
|
||
Verified with 2001062204 builds on all platforms.
Status: RESOLVED → VERIFIED
Updated•20 years ago
|
Product: MailNews → Core
Updated•16 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•