Allow a custom string to be passed into `bp_get_member_last_active()`'s `active_format` argument.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8748 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Bump "tested up to" header to 3.9.1

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8749 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Allow group member avatars to be passed an array of arguments, bringing them up-to-speed with pretty much all other avatar fetching functions. Pass the computed a`$r`guments array into the associated filters. (No changes to default arguments in these functions.)

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8750 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Clean up `bp_get_group_avatar()`:

* Remove `$bp` global
* Use `bp_parse_args()`
* Code format tidying
* Pass `$r` through filter
* Add documentation

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8751 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Clean up `bp_get_group_avatar_thumb()` and `bp_get_group_avatar_mini()` functions:

* Actually allow usage of `$group` parameter if passed
* Use array over query string
* Add phpdoc blocks

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8752 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Core: adjust the SQL generated by `BP_User_Query`'s `search_wildcard` parameter for better Suggestions API search results.

Introduced in r8675, the `search_wildcard` parameter controls where BuddyPress places MySQL wildcard characters around the search term (when it's set).

This change adjusts how the wildcard SQL is constructed; in addition to the wildcard, we now also check for matches that have a single space character at the opposite end of the string (from where the wildcard is). This allows searching data that looks like (for example) a surname in a combined first name/surname field.
e.g. if a displayname is "Paul Gibbs", you can search for "Gi", and with `search_wildcard=right`, the SQL generated will be `LIKE 'Gi%' OR LIKE '% Gi%'`.

See #3278

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8753 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Activity: introducing @mentions auto-suggestions.

Activity has long-supported @mentions, where you can mention the name of another user to get their attention in a conversation. You've always had to know the exact username of the person you're trying to mention, or you've been forced to go look it up. Now, when leaving an activity update or reply, press `@` and then start typing someone's diaply name (or user_nicename), and username suggestions will automatically appear below where you're typing.

If the Friends component is active, and if the logged-in user has any friends, those friends' details are used to pre-prime the username suggestions for super-fast snappy suggestions. Suggestions are also provided when writing a blog post comment.

This change has mostly been implemented using two third-party libraries, At.js (https://github.com/ichord/At.js) and Caret.js (https://github.com/ichord/Caret.js). Big thanks to those projects' authors for their fine work, and also to Automattic's O2 team, who made a number of CSS+JS tweaks/adaptions to At.js, which we've adopted. Props also to karmatosed for design suggestions on the earliest implementation of this feature, three years ago. :)

Fixes #3278

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8754 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Clean up `bp_has_blogs()` a bit:

* Remove unnecessary comparisons
* Remove one-time use variables
* `empty()` checks where appropriate

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8757 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Clean up `BP_Blogs_Template()` methods:

* Add inline doc
* Use `public` modifiers
* Normalize comparisons
* Add default variable values
* Add brackets and bring code formatting up to date
* Use `empty()` checks where appropriate

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8758 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Bring `bp_get_blog_avatar()` up to speed with `bp_get_group_avatar()`:

* Add inline doc
* Use `bp_parse_args()`
* Add brackets and bring code formatting up to date

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8759 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
In `bp_get_blog_avatar()` bail if avatars are turned off, to be consistent with all other avatar output functions.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8760 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Allow notifications loop to accept all available parameters.

Previously, the notifications loop accepted only a subset of parameters
from the `BP_Notification_Notification::get()` method.  This made
notification loop filtering very restrictive.

This commit opens up the notifications loop so all parameters are available
as per the `BP_Notifications_Notification::get()` fetch method.

Fixes #5558.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8761 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Activity: fix bug where activity comments were not being shown to anonymous users.

Fixes #5567, props wolfhoundjesse

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8762 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Blogs: Fix warning in function call when updating "Close Comments Days Old" option.

Props ebellempire.  Anti-props r-a-y.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8763 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Separate out registering and enqueing of `bp-admin-bar` styling.

This allows theme and plugin authors more flexibility in how they override BuddyPress's default behaviour, and also more closely follows our existing conventions for other scripts and styles.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8764 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Remove `$version` variable in `bp_core_register_common_styles()`.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8765 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Grunt: simplify list of CSS files used in the build tasks.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8766 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Grunt: simplify list of JS files used in the build tasks.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8767 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Grunt: simply jsvalidate syntax in build config, and also run on minified JS files.

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8768 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
Core: fix `bp_core_register_deprecated_styles` and `bp_core_register_common_styles` to load RTL CSS.

See #5614

git-svn-id: https://buddypress.svn.wordpress.org/trunk@8769 cdf35c40-ae34-48e0-9cc9-0c9da1808c22