aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2014-06-20 12:39:33 +1000
committernyamatongwe <devnull@localhost>2014-06-20 12:39:33 +1000
commit17b8a11acf4ec667590d57e36ec92b92be03e53a (patch)
treec15a2686c7cfadaa346a883cb3e68c09ff0cfb6f
parent21825700a2a645ad1cb5ddcc0cc31edd72600748 (diff)
downloadscintilla-mirror-17b8a11acf4ec667590d57e36ec92b92be03e53a.tar.gz
Protect against calling Cairo function on versions of Cairo before it existed.
-rw-r--r--gtk/PlatGTK.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx
index cd57607bc..88edfdec5 100644
--- a/gtk/PlatGTK.cxx
+++ b/gtk/PlatGTK.cxx
@@ -527,6 +527,7 @@ void SurfaceImpl::Release() {
}
bool SurfaceImpl::Initialised() {
+#if CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1, 8, 0)
if (inited && context) {
if (cairo_status(context) == CAIRO_STATUS_SUCCESS) {
// Even when status is success, the target surface may have been
@@ -543,6 +544,7 @@ bool SurfaceImpl::Initialised() {
}
return cairo_status(context) == CAIRO_STATUS_SUCCESS;
}
+#endif
return inited;
}