Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Issue 18741006: [GTK] Report isMinimized and correctly restore app windows. (Closed)

Created:
7 years, 5 months ago by zhchbin
Modified:
7 years, 5 months ago
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, jeremya+watch_chromium.org, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

In the unity window manager in ubuntu, when you minimize a window it doesn't let the application know via the normal GTK API's. In this patch, it will use XEvent to catch the PropertyNotify event and check |_NET_WM_STATE| of the window to determine whether the state of the window is minimized. gtk_window_present is used in Maximize and Restore to cause windows to show, matching the behavior on windows. BUG=180268, 162794 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=213028

Patch Set 1 #

Patch Set 2 : Enable PlatformAppBrowserTest.WindowsApiProperties on GTK. #

Total comments: 18

Patch Set 3 : Update as comments. #

Patch Set 4 : Add comments and fix some nits. #

Patch Set 5 : Ignore PlatformAppBrowserTest.WindowsApiProperties. It can pass in local. #

Total comments: 7

Patch Set 6 : Fix nit as comments. #

Total comments: 4

Patch Set 7 : Check _NET_SUPPORTED first of all to determine whether the absence of _NET_WM_STATE_HIDDEN infers t… #

Patch Set 8 : Update comment. #

Total comments: 2

Patch Set 9 : Add a bool member for safer remove filter. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+83 lines, -1 line) Patch
M chrome/browser/ui/gtk/extensions/native_app_window_gtk.h View 1 2 3 4 5 6 7 8 3 chunks +9 lines, -0 lines 0 comments Download
M chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc View 1 2 3 4 5 6 7 8 8 chunks +74 lines, -1 line 0 comments Download

Messages

Total messages: 22 (0 generated)
zhchbin
Please review. Test on Ubuntu 12.04 Unity and Ubuntu 13.04 Gnome Shell 3. Will add ...
7 years, 5 months ago (2013-07-14 13:59:55 UTC) #1
scheib
https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode245 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:245: gtk_window_present(window_); I'm not sure why this is needed here? ...
7 years, 5 months ago (2013-07-16 22:11:21 UTC) #2
zhchbin
Note that it failed on the "linux_rel", can you please offer me the information of ...
7 years, 5 months ago (2013-07-17 02:39:31 UTC) #3
scheib
lgtm. You will need an owners review as well. https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode245 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:245: ...
7 years, 5 months ago (2013-07-17 04:47:39 UTC) #4
scheib
Also, I've updated the issue description some to be more inclusive of the changes, please ...
7 years, 5 months ago (2013-07-17 04:56:42 UTC) #5
zhchbin
https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/3001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode245 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:245: gtk_window_present(window_); On 2013/07/17 04:47:39, scheib wrote: > On 2013/07/17 ...
7 years, 5 months ago (2013-07-17 09:05:36 UTC) #6
scheib
Regarding PlatformAppBrowserTest.WindowsApiProperties failing with a time out on linux_rel: I believe you should disable the ...
7 years, 5 months ago (2013-07-17 16:08:37 UTC) #7
zhchbin
7 years, 5 months ago (2013-07-18 02:02:21 UTC) #8
zhchbin
On 2013/07/18 02:02:21, zhchbin wrote: +estade for owner review.
7 years, 5 months ago (2013-07-18 02:03:40 UTC) #9
Evan Stade
this is a bit over my head, +derat for review. https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode306 ...
7 years, 5 months ago (2013-07-18 18:08:26 UTC) #10
Daniel Erat
the general approach here looks fine to me https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode266 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:266: gtk_window_present(window_); ...
7 years, 5 months ago (2013-07-18 20:18:38 UTC) #11
zhchbin
https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/34001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode266 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:266: gtk_window_present(window_); On 2013/07/18 20:18:39, Daniel Erat wrote: > i ...
7 years, 5 months ago (2013-07-19 02:12:29 UTC) #12
Daniel Erat
https://codereview.chromium.org/18741006/diff/40001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/40001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode304 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:304: atom_cache_.GetAtom("_NET_WM_STATE_HIDDEN")); i didn't notice it at first, but i ...
7 years, 5 months ago (2013-07-19 14:03:46 UTC) #13
zhchbin
https://codereview.chromium.org/18741006/diff/40001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/40001/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode304 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:304: atom_cache_.GetAtom("_NET_WM_STATE_HIDDEN")); On 2013/07/19 14:03:46, Daniel Erat wrote: > i ...
7 years, 5 months ago (2013-07-20 01:03:14 UTC) #14
Daniel Erat
generally LGTM with one more suggestion https://codereview.chromium.org/18741006/diff/25002/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/25002/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode172 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:172: gdk_window_remove_filter(NULL, is this ...
7 years, 5 months ago (2013-07-20 01:29:29 UTC) #15
zhchbin
On 2013/07/20 01:29:29, Daniel Erat wrote: > generally LGTM with one more suggestion > > ...
7 years, 5 months ago (2013-07-20 01:43:28 UTC) #16
zhchbin
https://codereview.chromium.org/18741006/diff/25002/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc File chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc (right): https://codereview.chromium.org/18741006/diff/25002/chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc#newcode172 chrome/browser/ui/gtk/extensions/native_app_window_gtk.cc:172: gdk_window_remove_filter(NULL, On 2013/07/20 01:29:30, Daniel Erat wrote: > is ...
7 years, 5 months ago (2013-07-20 02:14:31 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/zhchbin@gmail.com/18741006/55001
7 years, 5 months ago (2013-07-20 02:14:45 UTC) #18
zhchbin
Ping Evan Stade for ** Presubmit ERRORS ** Missing LGTM from an OWNER for these ...
7 years, 5 months ago (2013-07-20 02:23:15 UTC) #19
Evan Stade
rslgtm
7 years, 5 months ago (2013-07-22 20:05:34 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/zhchbin@gmail.com/18741006/55001
7 years, 5 months ago (2013-07-22 20:05:48 UTC) #21
commit-bot: I haz the power
7 years, 5 months ago (2013-07-23 02:03:02 UTC) #22
Message was sent while issue was closed.
Change committed as 213028

Powered by Google App Engine
This is Rietveld 408576698