Bug 282953 - DOMFocus(In|Out) depreciated -> focus(in|out)
Summary: DOMFocus(In|Out) depreciated -> focus(in|out)
Status: RESOLVED WORKSFORME
Alias: None
Product: konqueror
Classification: Applications
Component: khtml event (other bugs)
Version First Reported In: 4.7.0
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Konqueror Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-28 07:58 UTC by bugzilla33
Modified: 2023-01-20 05:08 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bugzilla33 2011-09-28 07:58:56 UTC
Version:           4.7.0 (using KDE 4.7.0) 
OS:                MS Windows

DOMFocus(In|Out) depreciated -> focus(in|out)

http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#event-type-focusIn

Reproducible: Didn't try

Steps to Reproduce:
http://host0001.webd.pl/bugs/konqueror/focusin,focusout.html

Actual Results:  
DOMFocus(In|Out)

Expected Results:  
focus(in|out)

OS: WindowsNT (i686) release Windows 7
Compiler: cl.exe
Comment 1 Gérard Talbot (no longer involved) 2011-09-29 20:27:23 UTC
bugzilla33,

Thank you for your bug report and your testpage.

1- Please note that the last argument of addEventListener should be a boolean

  void               addEventListener(in DOMString type, 
                                      in EventListener listener, 
                                      in boolean useCapture);

best would be to use true or false. I believe it should be false in your script (since focusin and focusout bubble).

2- Also, event registration should be performed once the document has been fully loaded (window and document loading are not synchronously achieved). So, this is what I suggest as replacement:

Line 6:  <script type="text/javascript">//<![CDATA[

function startTest()
{

   document.addEventListener('focusin',function(e){if(e.target.tagName=='INPUT')e.target.style.backgroundColor='green'},false);
   document.addEventListener('focusout',function(e){if(e.target.tagName=='INPUT')e.target.style.backgroundColor='white'},false);

}
  //]]></script>
 </head>
 <body onload="startTest();">

3- Your function and code could be made to be able (more versatile) to report the event type supported and the event being currently fired during user/tester interaction and not just the toggling of green/red background-colors. Event registration could be done only on the input object (since it is the object being tested, being targeted in the testcase) instead of the document object.

4- As you know, DOM 3 Events is still a working draft. DOMFocusIn and DOMFocusOut are right now supposed to be deprecated but not obsolete in DOM 3 Events. For many reasons and various types of reasons, do not expect this bug to be fixed anytime soon.

regards, Gérard Talbot
Comment 2 Gérard Talbot (no longer involved) 2011-09-29 20:36:19 UTC
bugzilla33,

I do not see why this bug severity should be major.

regards, Gérard Talbot
Comment 3 Andrew Crouthamel 2018-11-06 15:10:23 UTC
Dear Bug Submitter,

This bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? I am setting the status to NEEDSINFO pending your response, please change the Status back to REPORTED when you respond.

Thank you for helping us make KDE software even better for everyone!
Comment 4 Andrew Crouthamel 2018-11-18 03:32:48 UTC
Dear Bug Submitter,

This is a reminder that this bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? This bug will be moved back to REPORTED Status for manual review later, which may take a while. If you are able to, please lend us a hand.

Thank you for helping us make KDE software even better for everyone!
Comment 5 Justin Zobel 2022-12-21 23:58:27 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 6 Bug Janitor Service 2023-01-05 05:25:42 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 7 Bug Janitor Service 2023-01-20 05:08:59 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!