aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/conversation.php14
-rw-r--r--include/identity.php11
-rw-r--r--include/text.php33
3 files changed, 58 insertions, 0 deletions
diff --git a/include/conversation.php b/include/conversation.php
index 3bbaf0cba..59f2f2ed8 100644
--- a/include/conversation.php
+++ b/include/conversation.php
@@ -206,6 +206,20 @@ function localize_item(&$item){
$item['body'] = sprintf($txt, $A, $B). "\n\n\n" . $Bphoto;
}
+ if (stristr($item['verb'],ACTIVITY_MOOD)) {
+ $verb = urldecode(substr($item['verb'],strpos($item['verb'],'#')+1));
+ if(! $verb)
+ return;
+
+ $Aname = $item['author-name'];
+ $Alink = $item['author-link'];
+ $A = '[url=' . zrl($Alink) . ']' . $Aname . '[/url]';
+
+ $txt = t('%1$s is currently %2$s');
+
+ $item['body'] = sprintf($txt, $A, t($verb));
+ }
+
if ($item['verb']===ACTIVITY_TAG){
$r = q("SELECT * from `item`,`contact` WHERE
`item`.`contact-id`=`contact`.`id` AND `item`.`uri`='%s';",
diff --git a/include/identity.php b/include/identity.php
index 5164b5eae..8f906228f 100644
--- a/include/identity.php
+++ b/include/identity.php
@@ -1,6 +1,17 @@
<?php
+function create_identity($arr) {
+
+
+
+
+}
+
+
+
+
+
class simple_identity {
diff --git a/include/text.php b/include/text.php
index d49b2269c..feafafd06 100644
--- a/include/text.php
+++ b/include/text.php
@@ -670,6 +670,39 @@ function get_poke_verbs() {
return $arr;
}
+function get_mood_verbs() {
+
+ // index is present tense verb
+ // value is array containing past tense verb, translation of present, translation of past
+
+ $arr = array(
+ 'happy' => t('happy'),
+ 'sad' => t('sad'),
+ 'mellow' => t('mellow'),
+ 'tired' => t('tired'),
+ 'perky' => t('perky'),
+ 'angry' => t('angry'),
+ 'stupefied' => t('stupified'),
+ 'puzzled' => t('puzzled'),
+ 'interested' => t('interested'),
+ 'bitter' => t('bitter'),
+ 'cheerful' => t('cheerful'),
+ 'alive' => t('alive'),
+ 'annoyed' => t('annoyed'),
+ 'anxious' => t('anxious'),
+ 'cranky' => t('cranky'),
+ 'disturbed' => t('disturbed'),
+ 'frustrated' => t('frustrated'),
+ 'motivated' => t('motivated'),
+ 'relaxed' => t('relaxed'),
+ 'surprised' => t('surprised'),
+ );
+
+ call_hooks('mood_verbs', $arr);
+ return $arr;
+}
+
+
/**
*
* Function: smilies