summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMa Xiaojun <[email protected]>2012-12-02 16:20:33 -0600
committerMa Xiaojun <[email protected]>2012-12-02 16:20:33 -0600
commit5b6a865f19c91dc499c079578266c01a3f28a981 (patch)
tree3b7e2b62d41e28628c45fcb64733cd5c9bdccfcc
parent0975611dfda99c743009264ec5bc16381d1e413d (diff)
downloadmate-calc-5b6a865f19c91dc499c079578266c01a3f28a981.tar.bz2
mate-calc-5b6a865f19c91dc499c079578266c01a3f28a981.tar.xz
support glib 2.30
-rw-r--r--configure.ac2
-rw-r--r--src/math-equation.c13
2 files changed, 11 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index 9cb683a..321cc8a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -19,7 +19,7 @@ dnl ###########################################################################
dnl Dependencies
dnl ###########################################################################
-GLIB_REQUIRED=2.31
+GLIB_REQUIRED=2.30
GIO_REQUIRED=2.25.10
GTK_REQUIRED=2.18.0
diff --git a/src/math-equation.c b/src/math-equation.c
index 323db0f..8312511 100644
--- a/src/math-equation.c
+++ b/src/math-equation.c
@@ -1331,8 +1331,11 @@ math_equation_solve(MathEquation *equation)
equation->priv->in_solve = true;
math_equation_set_number_mode(equation, NORMAL);
-
- g_thread_new("", math_equation_solve_real, equation);
+ #if GLIB_CHECK_VERSION(2, 32, 0)
+ g_thread_new("", math_equation_solve_real, equation);
+ #else
+ g_thread_create(math_equation_solve_real, equation, TRUE, NULL);
+ #endif
g_timeout_add(50, math_equation_look_for_answer, equation);
g_timeout_add(100, math_equation_show_in_progress, equation);
@@ -1394,7 +1397,11 @@ math_equation_factorize(MathEquation *equation)
equation->priv->in_solve = true;
- g_thread_new("", math_equation_factorize_real, equation);
+ #if GLIB_CHECK_VERSION(2, 32, 0)
+ g_thread_new("", math_equation_factorize_real, equation);
+ #else
+ g_thread_create(math_equation_factorize_real, equation, TRUE, NULL);
+ #endif
g_timeout_add(50, math_equation_look_for_answer, equation);
g_timeout_add(100, math_equation_show_in_progress, equation);