From a7d2dc7637a923f4b5ba5530b7328e8a55f22985 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Tue, 22 Nov 2011 18:20:33 -0200 Subject: Messages icon in actions handler --- muamba.module | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'muamba.module') diff --git a/muamba.module b/muamba.module index 1a5967d..5251379 100644 --- a/muamba.module +++ b/muamba.module @@ -141,12 +141,14 @@ function muamba_theme($existing, $type, $theme, $path) { 'transactions' => NULL, 'available' => NULL, 'size' => 'small', + 'messages' => FALSE, ), ), 'muamba_widget_owner' => array( 'variables' => array( 'transaction' => NULL, 'size' => 'small', + 'messages' => FALSE, ), 'file' => 'muamba.theme.inc', ), @@ -154,6 +156,7 @@ function muamba_theme($existing, $type, $theme, $path) { 'variables' => array( 'transaction' => NULL, 'size' => 'small', + 'messages' => FALSE, ), 'file' => 'muamba.theme.inc', ), @@ -265,26 +268,26 @@ function muamba_privatemsg_view_alter(&$content) { $transaction = muamba_get_transaction($thread, 'thread_id'); if (!empty($transaction)) { - global $user; - include_once('muamba.embed.inc'); + $title = '

'. t('Messages') .'

'; + $info = muamba_embed_view('transacoes', array($transaction['mid']), 'info'); + + /* + global $user; $node = node_load($transaction['nid']); $available = muamba_check_availability($node->nid); $widget = ($node->uid == $user->uid) ? 'owner' : 'requester'; - $info = muamba_embed_view('muambas', array($node->nid), 'info'); - $title = '

'. t('Messages') .'

'; - /* $bar = theme('muamba_widget_'. $widget, array( 'node' => $node, 'transaction' => $transaction, 'available' => $available, 'size' => 'big', )); + $content['participants']['#markup'] = $bar . $content['participants']['#markup']; */ - //$content['participants']['#markup'] = $bar . $content['participants']['#markup']; $content['participants']['#markup'] = $info . $title; } } -- cgit v1.2.3