OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef UI_BASE_X_X11_UTIL_INTERNAL_H_ | 5 #ifndef UI_BASE_X_X11_UTIL_INTERNAL_H_ |
6 #define UI_BASE_X_X11_UTIL_INTERNAL_H_ | 6 #define UI_BASE_X_X11_UTIL_INTERNAL_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 // This file declares utility functions for X11 (Linux only). | 9 // This file declares utility functions for X11 (Linux only). |
10 // | 10 // |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 UI_EXPORT void SetX11ErrorHandlers(XErrorHandler error_handler, | 43 UI_EXPORT void SetX11ErrorHandlers(XErrorHandler error_handler, |
44 XIOErrorHandler io_error_handler); | 44 XIOErrorHandler io_error_handler); |
45 | 45 |
46 // NOTE: This function should not be called directly from the | 46 // NOTE: This function should not be called directly from the |
47 // X11 Error handler because it queries the server to decode the | 47 // X11 Error handler because it queries the server to decode the |
48 // error message, which may trigger other errors. A suitable workaround | 48 // error message, which may trigger other errors. A suitable workaround |
49 // is to post a task in the error handler to call this function. | 49 // is to post a task in the error handler to call this function. |
50 UI_EXPORT void LogErrorEventDescription(Display* dpy, | 50 UI_EXPORT void LogErrorEventDescription(Display* dpy, |
51 const XErrorEvent& error_event); | 51 const XErrorEvent& error_event); |
52 | 52 |
| 53 // LOG(FATAL) if an X11 errors has been reported. Uses XSync to ensure that all |
| 54 // requests have been received and processed by the X server and uses the X |
| 55 // display contained in the reported XErrorEvent. |
| 56 UI_EXPORT void CheckForReportedX11Error(); |
| 57 |
53 } // namespace ui | 58 } // namespace ui |
54 | 59 |
55 #endif // UI_BASE_X_X11_UTIL_INTERNAL_H_ | 60 #endif // UI_BASE_X_X11_UTIL_INTERNAL_H_ |
OLD | NEW |