← Back to team overview

ayatana-commits team mailing list archive

Re: [Merge] lp:~karl-qdh/indicator-datetime/fixappointmentformat into lp:indicator-datetime

 

Review: Needs Fixing
On Tue, 2011-03-08 at 16:09 +0000, Karl Lattimer wrote:
> +	gchar *time_format_str = g_settings_get_string(conf, SETTINGS_TIME_FORMAT_S);
> +	gint apt_output;
> +	if (g_strcmp0(time_format_str, "12-hour") == 0) {
> +		apt_output = SETTINGS_TIME_12_HOUR;
> +	} else if (g_strcmp0(time_format_str, "24-hour") == 0) {
> +		apt_output = SETTINGS_TIME_24_HOUR;
> +	} else {
> +		apt_output = SETTINGS_TIME_LOCALE;
> +	}

I think that you should be able to use priv->time_mode instead of
apt_output here.

> +		if (apt_output == SETTINGS_TIME_12_HOUR) {
> +			if ((mday == dmday) && (mon == dmon) && (year == dyear))
> +				strftime(right, 20, DEFAULT_TIME_12_FORMAT, due);
> +			else
> +				strftime(right, 20, DEFAULT_TIME_12_FORMAT_WITH_DAY, due);
> +		} else if (apt_output == SETTINGS_TIME_24_HOUR) {
> +			if ((mday == dmday) && (mon == dmon) && (year == dyear))
> +				strftime(right, 20, DEFAULT_TIME_24_FORMAT, due);
> +			else
> +				strftime(right, 20, DEFAULT_TIME_24_FORMAT_WITH_DAY, due);
> +		} else {
> +			if ((mday == dmday) && (mon == dmon) && (year == dyear))
> +				strftime(right, 20, DEFAULT_TIME_FORMAT, due);
> +			else
> +				strftime(right, 20, DEFAULT_TIME_FORMAT_WITH_DAY, due);
> +		}
> +		

All of the strings being passed to strftime need a _() around them so
that they go through gettext.

  review needsfixing

-- 
https://code.launchpad.net/~karl-qdh/indicator-datetime/fixappointmentformat/+merge/52574
Your team ayatana-commits is subscribed to branch lp:indicator-datetime.



Follow ups

References