Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Commit

Permalink
Change order of GFormatSizeFlags
Browse files Browse the repository at this point in the history
David requested that I change the order of the flags.

Also, assign numerical values to the flags in the usual way.  This
wasn't a bug yet, but only by chance.
  • Loading branch information
allisonkarlitskaya committed Jul 20, 2011
1 parent c26462a commit 8cadef1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions glib/gfileutils.c
Expand Up @@ -1826,15 +1826,15 @@ g_format_size (guint64 size)
/**
* GFormatSizeFlags:
* @G_FORMAT_SIZE_DEFAULT: behave the same as g_format_size()
* @G_FORMAT_SIZE_LONG_FORMAT: include the exact number of bytes as part
* of the returned string. For example,
* "45.6 kB (45,612 bytes)".
* @G_FORMAT_SIZE_IEC_UNITS: use IEC (base 1024) units with "KiB"-style
* suffixes. IEC units should only be used
* for reporting things with a strong "power
* of 2" basis, like RAM sizes or RAID stripe
* sizes. Network and storage sizes should
* be reported in the normal SI units.
* @G_FORMAT_SIZE_LONG_FORMAT: include the exact number of bytes as part
* of the returned string. For example,
* "45.6 kB (45,612 bytes)".
*
* Flags to modify the format of the string returned by
* g_format_size_full().
Expand Down
6 changes: 3 additions & 3 deletions glib/gfileutils.h
Expand Up @@ -112,9 +112,9 @@ gint g_file_open_tmp (const gchar *tmpl,

typedef enum
{
G_FORMAT_SIZE_DEFAULT,
G_FORMAT_SIZE_IEC_UNITS,
G_FORMAT_SIZE_LONG_FORMAT
G_FORMAT_SIZE_DEFAULT = 0,
G_FORMAT_SIZE_LONG_FORMAT = 1 << 0,
G_FORMAT_SIZE_IEC_UNITS = 1 << 1
} GFormatSizeFlags;

gchar * g_format_size_full (guint64 size,
Expand Down

0 comments on commit 8cadef1

Please sign in to comment.