Index: l10n_community/l10n_community.css
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/l10n_server/l10n_community/Attic/l10n_community.css,v
retrieving revision 1.1.2.10.2.6.2.3
diff -u -p -r1.1.2.10.2.6.2.3 l10n_community.css
--- l10n_community/l10n_community.css	10 Mar 2010 07:45:03 -0000	1.1.2.10.2.6.2.3
+++ l10n_community/l10n_community.css	10 Mar 2010 11:41:31 -0000
@@ -4,6 +4,7 @@ div.admin .admin-panel-contribute {
   background: #ffb;
   margin-bottom: 2em;
   padding-bottom: 0.3em;
+  position: relative;
 }
 table.l10n-community-overview {
   width: 45%;
@@ -22,6 +23,17 @@ div.admin .form-submit {
 div.admin form {
   margin-bottom: 0 !important;
 }
+div.admin .l10n-join-group {
+  text-align: center;
+  font-weight: bold;
+  font-size: 1.3em;
+  position: absolute;
+  top: 0.8em;
+  right: 0.6em;
+}
+div.admin .l10n-join-group a {
+  padding: 0.3em;
+}
 
 /* Overview navigation tables for projects and languages */
 .l10n-community-overview td, .l10n-community-overview thead th {
Index: l10n_community/pages.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/l10n_server/l10n_community/Attic/pages.inc,v
retrieving revision 1.1.2.20.2.24.2.4
diff -u -p -r1.1.2.20.2.24.2.4 pages.inc
--- l10n_community/pages.inc	1 Mar 2010 13:50:22 -0000	1.1.2.20.2.24.2.4
+++ l10n_community/pages.inc	10 Mar 2010 11:41:31 -0000
@@ -25,10 +25,6 @@ function l10n_community_explore_language
 
   // Generate listing of all languages with summaries. The list of languages
   // is relatively "short", compared to projects, so we don't need a pager here.
-  $groups = array();
-  if (module_exists('l10n_groups')) {
-    $groups = l10n_groups_get_groups();
-  }
   $table = array();
   $string_counts = l10n_community_get_string_count('languages');
   foreach ($languages as $langcode => $language) {
@@ -98,6 +94,8 @@ function l10n_community_explore_projects
  *   Language code, for example 'hu', 'pt-br', 'de', 'it'.
  */
 function l10n_community_overview_language($langcode = NULL) {
+  global $user;
+
   // Add missing breadcrumb.
   drupal_set_breadcrumb(
     array(
@@ -115,34 +113,44 @@ function l10n_community_overview_languag
   $languages = l10n_community_get_languages('name');
   drupal_set_title(t('@language overview', array('@language' => $languages[$langcode])));
 
-  $output = '<div id="l10n-community-summary" class="admin clear-block"><div class="left clear-block">';
-
-  $has_posts = FALSE;
-  if (module_exists('taxonomy') && ($term = taxonomy_get_term_by_name('l10n-server-'. $langcode))) {
-    $result = taxonomy_select_nodes(array($term[0]->tid), 'or', 0, TRUE);
-    while ($node = db_fetch_object($result)) {
-      $has_posts = TRUE;
-      $output .= node_view(node_load($node->nid), 1);
+  $content_output = $group_prefix = '';
+  if (module_exists('l10n_groups')) {
+    // If l10n_groups available, try to load group frontpage.
+    $groups = l10n_groups_get_groups();
+    if (isset($groups[$langcode]) && node_access('view', $group_node = node_load($groups[$langcode]))) {
+      $content_output = node_view($group_node, FALSE, TRUE);
+      if (!isset($user->og_groups[$groups[$langcode]])) {
+        $group_prefix = '<div class="l10n-join-group">'. og_subscribe_link($group_node) .'</div>';
+      }
+    }
+    else {
+      $content_output .= '<p>'. t('Group not found or not accessible. No posts to display') .'</p>';
     }
   }
-  if (!$has_posts) {
-    $output .= '<p>'. t('There are currently no posts set for display here. Mark posts to display here with the %tagname tag, using the taxonomy module.', array('%tagname' => 'l10n-server-'. $langcode)) .'</p>';
+  elseif (module_exists('taxonomy')) {
+    if ($term = taxonomy_get_term_by_name('l10n-server-'. $langcode)) {
+      // Found tag, look for posts.
+      $result = taxonomy_select_nodes(array($term[0]->tid), 'or', 0, TRUE);
+      while ($node = db_fetch_object($result)) {
+        $content_output .= node_view(node_load($node->nid), 1);
+      }
+    }
+    if (empty($content_output)) {
+      // Either no such tag, or that tag has no posts currently.
+      $output .= '<p>'. t('There are currently no posts set for display here. Mark posts to display here with the %tagname tag, using the taxonomy module.', array('%tagname' => 'l10n-server-'. $langcode)) .'</p>';
+    }
+  }
+  else {
+    // Neither l10n_groups, neither taxonomy available.
+    $content_output .= '<p>'. t('No posts to display') .'</p>';
   }
 
-  $output .= '</div><div class="right clear-block">';
+  $output = '<div id="l10n-community-summary" class="admin clear-block"><div class="left clear-block">'. $content_output .'</div><div class="right clear-block">';
 
-  $group_help = '';
-  if (module_exists('l10n_groups')) {
-    // A little extra message if the groups module is enabled.
-    $groups = l10n_groups_get_groups();
-    if (isset($groups[$langcode])) {
-      $group_help = '<p>'. t('The <a href="@group">%language group</a> pages might provide you with more information, translation suggestions and guidelines.', array('@group' => url('node/'. $groups[$langcode]->nid), '%language' => $languages[$langcode])) .'</p>';
-    }
-  }
   $block = array(
     'title' => t('Contribute'),
     'description' => t('Review, translate, import'),
-    'content' => '<p class="info">'. t('Different tabs allow you to view existing translations, suggest new ones, import translations completed offline or export translations for import to Drupal or offline work.') .'</p>'. $group_help
+    'content' => $group_prefix .'<p class="info">'. t('Different tabs allow you to view existing translations, suggest new ones, import translations completed offline or export translations for use or  offline work.') .'</p>'
   );
   $output .= str_replace('class="admin-panel"', 'class="admin-panel admin-panel-contribute"', theme('admin_block', $block));
 
Index: l10n_groups/l10n_groups.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/l10n_server/l10n_groups/Attic/l10n_groups.module,v
retrieving revision 1.1.2.4.2.10.2.1
diff -u -p -r1.1.2.4.2.10.2.1 l10n_groups.module
--- l10n_groups/l10n_groups.module	7 Mar 2010 16:55:16 -0000	1.1.2.4.2.10.2.1
+++ l10n_groups/l10n_groups.module	10 Mar 2010 11:41:32 -0000
@@ -9,6 +9,22 @@
 // = Core hooks ================================================================
 
 /**
+ * Implementation of hook_menu().
+ */
+function l10n_groups_menu() {
+  $items['translate/languages/%l10n_community_language/broadcast'] = array(
+    'title' => 'Broadcast',
+    'page callback' => 'l10n_groups_broadcast',
+    'page arguments' => array(2),
+    'access callback' => 'l10n_groups_broadcast_access',
+    'access arguments' => array(2),
+    'type' => MENU_LOCAL_TASK,
+    'weight' => 200,
+  );
+  return $items;
+}
+
+/**
  * Implementation of hook_perm().
  */
 function l10n_groups_perm() {
@@ -53,6 +69,11 @@ function l10n_groups_init() {
       l10n_groups_set_context($langcode);
     }
   }
+  if (($item = menu_get_item()) && ($item['path'] == 'node/%') && ($item['page_arguments'][0]->type == 'l10n_group')) {
+    // If on node view page for l10n_group nodes, redirect to our more full featured
+    // version of the group with translation tabs and all.
+    drupal_goto('translate/languages/'. $item['page_arguments'][0]->l10n_group_language);
+  }
 }
 
 /**
@@ -62,7 +83,7 @@ function l10n_groups_set_context($langco
   $groups = l10n_groups_get_groups();
   if (isset($groups[$langcode])) {
     // Set group context and ask for og details block.
-    $node = node_load($groups[$langcode]->nid);
+    $node = node_load($groups[$langcode]);
     og_set_group_context($node);
   }
 }
@@ -211,6 +232,17 @@ function l10n_groups_form($node, $form_s
   return $form;
 }
 
+/**
+ * Implementation of hook_og_create_links().
+ */
+function l10n_groups_og_create_links($node) {
+  $links = array();
+  if (node_access('update', $node)) {
+    $links['edit_group'] = l(t('Edit group'), 'node/'. $node->nid .'/edit');
+  }
+  return $links;
+}
+
 // = API functions =============================================================
 
 /**
@@ -231,10 +263,10 @@ function l10n_groups_block_help($perm, $
   $groups = l10n_groups_get_groups();
   $permission_help = '';
 
-  if (empty($user->og_groups) || empty($user->og_groups[$groups[$langcode]->nid])) {
-    $permission_help = t('You are not a member of this translation group.') .' '. ($user->uid ? t('<a href="@group">Subscribe to this group</a> if you would like to help out.', array('@group' => url('node/'. $groups[$langcode]->nid))) : t('<a href="@register">Create an account or log in</a> and <a href="@group">subscribe to this group</a> if you would like to help out.', array('@register' => url('user'), '@group' => url('node/'. $groups[$langcode]->nid))));
+  if (empty($user->og_groups) || empty($user->og_groups[$groups[$langcode]])) {
+    $permission_help = t('You are not a member of this translation group.') .' '. ($user->uid ? t('<a href="@group">Subscribe to this group</a> if you would like to help out.', array('@group' => url('node/'. $groups[$langcode]))) : t('<a href="@register">Create an account or log in</a> and <a href="@group">subscribe to this group</a> if you would like to help out.', array('@register' => url('user'), '@group' => url('node/'. $groups[$langcode]))));
   }
-  elseif (!empty($user->og_groups[$groups[$langcode]->nid]['is_admin'])) {
+  elseif (!empty($user->og_groups[$groups[$langcode]]['is_admin'])) {
     $permission_help = t('You are an administrator in this translation group.');
   }
 
@@ -254,7 +286,7 @@ function l10n_groups_get_groups() {
     $groups = array();
     $result = db_query('SELECT nid, language FROM {l10n_groups_group}');
     while ($group = db_fetch_object($result)) {
-      $groups[$group->language] = $group;
+      $groups[$group->language] = $group->nid;
     }
   }
 
@@ -285,3 +317,23 @@ function l10n_groups_pick_go() {
     }
   }
 }
+
+/**
+ * Menu access callback for broadcast proxy tab.
+ */
+function l10n_groups_broadcast_access($langcode) {
+  $groups = l10n_groups_get_groups();
+  if (isset($groups[$langcode])) {
+    return og_broadcast_access(node_load($groups[$langcode]));
+  }
+  return FALSE;
+}
+
+/**
+ * Menu callback for broadcast proxy tab.
+ */
+function l10n_groups_broadcast($langcode) {
+  $groups = l10n_groups_get_groups();
+  include_once drupal_get_path('module', 'og') .'/og.pages.inc';
+  return drupal_get_form('og_broadcast_form', node_load($groups[$langcode]));
+}
