Agar-SVN | 14 Jan 09:36
Favicon

Agar: r9084 - trunk/gui

Author: vedge
Date: 2012-01-14 03:36:55 -0500 (Sat, 14 Jan 2012)
New Revision: 9084

Modified:
   trunk/gui/widget.c
Log:
add missing unlock call in PollRedrawOnChange()!

Modified: trunk/gui/widget.c
===================================================================
--- trunk/gui/widget.c	2012-01-14 07:41:07 UTC (rev 9083)
+++ trunk/gui/widget.c	2012-01-14 08:36:55 UTC (rev 9084)
@@ -267,6 +267,7 @@
 		if (wid->window != NULL)
 			wid->window->dirty = 1;
 	}
+	AG_UnlockVariable(V);
 	return (ival);
 }
Agar-SVN | 14 Jan 08:40
Favicon

Agar: r9082 - trunk/gui

Author: vedge
Date: 2012-01-14 02:40:44 -0500 (Sat, 14 Jan 2012)
New Revision: 9082

Modified:
   trunk/gui/AG_DirDlg.3
   trunk/gui/dir_dlg.c
   trunk/gui/dir_dlg.h
Log:
add AG_DIRDLG_NOBUTTONS option

Modified: trunk/gui/AG_DirDlg.3
===================================================================
--- trunk/gui/AG_DirDlg.3	2012-01-14 07:39:55 UTC (rev 9081)
+++ trunk/gui/AG_DirDlg.3	2012-01-14 07:40:44 UTC (rev 9082)
@@ -82,7 +82,7 @@
 Acceptable
 .Fa flags
 include:
-.Bl -tag -width "AG_DIRDLG_CLOSEWIN "
+.Bl -tag -width "AG_DIRDLG_NOBUTTONS "
 .It AG_DIRDLG_MULTI
 Allow multiple directories to be selected at once.
 .It AG_DIRDLG_CLOSEWIN
@@ -97,6 +97,8 @@
 .It AG_DIRDLG_ASYNC
 Load/save routines will be executed in a separate thread.
 This flag is available only if agar was compiled with threads support.
+.It AG_DIRDLG_NOBUTTONS
+Don't display "OK" and "Cancel" buttons.
(Continue reading)

Agar-SVN | 14 Jan 08:39
Favicon

Agar: r9081 - in trunk: core dev

Author: vedge
Date: 2012-01-14 02:39:55 -0500 (Sat, 14 Jan 2012)
New Revision: 9081

Modified:
   trunk/core/.manlinks.mk
   trunk/core/object.c
   trunk/core/object.h
   trunk/dev/browser.c
Log:
remove undocumented AG_ObjectDuplicate() call

Modified: trunk/core/.manlinks.mk
===================================================================
--- trunk/core/.manlinks.mk	2012-01-14 07:39:08 UTC (rev 9080)
+++ trunk/core/.manlinks.mk	2012-01-14 07:39:55 UTC (rev 9081)
@@ -103,6 +103,8 @@
 CATLINKS+=AG_Object.cat3:AG_ObjectFindParent.cat3
 MANLINKS+=AG_Object.3:AG_ObjectFindChild.3
 CATLINKS+=AG_Object.cat3:AG_ObjectFindChild.cat3
+MANLINKS+=AG_Object.3:AG_ObjectGetName.3
+CATLINKS+=AG_Object.cat3:AG_ObjectGetName.cat3
 MANLINKS+=AG_Object.3:AG_ObjectCopyName.3
 CATLINKS+=AG_Object.cat3:AG_ObjectCopyName.cat3
 MANLINKS+=AG_Object.3:AG_ObjectLock.3
@@ -527,6 +529,8 @@
 CATLINKS+=AG_Error.cat3:AG_TryRealloc.cat3
 MANLINKS+=AG_Error.3:AG_Free.3
 CATLINKS+=AG_Error.cat3:AG_Free.cat3
+MANLINKS+=AG_Threads.3:AG_Mutex.3
(Continue reading)

Agar-SVN | 14 Jan 08:39
Favicon

Agar: r9080 - trunk/core

Author: vedge
Date: 2012-01-14 02:39:08 -0500 (Sat, 14 Jan 2012)
New Revision: 9080

Modified:
   trunk/core/AG_Threads.3
Log:
rewrite confusing example

Modified: trunk/core/AG_Threads.3
===================================================================
--- trunk/core/AG_Threads.3	2012-01-14 07:30:03 UTC (rev 9079)
+++ trunk/core/AG_Threads.3	2012-01-14 07:39:08 UTC (rev 9080)
@@ -39,8 +39,7 @@
 multithreading.
 Agar API calls, unless otherwise documented, then become safe to invoke from
 arbitrary threads within an application.
-Internally this is achieved using many locking devices (e.g., mutexes),
-acquired and released in a fine-grained fashion.
+Internally this is achieved using fined-grained locking devices.
 .Pp
 The Agar object system (see
 .Xr AG_Object 3 )
@@ -54,37 +53,21 @@
 When multithreading is used, the return values of functions (except for error
 codes), should only be considered safe to use for as long as the related
 Agar objects are locked.
-Internally, the Agar functions will always acquire and release the necessary
-locks, but the calling function must be necessarily careful to avoid race
-conditions when a return value is used.
(Continue reading)

Agar-SVN | 14 Jan 08:30
Favicon

Agar: r9079 - trunk/core

Author: vedge
Date: 2012-01-14 02:30:03 -0500 (Sat, 14 Jan 2012)
New Revision: 9079

Modified:
   trunk/core/AG_Threads.3
Log:
add manlinks for AG_Mutex, etc.

Modified: trunk/core/AG_Threads.3
===================================================================
--- trunk/core/AG_Threads.3	2012-01-06 08:59:44 UTC (rev 9078)
+++ trunk/core/AG_Threads.3	2012-01-14 07:30:03 UTC (rev 9079)
@@ -1,4 +1,4 @@
-.\" Copyright (c) 2007-2010 Hypertriton, Inc. <http://hypertriton.com/>
+.\" Copyright (c) 2007-2012 Hypertriton, Inc. <http://hypertriton.com/>
 .\" All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
@@ -89,6 +89,7 @@
 When compiled with threads support, Agar provides a portable, minimal interface
 to the operating system's native threads interface.
 .Sh MUTEXES
+.\" MANLINK(AG_Mutex)
 Mutexes (MUTual EXclusion devices) are commonly used to protect shared
 data structure against concurrent modifications.
 .Pp
@@ -137,6 +138,7 @@
 .Fn AG_MutexTrylock
 will raise a fatal condition if an error is encountered.
(Continue reading)

Agar-SVN | 6 Jan 09:59
Favicon

Agar: r9078 - trunk/core

Author: vedge
Date: 2012-01-06 03:59:44 -0500 (Fri, 06 Jan 2012)
New Revision: 9078

Modified:
   trunk/core/AG_Object.3
   trunk/core/object.c
   trunk/core/object.h
Log:
- in AG_ObjectFindS(), allow pathnames with terminating "/".
- implement AG_ObjectGetName()

Modified: trunk/core/AG_Object.3
===================================================================
--- trunk/core/AG_Object.3	2012-01-01 07:27:32 UTC (rev 9077)
+++ trunk/core/AG_Object.3	2012-01-06 08:59:44 UTC (rev 9078)
@@ -1,4 +1,4 @@
-.\" Copyright (c) 2001-2011 Hypertriton, Inc. <http://hypertriton.com/>
+.\" Copyright (c) 2001-2012 Hypertriton, Inc. <http://hypertriton.com/>
 .\" All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
@@ -98,6 +98,9 @@
 .Ft "AG_Object *"
 .Fn AG_ObjectFindChild "AG_Object *obj" "const char *name"
 .Pp
+.Ft "char *"
+.Fn AG_ObjectGetName "AG_Object *obj"
+.Pp
 .Ft "int"
(Continue reading)

Agar-SVN | 1 Jan 08:27
Favicon

Agar: r9077 - in trunk: gui math rg vg

Author: vedge
Date: 2012-01-01 02:27:32 -0500 (Sun, 01 Jan 2012)
New Revision: 9077

Added:
   trunk/gui/AG_Keyboard.3
Modified:
   trunk/gui/drv_glx.c
   trunk/gui/graph.c
   trunk/gui/keyboard.c
   trunk/gui/keyboard.h
   trunk/gui/table.c
   trunk/gui/tlist.c
   trunk/gui/treetbl.c
   trunk/gui/widget.h
   trunk/math/m_plotter.c
   trunk/rg/pixmap.c
   trunk/rg/sketch.c
   trunk/vg/vg_proximity_tool.c
   trunk/vg/vg_view.h
Log:
document AG_GetKeyState() and AG_GetModState() in AG_Keyboard(3)

Added: trunk/gui/AG_Keyboard.3
===================================================================
--- trunk/gui/AG_Keyboard.3	                        (rev 0)
+++ trunk/gui/AG_Keyboard.3	2012-01-01 07:27:32 UTC (rev 9077)
@@ -0,0 +1,137 @@
+.\" Copyright (c) 2012 Hypertriton, Inc. <http://hypertriton.com/>
+.\" All rights reserved.
(Continue reading)

Agar-SVN | 1 Jan 08:26
Favicon

Agar: r9076 - trunk/math

Author: vedge
Date: 2012-01-01 02:26:19 -0500 (Sun, 01 Jan 2012)
New Revision: 9076

Modified:
   trunk/math/m_polygon.c
Log:
n must be >= 3 in M_PointInPolygon()

Modified: trunk/math/m_polygon.c
===================================================================
--- trunk/math/m_polygon.c	2012-01-01 07:25:34 UTC (rev 9075)
+++ trunk/math/m_polygon.c	2012-01-01 07:26:19 UTC (rev 9076)
@@ -231,6 +231,9 @@
 	M_Real ix;
 	M_Vector2 p1, p2;

+	if (P->n < 3)
+		return (0);
+
 	p1 = P->v[0];
 	for (i = 1; i <= P->n; i++) {
 		p2 = P->v[i % P->n];
Agar-SVN | 1 Jan 08:25
Favicon

Agar: r9075 - trunk/gui

Author: vedge
Date: 2012-01-01 02:25:34 -0500 (Sun, 01 Jan 2012)
New Revision: 9075

Modified:
   trunk/gui/Makefile
Log:
+ missing AG_Anim, AG_GlobalKeys, AG_Keyboard

Modified: trunk/gui/Makefile
===================================================================
--- trunk/gui/Makefile	2011-12-29 02:49:14 UTC (rev 9074)
+++ trunk/gui/Makefile	2012-01-01 07:25:34 UTC (rev 9075)
@@ -41,7 +41,8 @@
 	AG_WidgetPrimitives.3 AG_EventLoop.3 AG_BlendFn.3 AG_KeySym.3 \
 	AG_KeyMod.3 AG_Color.3 AG_MouseButton.3 AG_Driver.3 AG_InitGraphics.3 \
 	AG_DriverMw.3 AG_DriverSw.3 AG_DriverGLX.3 AG_DriverWGL.3 \
-	AG_DriverSDLFB.3 AG_DriverSDLGL.3 AG_GL.3 AG_DirDlg.3
+	AG_DriverSDLFB.3 AG_DriverSDLGL.3 AG_GL.3 AG_DirDlg.3 AG_Anim.3 \
+	AG_GlobalKeys.3 AG_Keyboard.3

 CFLAGS+=-D_AGAR_GUI_INTERNAL ${SDL_CFLAGS} ${FREETYPE_CFLAGS} ${OPENGL_CFLAGS} \
 	${X11_CFLAGS} ${XINERAMA_CFLAGS} ${JPEG_CFLAGS} ${PNG_CFLAGS} \
Agar-SVN | 29 Dec 03:49
Favicon

Agar: r9074 - trunk/gui

Author: vedge
Date: 2011-12-28 21:49:14 -0500 (Wed, 28 Dec 2011)
New Revision: 9074

Modified:
   trunk/gui/AG_Colors.3
Log:
typo

Modified: trunk/gui/AG_Colors.3
===================================================================
--- trunk/gui/AG_Colors.3	2011-12-24 03:02:16 UTC (rev 9073)
+++ trunk/gui/AG_Colors.3	2011-12-29 02:49:14 UTC (rev 9074)
@@ -138,7 +138,7 @@
 .Sh EXAMPLES
 The following code fragment sets the window background color to black:
 .Bd -literal -offset indent
-AG_ColorSetRGB(WINDOW_BG_COLOR, 0,0,0);
+AG_ColorsSetRGB(WINDOW_BG_COLOR, 0,0,0);
 .Ed
 .Sh SEE ALSO
 .Xr AG_Intro 3 ,
Agar-SVN | 23 Dec 02:16
Favicon

Agar: r9072 - in trunk: . gui

Author: vedge
Date: 2011-12-22 20:16:24 -0500 (Thu, 22 Dec 2011)
New Revision: 9072

Modified:
   trunk/configure
   trunk/configure.in
   trunk/gui/load_png.c
Log:
don't look for HAVE_LIBPNG14 if !HAVE_PNG

Modified: trunk/configure
===================================================================
--- trunk/configure	2011-12-22 03:47:22 UTC (rev 9071)
+++ trunk/configure	2011-12-23 01:16:24 UTC (rev 9072)
@@ -6608,11 +6608,15 @@
 			else
 echo "#undef HAVE_PNG" >$BLD/include/agar/config/have_png.h
 echo "hdefs[\"HAVE_PNG\"] = nil" >>configure.lua
+echo "#undef HAVE_LIBPNG14" >$BLD/include/agar/config/have_libpng14.h
+echo "hdefs[\"HAVE_LIBPNG14\"] = nil" >>configure.lua
 			fi
 		fi
 	else
 echo "#undef HAVE_PNG" >$BLD/include/agar/config/have_png.h
 echo "hdefs[\"HAVE_PNG\"] = nil" >>configure.lua
+echo "#undef HAVE_LIBPNG14" >$BLD/include/agar/config/have_libpng14.h
+echo "hdefs[\"HAVE_LIBPNG14\"] = nil" >>configure.lua
 PNG_CFLAGS=""
 echo "PNG_CFLAGS=$PNG_CFLAGS" >>Makefile.config
(Continue reading)


Gmane