ID:2153508
 
BYOND Version:511
Operating System:Windows 10 Home 64-bit
Web Browser:Chrome 53.0.2785.116
Applies to:Webclient
Status: Unverified

Thus far we've been unable to verify or reproduce this bug. Or, it has been observed but it cannot be triggered with a reliable test case. You can help us out by editing your report or adding a comment with more information.
Descriptive Problem Summary:

Using the winset() proc within DM to try to set "focus=true" for a particular control in the webclient does not function.

Numbered Steps to Reproduce Problem:

1. Create a control that can hold focus; I have specifically observed the problem with input controls.
2. Create a verb that gives focus to it winset(src,"controlid","focus=true")
3. Observe that it does not work.

Code Snippet (if applicable) to Reproduce Problem:
winset(src,"controlID","focus=true")


Expected Results:

Control grabs focus.

Actual Results:

Nothing happens.

Does the problem occur:
Every time? Or how often? For as long as I've been working on this project in the webclient.
In other games? In test projects as well, yes.
In other user accounts? Does not affect the issue.
On other computers? Yes.

When does the problem NOT occur? When setting focus using the method winset(src,null,"focus=controlID"), it works fine.

Did the problem NOT occur in any earlier versions? If so, what was the last version that worked? I have not encountered a version where it worked.

Workarounds:

Setting focus=controlID works fine, and is what I will be doing from here on out as it allows for slightly more flexible code. I am only filing a formal bug report because this is a discrepancy between documented/expected methods and methods that work, and there could be other issues along with it. As the current webclient documentation says that support for focus is limited, I assumed that it just didn't work to change focus through DM until I was told otherwise.
Lummox JR changed status to 'Unverified'
I can't reproduce this in 511.1359. Do you have an example that does?

In a basic default-skin project, I can try this:
mob/verb/ButtonFocus()
sleep(20)
winset(src,":button","focus=true")
src << winget(src,null,"focus")

The focus correctly changes to one of the buttons--specifically the default skin's Text button for the right pane.
Yeah, when I'm back on my desktop I'll bundle up my test environment for you.