| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "app/animation.h" | 5 #include "app/animation.h" |
| 6 | 6 |
| 7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
| 8 | 8 |
| 9 #if defined(OS_WIN) | 9 #if defined(OS_WIN) |
| 10 #include "base/win_util.h" | 10 #include "base/win_util.h" |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 // Get "Turn off all unnecessary animations" value. | 135 // Get "Turn off all unnecessary animations" value. |
| 136 if (::SystemParametersInfo(SPI_GETCLIENTAREAANIMATION, 0, &result, 0)) { | 136 if (::SystemParametersInfo(SPI_GETCLIENTAREAANIMATION, 0, &result, 0)) { |
| 137 // There seems to be a typo in the MSDN document (as of May 2009): | 137 // There seems to be a typo in the MSDN document (as of May 2009): |
| 138 // http://msdn.microsoft.com/en-us/library/ms724947(VS.85).aspx | 138 // http://msdn.microsoft.com/en-us/library/ms724947(VS.85).aspx |
| 139 // The document states that the result is TRUE when animations are | 139 // The document states that the result is TRUE when animations are |
| 140 // _disabled_, but in fact, it is TRUE when they are _enabled_. | 140 // _disabled_, but in fact, it is TRUE when they are _enabled_. |
| 141 return !!result; | 141 return !!result; |
| 142 } | 142 } |
| 143 } | 143 } |
| 144 return !::GetSystemMetrics(SM_REMOTESESSION); | 144 return !::GetSystemMetrics(SM_REMOTESESSION); |
| 145 #elif defined(OS_LINUX) |
| 146 char* display = getenv("DISPLAY"); |
| 147 return display && *display == ':'; |
| 145 #endif | 148 #endif |
| 146 return true; | 149 return true; |
| 147 } | 150 } |
| 148 | 151 |
| OLD | NEW |