forked from enlightenment/efl
Move private function in the right part of the file.
SVN revision: 35729
This commit is contained in:
parent
edad077c64
commit
67f3ddfb7a
|
@ -86,6 +86,26 @@ struct _Eina_Stringshare_Node
|
|||
static Eina_Stringshare *share = NULL;
|
||||
static int eina_stringshare_init_count = 0;
|
||||
|
||||
static int
|
||||
_eina_stringshare_cmp(const Eina_Stringshare_Node *node, const char *key, int length, __UNUSED__ void *data)
|
||||
{
|
||||
const char *el_str;
|
||||
|
||||
el_str = (const char *) (node + 1);
|
||||
return strncmp(el_str, key, length);
|
||||
}
|
||||
|
||||
static Eina_Rbtree_Direction
|
||||
_eina_stringshare_node(const Eina_Stringshare_Node *left, const Eina_Stringshare_Node *right, __UNUSED__ void *data)
|
||||
{
|
||||
if (!left) return EINA_RBTREE_RIGHT;
|
||||
if (!right) return EINA_RBTREE_LEFT;
|
||||
|
||||
if (strcmp((const char*) (left + 1), (const char*) (right + 1)) < 0)
|
||||
return EINA_RBTREE_LEFT;
|
||||
return EINA_RBTREE_RIGHT;
|
||||
}
|
||||
|
||||
/*============================================================================*
|
||||
* Global *
|
||||
*============================================================================*/
|
||||
|
@ -139,26 +159,6 @@ eina_stringshare_init()
|
|||
return 1;
|
||||
}
|
||||
|
||||
static int
|
||||
_eina_stringshare_cmp(const Eina_Stringshare_Node *node, const char *key, int length, __UNUSED__ void *data)
|
||||
{
|
||||
const char *el_str;
|
||||
|
||||
el_str = (const char *) (node + 1);
|
||||
return strncmp(el_str, key, length);
|
||||
}
|
||||
|
||||
static Eina_Rbtree_Direction
|
||||
_eina_stringshare_node(const Eina_Stringshare_Node *left, const Eina_Stringshare_Node *right, __UNUSED__ void *data)
|
||||
{
|
||||
if (!left) return EINA_RBTREE_RIGHT;
|
||||
if (!right) return EINA_RBTREE_LEFT;
|
||||
|
||||
if (strcmp((const char*) (left + 1), (const char*) (right + 1)) < 0)
|
||||
return EINA_RBTREE_LEFT;
|
||||
return EINA_RBTREE_RIGHT;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves an instance of a string for use in a program.
|
||||
* @param str The string to retrieve an instance of.
|
||||
|
|
Loading…
Reference in New Issue