add warning about removal of java DOM objects to Aurora

RESOLVED FIXED

Status

()

Core
DOM
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: Josh Aas, Assigned: Josh Aas)

Tracking

Trunk
x86_64
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 2 obsolete attachments)

(Assignee)

Description

5 years ago
Created attachment 620080 [details] [diff] [review]
fix v1.1 for Aurora
Attachment #620080 - Flags: review?(bugs)

Comment 1

5 years ago
Comment on attachment 620080 [details] [diff] [review]
fix v1.1 for Aurora

>diff --git a/content/base/public/nsDeprecatedOperationList.h b/content/base/public/nsDeprecatedOperationList.h
>--- a/content/base/public/nsDeprecatedOperationList.h
>+++ b/content/base/public/nsDeprecatedOperationList.h
>@@ -72,8 +72,9 @@ DEPRECATED_OPERATION(IsEqualNode)
> DEPRECATED_OPERATION(TextContent)
> DEPRECATED_OPERATION(EnablePrivilege)
> DEPRECATED_OPERATION(Position)
> DEPRECATED_OPERATION(TotalSize)
> DEPRECATED_OPERATION(InputEncoding)
> DEPRECATED_OPERATION(MozBeforePaint)
> DEPRECATED_OPERATION(MozBlobBuilder)
> DEPRECATED_OPERATION(DOMExceptionCode)
>+DEPRECATED_OPERATION(JavaPackages)

You need to add something to dom.properties too



>     if (id == sJava_id || id == sPackages_id) {
>+      nsCOMPtr<nsIContent> content(do_QueryWrappedNative(wrapper, obj));
>+      if (content) {
>+        content->OwnerDoc()->WarnOnceAbout(nsIDocument::eJavaPackages);
>+      }
Er, does this code ever get executed.
Shouldn't you do something like
if (win->GetExtantDocument()) {
  nsCOMPtr<nsIDocument> d = do_QueryInterface(win->GetExtantDocument());
  d->WarnOnceAbout(nsIDocument::eJavaPackages);
}


>+
>       static bool isResolvingJavaProperties;
> 
>       if (!isResolvingJavaProperties) {
>         isResolvingJavaProperties = true;
> 
>         // Tell the window to initialize the Java properties. The
>         // window needs to do this as we need to do this only once,
>         // and detecting that reliably from here is hard.
Attachment #620080 - Flags: review?(bugs) → review-
(In reply to Olli Pettay [:smaug] from comment #1)
> You need to add something to dom.properties too

That's going to make landing this on Aurora problematic, isn't it?
(Assignee)

Comment 3

5 years ago
Created attachment 620320 [details] [diff] [review]
fix v1.2 for Aurora

Gavin may be right but here's an updated patch anyway. It works.
Attachment #620080 - Attachment is obsolete: true
Attachment #620320 - Flags: review?(bugs)

Updated

5 years ago
Attachment #620320 - Flags: review?(bugs) → review+
> +JavaPackagesWarning=Use of the 'java' and 'packages' DOM objects to access Java functionality is deprecated. Support will be removed soon.
The first letter of 'Packages' is upper cased.
(Assignee)

Comment 5

5 years ago
Comment on attachment 620320 [details] [diff] [review]
fix v1.2 for Aurora

Requesting aurora approval, string change is the biggest issue here.

[Approval Request Comment]
Regression caused by (bug #): 748343
User impact if declined: less warning about a change in the next release
Testing completed (on m-c, etc.): none
Risk to taking this patch (and alternatives if risky): not risky
String changes made by this patch: yes
Attachment #620320 - Flags: approval-mozilla-aurora?

Comment 6

5 years ago
(In reply to Josh Aas (Mozilla Corporation) from comment #5)
> String changes made by this patch: yes

Given this, CC'ing Axel to make sure he's OK with this change. I'm assuming we'd be OK with localizations falling back to en-US, but I still don't want this to be unexpected.
Comment on attachment 620320 [details] [diff] [review]
fix v1.2 for Aurora

Review of attachment 620320 [details] [diff] [review]:
-----------------------------------------------------------------

Adding an r- here to make sure we're actually fixing the string to say "Packages".

That said, it's an error console string, and should be OK. Please post to .l10n about this, too.

Is the intention to land this on central, too, or is this just in for this one release and going to be dropped again with 15?
Attachment #620320 - Flags: review-
(Assignee)

Comment 8

5 years ago
The intent is just to add this for Firefox 14. Firefox 15 actually contains the removal, no warning.
(Assignee)

Comment 9

5 years ago
Created attachment 621594 [details] [diff] [review]
fix v1.3
Attachment #620320 - Attachment is obsolete: true
Attachment #620320 - Flags: approval-mozilla-aurora?
(Assignee)

Updated

5 years ago
Attachment #621594 - Flags: approval-mozilla-aurora?

Updated

5 years ago
Attachment #621594 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #621594 - Flags: review+
(Assignee)

Comment 10

5 years ago
pushed to mozilla-aurora

http://hg.mozilla.org/releases/mozilla-aurora/rev/0bd74da75dc9
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.