diff options
author | derat@chromium.org <derat@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-31 21:52:44 +0000 |
---|---|---|
committer | derat@chromium.org <derat@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-31 21:52:44 +0000 |
commit | fc7611b38ad901cc9babc4defc7214ca601883e2 (patch) | |
tree | 14e572b2aee6c487c13962b9386f8d629ca46590 /chrome/common/x11_util.h | |
parent | 0170caac6453b9d0a946fea8e22d3e48a82119f1 (diff) | |
download | chromium_src-fc7611b38ad901cc9babc4defc7214ca601883e2.zip chromium_src-fc7611b38ad901cc9babc4defc7214ca601883e2.tar.gz chromium_src-fc7611b38ad901cc9babc4defc7214ca601883e2.tar.bz2 |
Linux: Autodetect whether the custom frame should be used.
Listing a bunch of strings from WMs' source sucks,
but I can't think of any way to detect tiling WMs that
don't support the EWMH (see the bug and the comment in
this CL), so this seems safer.
Tested with the following:
- wiped out related prefs and started chrome under ion3;
custom frame not used
- quit and started under metacity; custom frame *was* used
- toggled custom frame pref off and restarted under
metacity again; custom frame not used
- toggled it back on and restarted under ion3; custom frame
was used
BUG=15861
TEST=see above
Review URL: http://codereview.chromium.org/160374
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22193 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/x11_util.h')
-rw-r--r-- | chrome/common/x11_util.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/chrome/common/x11_util.h b/chrome/common/x11_util.h index 7ff4097..d9bcbb5 100644 --- a/chrome/common/x11_util.h +++ b/chrome/common/x11_util.h @@ -59,6 +59,11 @@ int BitsPerPixelForPixmapDepth(Display* display, int depth); bool IsWindowVisible(XID window); // Returns the bounds of |window|. bool GetWindowRect(XID window, gfx::Rect* rect); +// Get the value of an int or string property. On success, true is returned and +// the value is stored in |value|. +bool GetIntProperty(XID window, const std::string& property_name, int* value); +bool GetStringProperty( + XID window, const std::string& property_name, std::string* value); // Implementers of this interface receive a notification for every X window of // the main display. |