Removed unnecessary const prefix from GsweMoment methods returning boxed types

This commit is contained in:
Gergely Polonkai 2013-10-04 00:19:11 +02:00
parent c78108ce84
commit 54698df423
2 changed files with 8 additions and 8 deletions

View File

@ -871,9 +871,9 @@ gswe_moment_get_house(GsweMoment *moment, gdouble position, GError **err)
* warning. Thus, you should always provide a non-NULL value for @err, and
* always check it after calling this function.
*
* Returns: (transfer none): @planet's data
* Returns: (transfer full): @planet's data
*/
const GswePlanetData *
GswePlanetData *
gswe_moment_get_planet(GsweMoment *moment, GswePlanet planet, GError **err)
{
GswePlanetData *planet_data = (GswePlanetData *)(g_list_find_custom(moment->priv->planet_list, &planet, (GCompareFunc)find_planet_by_id)->data);
@ -886,7 +886,7 @@ gswe_moment_get_planet(GsweMoment *moment, GswePlanet planet, GError **err)
gswe_moment_calculate_planet(moment, planet, err);
return planet_data;
return gswe_planet_data_ref(planet_data);
}
static void
@ -967,9 +967,9 @@ gswe_moment_get_quality_points(GsweMoment *moment, GsweQuality quality)
*
* Gets the phase of the Moon.
*
* Returns: (transfer none): a #GsweMoonPhaseData representing the phase of the Moon
* Returns: (transfer full): a #GsweMoonPhaseData representing the phase of the Moon
*/
const GsweMoonPhaseData *
GsweMoonPhaseData *
gswe_moment_get_moon_phase(GsweMoment *moment, GError **err)
{
gdouble difference,
@ -1028,7 +1028,7 @@ gswe_moment_get_moon_phase(GsweMoment *moment, GError **err)
moment->priv->moon_phase_revision = moment->priv->revision;
return moment->priv->moon_phase;
return gswe_moon_phase_data_ref(moment->priv->moon_phase);
}
static gint

View File

@ -108,14 +108,14 @@ gboolean gswe_moment_has_planet(GsweMoment *moment, GswePlanet planet);
void gswe_moment_add_planet(GsweMoment *moment, GswePlanet planet, GError **err);
void gswe_moment_add_all_planets(GsweMoment *moment);
GList *gswe_moment_get_all_planets(GsweMoment *moment);
const GswePlanetData *gswe_moment_get_planet(GsweMoment *moment, GswePlanet planet, GError **err);
GswePlanetData *gswe_moment_get_planet(GsweMoment *moment, GswePlanet planet, GError **err);
GList *gswe_moment_get_sign_planets(GsweMoment *moment, GsweZodiac sign);
GList *gswe_moment_get_house_planets(GsweMoment *moment, guint house);
guint gswe_moment_get_element_points(GsweMoment *moment, GsweElement element);
guint gswe_moment_get_quality_points(GsweMoment *moment, GsweQuality quality);
const GsweMoonPhaseData *gswe_moment_get_moon_phase(GsweMoment *moment, GError **err);
GsweMoonPhaseData *gswe_moment_get_moon_phase(GsweMoment *moment, GError **err);
GList *gswe_moment_get_all_aspects(GsweMoment *moment);
GList *gswe_moment_get_planet_aspects(GsweMoment *moment, GswePlanet planet, GError **err);