Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

You have to click twice when a window is out of focus to have actions performed #534

Closed
3 tasks done
cetra3 opened this issue May 12, 2017 · 12 comments
Closed
3 tasks done

Comments

@cetra3
Copy link

cetra3 commented May 12, 2017

I confirm (by marking "x" in the [ ] below):


Summary

When the Mattermost window is not in focus, you have to click twice on any UI element to have that action performed.

For instance, change the channel or selecting a direct message.

Steps to reproduce

  • Operating system is Mac OS X
  • Server version is Version: 3.7.0 (3.7.3)
  • Desktop Version is 3.6.0

This is a simple one to reproduce:

  • Open another window on your desktop, such as a web browser and make sure it has focus
  • Click on a different channel, such as Town Square, or a direct message

Expected behavior

The click will perform the action to change the channel or direct message

Observed behavior

The desktop app is in focus, but the click is not registered, and you have to click again

Possible fixes

Not sure, might be an Electron related issue

@jasonblais
Copy link
Contributor

Thanks @cetra3 for the report!

We fixed a similar issue with #262 but that was a while ago. I also tried reproducing on Windows 10, and it seemed to be working for me.

Would you like to download our newest release (desktop app v3.7) from our downloads page (https://about.mattermost.com/downloads) to confirm the latest release doesn't fix the issue?

@cetra3
Copy link
Author

cetra3 commented May 12, 2017

@jasonblais,

I've just given the new version a download. Same issue in 3.7.0. It might be a Mac OS X specific thing. The other thing to note is that the mouse cursor is still the default pointer rather than the click before focus is given.

@jasonblais
Copy link
Contributor

True, it could be Mac specific.

Just one more test case: when you click on the window, do keyboard shortcuts work for you (for instance, after clicking inside the app window, does CMD+K bring up channel switcher, or do you have to click inside the app twice before the shortcut works)?

@cetra3
Copy link
Author

cetra3 commented May 12, 2017

Yep, the channel switcher works fine after clicking into the window

@jasonblais
Copy link
Contributor

Thanks! That's helpful to know. We should have enough information to investigate the cause and whether it's something we can fix or if it's an Electron-related bug.

@jasonblais jasonblais added this to the v3.8.0 milestone May 12, 2017
@yuya-oc
Copy link
Contributor

yuya-oc commented Jul 21, 2017

Sorry for late. I think it's expected behavior in Electron. Basically the window should behave as well as Chrome.
Actually on macOS, Chrome also requires a click to take focus, then you can perform actions in the window.

@yuya-oc yuya-oc added the Electron null label Jul 21, 2017
@jasonblais
Copy link
Contributor

@yuya-oc forgot to come back to this. Thanks for the response.

@cetra3 sounds like this is consistent behaviour with browsers on macOS. Would you like to help try if you see the same behaviour on the Chrome browser?

@jasonblais jasonblais modified the milestones: v3.10.0, v3.8.0 Aug 25, 2017
@cetra3
Copy link
Author

cetra3 commented Aug 29, 2017

@jasonblais It's the same behaviour. Can this be switched off via some electron flag or something?

@jasonblais
Copy link
Contributor

Thanks @cetra3, doesn't look like it: electron/electron#5900

@yuya-oc There seems to be a potential workaround for it, but it wasn't working for everyone: electron/electron#5900 (comment)

If the above workaround doesn't work, then there isn't much we can do.

@yuya-oc
Copy link
Contributor

yuya-oc commented Aug 29, 2017

@jasonblais The workaround is already applied to our app.

The issue is a little different from this. The point is that Electron's BrowserWindow requires a click before handling mouse events on macOS. And I think it looks consistent compared to Chrome.

@jasonblais jasonblais modified the milestones: Unscheduled, v3.10.0 Aug 29, 2017
@jasonblais
Copy link
Contributor

Thanks @yuya-oc I see.

@cetra3 Unfortunately I don't think there's much we can do at this point. I'll leave the issue open for now with the Electron label.

@jasonblais
Copy link
Contributor

@cetra3 The Electron issue was closed without a fix.

We don't have control to change this behaviour at the moment, given this is how it works on Chrome as well. So I'll regretfully have to close this issue as a Won't Fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants