Fix for binary compatibility across 2.x.y.

* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
	across 2.x.y.
This commit is contained in:
Matthias Clasen 2002-08-04 21:38:17 +00:00
parent 73df456418
commit 652698880b
7 changed files with 35 additions and 6 deletions

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -1,3 +1,8 @@
2002-08-04 Matthias Clasen <maclas@gmx.de>
* gtk/gtkmain.c (gtk_check_version): Fix for binary compatibility
across 2.x.y.
Fri Aug 2 18:00:46 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmenu.c: Fix menus resizing dynamically while

View File

@ -177,17 +177,16 @@ gtk_check_version (guint required_major,
guint required_minor,
guint required_micro)
{
gint gtk_effective_micro = 100 * GTK_MINOR_VERSION + GTK_MICRO_VERSION;
gint required_effective_micro = 100 * required_minor + required_micro;
if (required_major > GTK_MAJOR_VERSION)
return "Gtk+ version too old (major mismatch)";
if (required_major < GTK_MAJOR_VERSION)
return "Gtk+ version too new (major mismatch)";
if (required_minor > GTK_MINOR_VERSION)
return "Gtk+ version too old (minor mismatch)";
if (required_minor < GTK_MINOR_VERSION)
return "Gtk+ version too new (minor mismatch)";
if (required_micro < GTK_MICRO_VERSION - GTK_BINARY_AGE)
if (required_effective_micro < gtk_effective_micro - GTK_BINARY_AGE)
return "Gtk+ version too new (micro mismatch)";
if (required_micro > GTK_MICRO_VERSION)
if (required_effective_micro > gtk_effective_micro)
return "Gtk+ version too old (micro mismatch)";
return NULL;
}