/**********************************************************************
 
	Copyright (C) 2003 Hirohisa MORI <joshua@nichibun.ac.jp>
 
	This program is free software; you can redistribute it 
	and/or modify it under the terms of the GLOBALBASE 
	Library General Public License (G-LGPL) as published by 

	http://www.globalbase.org/
 
	This program is distributed in the hope that it will be 
	useful, but WITHOUT ANY WARRANTY; without even the 
	implied warranty of MERCHANTABILITY or FITNESS FOR A 
	PARTICULAR PURPOSE.

**********************************************************************/


#include	"win_flame.h"



GBVIEW_FLAME *
get_gf_from_sf(XL_SYM_FIELD * sf)
{
GBVIEW_FLAME * gf;
L_CHAR * gf_id;
	gf_id = get_sf_attribute(sf,l_string(std_cm,"flame-id"));
	if ( gf_id ) {
		gf = wf_get_gf_from_id(atoi(n_string(std_cm,gf_id)));
	}
	else 	gf = 0;
	if ( gf == 0 )
		gf = wf_next_gf(0,GVFM_LIVE);
	return gf;
}
