From a157bc24b3de6444754b25627ae0129e61776182 Mon Sep 17 00:00:00 2001 From: dmzx Date: Sun, 29 Mar 2015 14:15:29 +0200 Subject: [PATCH] Update version 0.0.13 Update version 0.0.13 --- acp/acp_mchat_module.php | 16 ++++-------- composer.json | 2 +- core/render_helper.php | 25 ++++++++++++------- event/listener.php | 2 +- language/de/common.php | 15 +++-------- language/en/common.php | 13 +++------- language/en/info_acp_mchat.php | 3 +++ language/fr/common.php | 15 +++-------- language/it/common.php | 15 +++-------- language/nl/common.php | 15 +++-------- language/pl/common.php | 15 +++-------- migrations/mchat_schema.php | 8 +++++- styles/prosilver/template/mchat_avatars.html | 4 +-- styles/prosilver/template/mchat_body.html | 3 ++- styles/prosilver/theme/images/message.gif | Bin 0 -> 576 bytes styles/prosilver/theme/mchat.css | 8 +++++- 16 files changed, 67 insertions(+), 92 deletions(-) create mode 100644 styles/prosilver/theme/images/message.gif diff --git a/acp/acp_mchat_module.php b/acp/acp_mchat_module.php index 7370d51..7feb8b8 100644 --- a/acp/acp_mchat_module.php +++ b/acp/acp_mchat_module.php @@ -62,7 +62,6 @@ class acp_mchat_module $this->config = $config; $this->config_text = $phpbb_container->get('config_text'); $this->db = $db; - $this->request = $request; $this->template = $template; $this->user = $user; @@ -160,19 +159,19 @@ class acp_mchat_module $config->set('mchat_enable', $request->variable('mchat_enable', 0)); // update setting in config table for allowing on index or not $config->set('mchat_on_index', $request->variable('mchat_on_index', 0)); - // update setting in config table to allow new posts to display or not + // update setting in config table to enable posts to display or not $config->set('mchat_new_posts', $request->variable('mchat_new_posts', 0)); - // update setting in config table to allow new posts to display or not + // update setting in config table to allow topic to display or not $config->set('mchat_new_posts_topic', $request->variable('mchat_new_posts_topic', 0)); - // update setting in config table to allow new replies to display or not + // update setting in config table to allow replies to display or not $config->set('mchat_new_posts_reply', $request->variable('mchat_new_posts_reply', 0)); - // update setting in config table to allow new edit posts to display or not + // update setting in config table to allow edit posts to display or not $config->set('mchat_new_posts_edit', $request->variable('mchat_new_posts_edit', 0)); // update setting in config table to allow quoted posts to display or not $config->set('mchat_new_posts_quote', $request->variable('mchat_new_posts_quote', 0)); // update setting in config table for stats on index $config->set('mchat_stats_index', $request->variable('mchat_stats_index', 0)); - // update setting in config table for message om top + // update setting in config table for message on top $config->set('mchat_message_top', $request->variable('mchat_message_top', 0)); // and an entry into the log table @@ -206,9 +205,7 @@ class acp_mchat_module $mchat_new_posts_reply = isset($config['mchat_new_posts_reply']) ? $config['mchat_new_posts_reply'] : 0; $mchat_new_posts_edit = isset($config['mchat_new_posts_edit']) ? $config['mchat_new_posts_edit'] : 0; $mchat_new_posts_quote = isset($config['mchat_new_posts_quote']) ? $config['mchat_new_posts_quote'] : 0; - $mchat_stats_index = isset($config['mchat_stats_index']) ? $config['mchat_stats_index'] : 0; - $mchat_message_top = isset($config['mchat_message_top']) ? $config['mchat_message_top'] : 0; $dateformat_options = ''; @@ -263,12 +260,9 @@ class acp_mchat_module 'MCHAT_NEW_POSTS_REPLY' => ($mchat_new_posts_reply) ? true : false, 'MCHAT_NEW_POSTS_EDIT' => ($mchat_new_posts_edit) ? true : false, 'MCHAT_NEW_POSTS_QUOTE' => ($mchat_new_posts_quote) ? true : false, - 'MCHAT_PAUSE_ON_INPUT' => !empty($mchat_row['pause_on_input']) ? $mchat_row['pause_on_input'] : $mchat_config['pause_on_input'], - 'L_MCHAT_BBCODES_DISALLOWED_EXPLAIN' => sprintf($user->lang['MCHAT_BBCODES_DISALLOWED_EXPLAIN'], 'session_id) . '">', ''), 'L_MCHAT_TIMEOUT_EXPLAIN' => sprintf($user->lang['MCHAT_USER_TIMEOUT_EXPLAIN'],'session_id) . '">', '', $config['session_length']), - 'S_MCHAT_DATEFORMAT_OPTIONS' => $dateformat_options, 'S_CUSTOM_DATEFORMAT' => $s_custom, diff --git a/composer.json b/composer.json index f5f742c..4958114 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "type": "phpbb-extension", "description": "mChat Extension for phpbb 3.1.x", "homepage": "http://www.dmzx-web.net", - "version": "0.0.12", + "version": "0.0.13", "time": "2015-03-10", "keywords": ["phpbb", "extension", "mchat"], "license": "GPL-2.0", diff --git a/core/render_helper.php b/core/render_helper.php index 67b91e9..f81bac5 100644 --- a/core/render_helper.php +++ b/core/render_helper.php @@ -86,6 +86,7 @@ class render_helper // Add lang file //$this->user->add_lang(array('mods/mchat_lang', 'viewtopic', 'posting')); + $this->user->add_lang('posting'); //chat enabled if (!$this->config['mchat_enable']) @@ -114,6 +115,9 @@ class render_helper $mchat_smilies = ($this->config['allow_smilies'] && $this->auth->acl_get('u_mchat_smilies')) ? true : false; $mchat_urls = ($this->config['allow_post_links'] && $this->auth->acl_get('u_mchat_urls')) ? true : false; $mchat_ip = ($this->auth->acl_get('u_mchat_ip')) ? true : false; + $mchat_pm = ($this->auth->acl_get('u_mchat_pm')) ? true : false; + $mchat_like = ($this->auth->acl_get('u_mchat_like')) ? true : false; + $mchat_quote = ($this->auth->acl_get('u_mchat_quote')) ? true : false; $mchat_add_mess = ($this->auth->acl_get('u_mchat_use')) ? true : false; $mchat_view = ($this->auth->acl_get('u_mchat_view')) ? true : false; $mchat_no_flood = ($this->auth->acl_get('u_mchat_flood_ignore')) ? true : false; @@ -254,11 +258,11 @@ class render_helper meta_refresh(3, $mchat_redirect); // Return for: \$this->helper->error(error_text, error_type); - return array( - 'error' => true, - 'error_type' => E_USER_NOTICE, - 'error_text' => $this->user->lang['MCHAT_CLEANED'].'

'.sprintf($this->user->lang['RETURN_PAGE'], '', ''), - ); + // return array( + // 'error' => true, + // 'error_type' => E_USER_NOTICE, + // 'error_text' => $this->user->lang['MCHAT_CLEANED'].'

'.sprintf($this->user->lang['RETURN_PAGE'], '', ''), + // ); } else { @@ -341,7 +345,7 @@ class render_helper 'MCHAT_ALLOW_DEL' => $mchat_del, 'MCHAT_USER_AVATAR' => $mchat_avatar, 'U_VIEWPROFILE' => ($row['user_id'] != ANONYMOUS) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->phpEx}", 'mode=viewprofile&u=' . $row['user_id']) : '', - 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', + 'U_USER_IDS' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'BOT_USER_ID' => $row['user_id'] != '1', 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->config['allow_privmsg'] && $this->auth->acl_get('u_sendpm') && $this->user->data['user_id'] != $row['user_id'] && $row['user_id'] != '1' && ($row['user_allow_pm'] || $this->auth->acl_gets('a_', 'm_') || $this->auth->acl_getf_global('m_'))) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'MCHAT_MESSAGE_EDIT' => $message_edit, @@ -460,7 +464,7 @@ class render_helper 'MCHAT_ALLOW_DEL' => $mchat_del, 'MCHAT_USER_AVATAR' => $mchat_avatar, 'U_VIEWPROFILE' => ($row['user_id'] != ANONYMOUS) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->phpEx}", 'mode=viewprofile&u=' . $row['user_id']) : '', - 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', + 'U_USER_IDS' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'BOT_USER_ID' => $row['user_id'] != '1', 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->config['allow_privmsg'] && $this->auth->acl_get('u_sendpm') && $this->user->data['user_id'] != $row['user_id'] && $row['user_id'] != '1' && ($row['user_allow_pm'] || $this->auth->acl_gets('a_', 'm_') || $this->auth->acl_getf_global('m_'))) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'MCHAT_MESSAGE_EDIT' => $message_edit, @@ -770,7 +774,7 @@ class render_helper 'MCHAT_MESSAGE_EDIT' => $message_edit, 'MCHAT_USER_AVATAR' => $mchat_avatar, 'U_VIEWPROFILE' => ($row['user_id'] != ANONYMOUS) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->phpEx}", 'mode=viewprofile&u=' . $row['user_id']) : '', - 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', + 'U_USER_IDS' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'BOT_USER_ID' => $row['user_id'] != '1', 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->config['allow_privmsg'] && $this->auth->acl_get('u_sendpm') && $this->user->data['user_id'] != $row['user_id'] && $row['user_id'] != '1' && ($row['user_allow_pm'] || $this->auth->acl_gets('a_', 'm_') || $this->auth->acl_getf_global('m_'))) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'MCHAT_MESSAGE_ID' => $row['message_id'], @@ -1003,7 +1007,7 @@ class render_helper 'MCHAT_ALLOW_DEL' => $mchat_del, 'MCHAT_USER_AVATAR' => $mchat_avatar, 'U_VIEWPROFILE' => ($row['user_id'] != ANONYMOUS) ? append_sid("{$this->phpbb_root_path}memberlist.{$this->phpEx}", 'mode=viewprofile&u=' . $row['user_id']) : '', - 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', + 'U_USER_IDS' => ($row['user_id'] != ANONYMOUS && $this->user->data['user_id'] != $row['user_id']) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'BOT_USER_ID' => $row['user_id'] != '1', 'U_USER_ID' => ($row['user_id'] != ANONYMOUS && $this->config['allow_privmsg'] && $this->auth->acl_get('u_sendpm') && $this->user->data['user_id'] != $row['user_id'] && $row['user_id'] != '1' && ($row['user_allow_pm'] || $this->auth->acl_gets('a_', 'm_') || $this->auth->acl_getf_global('m_'))) ? append_sid("{$this->phpbb_root_path}ucp.{$this->phpEx}", 'i=pm&mode=compose&u=' . $row['user_id']) : '', 'MCHAT_MESSAGE_EDIT' => $message_edit, @@ -1101,6 +1105,9 @@ class render_helper 'MCHAT_RULES' => $mchat_rules, 'MCHAT_ALLOW_SMILES' => $mchat_smilies, 'MCHAT_ALLOW_IP' => $mchat_ip, + 'MCHAT_ALLOW_PM' => $mchat_pm, + 'MCHAT_ALLOW_LIKE' => $mchat_like, + 'MCHAT_ALLOW_QUOTE' => $mchat_quote, 'MCHAT_NOMESSAGE_MODE' => $mchat_no_message, 'MCHAT_ALLOW_BBCODES' => ($mchat_allow_bbcode && $this->config['allow_bbcode']) ? true : false, 'MCHAT_MESSAGE_TOP' => $this->config['mchat_message_top'] ? true : false, diff --git a/event/listener.php b/event/listener.php index f375870..9d8e925 100644 --- a/event/listener.php +++ b/event/listener.php @@ -151,7 +151,7 @@ class listener implements EventSubscriberInterface } // Data... - $message = utf8_normalize_nfc($mchat_new_data . ': [url=' . generate_board_url() . '/viewtopic.' . $this->phpEx . '?p=' . $event['data']['post_id'] . '#p' . $event['data']['post_id'] . ']' . $event['post_data']['post_subject'] . '[/url] '. $this->user->lang['MCHAT_IN'] .' [url=' . generate_board_url() . '/viewforum.' . $this->phpEx . '?f=' . $event['forum_id'] . ']' . $event['post_data']['forum_name'] . ' Section[/url] '); + $message = utf8_normalize_nfc($mchat_new_data . ': [url=' . generate_board_url() . '/viewtopic.' . $this->phpEx . '?p=' . $event['data']['post_id'] . '#p' . $event['data']['post_id'] . ']' . $event['post_data']['post_subject'] . '[/url] '. $this->user->lang['MCHAT_IN'] .' [url=' . generate_board_url() . '/viewforum.' . $this->phpEx . '?f=' . $event['forum_id'] . ']' . $event['post_data']['forum_name'] . ' [/url] ' . $this->user->lang['MCHAT_IN_SECTION']); $uid = $bitfield = $options = ''; // will be modified by generate_text_for_storage generate_text_for_storage($message, $uid, $bitfield, $options, true, false, false); diff --git a/language/de/common.php b/language/de/common.php index 6202655..76c9a47 100644 --- a/language/de/common.php +++ b/language/de/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Senden', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Ankündigen', 'MCHAT_ARCHIVE' => 'Archiv', 'MCHAT_ARCHIVE_PAGE' => 'Mini-Chat Archiv', @@ -124,18 +126,9 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Characters remaining: %d', 'MCHAT_TOP_POSTERS' => 'Top Poster', 'MCHAT_NEW_CHAT' => 'Neue mChat Nachricht!', - 'FONT_COLOR' => 'Schriftfarbe', - 'FONT_COLOR_HIDE' => 'Schriftfarbe ausblenden', - 'FONT_HUGE' => 'Riesig', - 'FONT_LARGE' => 'Groß', - 'FONT_NORMAL' => 'Normal', - 'FONT_SIZE' => 'Schriftgröße', - 'FONT_SMALL' => 'Klein', - 'FONT_TINY' => 'Tiny', 'MCHAT_SEND_PM' => 'Sende private Nachricht', 'MCHAT_PM' => '(PN)', - 'MORE_SMILIES' => 'Mehr Smilies', - + //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', )); \ No newline at end of file diff --git a/language/en/common.php b/language/en/common.php index b8a23af..585f0db 100644 --- a/language/en/common.php +++ b/language/en/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Send', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Announcement', 'MCHAT_ARCHIVE' => 'Archive', 'MCHAT_ARCHIVE_PAGE' => 'Mini-Chat Archive', @@ -124,17 +126,8 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Characters remaining: %d', 'MCHAT_TOP_POSTERS' => 'Top Spammers', 'MCHAT_NEW_CHAT' => 'New Chat Message!', - 'FONT_COLOR' => 'Font colour', - 'FONT_COLOR_HIDE' => 'Hide font colour', - 'FONT_HUGE' => 'Huge', - 'FONT_LARGE' => 'Large', - 'FONT_NORMAL' => 'Normal', - 'FONT_SIZE' => 'Font size', - 'FONT_SMALL' => 'Small', - 'FONT_TINY' => 'Tiny', 'MCHAT_SEND_PM' => 'Send Private Message', 'MCHAT_PM' => '(PM)', - 'MORE_SMILIES' => 'More Smilies', //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', diff --git a/language/en/info_acp_mchat.php b/language/en/info_acp_mchat.php index d4842ce..7cac185 100644 --- a/language/en/info_acp_mchat.php +++ b/language/en/info_acp_mchat.php @@ -158,6 +158,9 @@ $lang = array_merge($lang, array( 'ACL_U_MCHAT_EDIT' => 'Can edit mChat messages mchat', 'ACL_U_MCHAT_DELETE' => 'Can delete mChat messages mchat', 'ACL_U_MCHAT_IP' => 'Can use view mChat IP addresses mchat', + 'ACL_U_MCHAT_PM' => 'Can use private message in mchat', + 'ACL_U_MCHAT_LIKE' => 'Can use like message in mchat', + 'ACL_U_MCHAT_QUOTE' => 'Can use quote message in mchat', 'ACL_U_MCHAT_FLOOD_IGNORE' => 'Can ignore mChat flood mchat', 'ACL_U_MCHAT_ARCHIVE' => 'Can view the Archive mchat', 'ACL_U_MCHAT_BBCODE' => 'Can use bbcode in mChat mchat', diff --git a/language/fr/common.php b/language/fr/common.php index 8ad52c2..a694e7f 100644 --- a/language/fr/common.php +++ b/language/fr/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Envoyer', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Annonce', 'MCHAT_ARCHIVE' => 'Archives', 'MCHAT_ARCHIVE_PAGE' => 'Archives du mini-chat', @@ -124,18 +126,9 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Caractères restants: %d', 'MCHAT_TOP_POSTERS' => 'Top Spammers', 'MCHAT_NEW_CHAT' => 'Nouveau Message Dans Mchat!', - 'FONT_COLOR' => 'Couleur de fond', - 'FONT_COLOR_HIDE' => 'Cacher la couleur de fond', - 'FONT_HUGE' => 'Énorme', - 'FONT_LARGE' => 'Large', - 'FONT_NORMAL' => 'Normal', - 'FONT_SIZE' => 'Taille de la police', - 'FONT_SMALL' => 'Petite', - 'FONT_TINY' => 'Minuscule', 'MCHAT_SEND_PM' => 'Envoyer un message privé', 'MCHAT_PM' => '(MP)', - 'MORE_SMILIES' => 'Plus de smileys', - + //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', )); \ No newline at end of file diff --git a/language/it/common.php b/language/it/common.php index 7ec449c..5cc843b 100644 --- a/language/it/common.php +++ b/language/it/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Invia', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Announcio', 'MCHAT_ARCHIVE' => 'Archivio', 'MCHAT_ARCHIVE_PAGE' => 'Mini-Chat Archivio', @@ -124,18 +126,9 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Caratteri: %d', 'MCHAT_TOP_POSTERS' => 'Miglior Spammer', 'MCHAT_NEW_CHAT' => 'Nuovo messaggio in Chat !', - 'FONT_COLOR' => 'Font colore', - 'FONT_COLOR_HIDE' => 'Nascondi colore font', - 'FONT_HUGE' => 'Enorme', - 'FONT_LARGE' => 'Grande', - 'FONT_NORMAL' => 'Normale', - 'FONT_SIZE' => 'Grandezza Font', - 'FONT_SMALL' => 'Piccolo', - 'FONT_TINY' => 'Molto Piccolo', 'MCHAT_SEND_PM' => 'Invia messaggio privato', 'MCHAT_PM' => '(PM)', - 'MORE_SMILIES' => 'Altre Smile', - + //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', )); \ No newline at end of file diff --git a/language/nl/common.php b/language/nl/common.php index 901bbd0..0cae717 100644 --- a/language/nl/common.php +++ b/language/nl/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Versturen', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Aankondiging', 'MCHAT_ARCHIVE' => 'Archief', 'MCHAT_ARCHIVE_PAGE' => 'Mini-Chat Archief', @@ -124,18 +126,9 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Overgebleven karakters: %d', 'MCHAT_TOP_POSTERS' => 'Top Spammers', 'MCHAT_NEW_CHAT' => 'Nieuw Chat bericht!', - 'FONT_COLOR' => 'letterkleur', - 'FONT_COLOR_HIDE' => 'verberg letterkleur', - 'FONT_HUGE' => 'Zeer Groot', - 'FONT_LARGE' => 'Groot', - 'FONT_NORMAL' => 'Normaal', - 'FONT_SIZE' => 'Letter grootte', - 'FONT_SMALL' => 'Klein', - 'FONT_TINY' => 'zeer klein', 'MCHAT_SEND_PM' => 'Stuur prive bericht', 'MCHAT_PM' => '(PM)', - 'MORE_SMILIES' => 'Meer Smilies', - + //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', )); \ No newline at end of file diff --git a/language/pl/common.php b/language/pl/common.php index 5977840..3789191 100644 --- a/language/pl/common.php +++ b/language/pl/common.php @@ -40,7 +40,9 @@ $lang = array_merge($lang, array( 'MCHAT_TITLE' => 'Mini-Chat', 'MCHAT_ADD' => 'Wyślij', - 'MCHAT_IN' => 'In', + 'MCHAT_IN' => 'in', + 'MCHAT_IN_SECTION' => 'section', + 'MCHAT_LIKES' => 'Likes this post', 'MCHAT_ANNOUNCEMENT' => 'Ogłoszenie', 'MCHAT_ARCHIVE' => 'Archiwum', 'MCHAT_ARCHIVE_PAGE' => 'Mini-Chat Archiwum', @@ -124,18 +126,9 @@ $lang = array_merge($lang, array( 'MCHAT_MESSAGE_LNGTH_EXPLAIN' => 'Pozostało znaków: %d', 'MCHAT_TOP_POSTERS' => 'Top Spammerzy', 'MCHAT_NEW_CHAT' => 'Nowa wiadomośc na mChacie!', - 'FONT_COLOR' => 'Kolor czcionki', - 'FONT_COLOR_HIDE' => 'Ukryj kolor czcionki', - 'FONT_HUGE' => 'Ogromne', - 'FONT_LARGE' => 'Duże', - 'FONT_NORMAL' => 'Normalne', - 'FONT_SIZE' => 'Rozmiar czcionki', - 'FONT_SMALL' => 'Mały', - 'FONT_TINY' => 'Malutki', 'MCHAT_SEND_PM' => 'Wyślij prywatną wiadomość', 'MCHAT_PM' => '(PM)', - 'MORE_SMILIES' => 'Więcej emotikon', - + //Custom edits 'REPLY_WITH_LIKE' =>'Like This Post', )); \ No newline at end of file diff --git a/migrations/mchat_schema.php b/migrations/mchat_schema.php index d102997..98d7627 100644 --- a/migrations/mchat_schema.php +++ b/migrations/mchat_schema.php @@ -25,13 +25,16 @@ class mchat_schema extends \phpbb\db\migration\migration array('config.add', array('mchat_new_posts_quote', false)), array('config.add', array('mchat_message_top', true)), array('config.add', array('mchat_stats_index', false)), - array('config.add', array('mchat_version','0.0.12')), + array('config.add', array('mchat_version','0.0.13')), array('permission.add', array('u_mchat_use')), array('permission.add', array('u_mchat_view')), array('permission.add', array('u_mchat_edit')), array('permission.add', array('u_mchat_delete')), array('permission.add', array('u_mchat_ip')), + array('permission.add', array('u_mchat_pm')), + array('permission.add', array('u_mchat_like')), + array('permission.add', array('u_mchat_quote')), array('permission.add', array('u_mchat_flood_ignore')), array('permission.add', array('u_mchat_archive')), array('permission.add', array('u_mchat_bbcode')), @@ -45,6 +48,9 @@ class mchat_schema extends \phpbb\db\migration\migration array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_edit', 'group')), array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_delete', 'group')), array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_ip', 'group')), + array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_pm', 'group')), + array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_like', 'group')), + array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_quote', 'group')), array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_flood_ignore', 'group')), array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_archive', 'group')), array('permission.permission_set', array('ADMINISTRATORS', 'u_mchat_bbcode', 'group')), diff --git a/styles/prosilver/template/mchat_avatars.html b/styles/prosilver/template/mchat_avatars.html index c86b48b..7f692c7 100644 --- a/styles/prosilver/template/mchat_avatars.html +++ b/styles/prosilver/template/mchat_avatars.html @@ -3,8 +3,8 @@
{mchatrow.MCHAT_USER_AVATAR}
- @ @ @ {mchatrow.MCHAT_USERNAME_FULL} {L_MCHAT_PM} - {mchatrow.MCHAT_TIME} - {L_REPLY_WITH_LIKE}  {L_REPLY_WITH_QUOTE} {L_MCHAT_IP} {mchatrow.MCHAT_USER_IP} {L_MCHAT_PERMISSIONS} {L_MCHAT_EDIT} {L_MCHAT_DELITE}
{mchatrow.MCHAT_MESSAGE}
+ @ @ @ {mchatrow.MCHAT_USERNAME_FULL} - {mchatrow.MCHAT_TIME} + {L_MCHAT_SEND_PM} {L_REPLY_WITH_LIKE}  {L_REPLY_WITH_QUOTE} {L_MCHAT_IP} {mchatrow.MCHAT_USER_IP} {L_MCHAT_PERMISSIONS} {L_MCHAT_EDIT} {L_MCHAT_DELITE}
{mchatrow.MCHAT_MESSAGE}
diff --git a/styles/prosilver/template/mchat_body.html b/styles/prosilver/template/mchat_body.html index 5c91e26..bf248ed 100644 --- a/styles/prosilver/template/mchat_body.html +++ b/styles/prosilver/template/mchat_body.html @@ -72,6 +72,7 @@ var mChatRefreshYes = '{MCHAT_REFRESH_YES}'; var mChatRefreshNo = '{LA_MCHAT_REFRESH_NO}'; var mChatMssgLngthLong = '{MCHAT_MESS_LONG}'; + var mChatLikes = '{LA_MCHAT_LIKES}'; var mChatMssgLngth = '{MCHAT_MESSAGE_LNGTH}'; @@ -133,7 +134,7 @@ username = username.replace(/./g, '.'); username = username.replace(/&/g, '&'); username = username.replace(/"/g, '"'); - document.getElementById('mChatMessage').value += 'Like\'s this post.[quote="' + username + '"]' + ' ' + quote + '[/quote]'; + document.getElementById('mChatMessage').value += '' + mChatLikes + '[quote="' + username + '"]' + ' ' + quote + '[/quote]'; document.getElementById('mChatMessage').focus(); } // ]]> diff --git a/styles/prosilver/theme/images/message.gif b/styles/prosilver/theme/images/message.gif new file mode 100644 index 0000000000000000000000000000000000000000..103421a26fad88883a29117380670edbe7b28094 GIT binary patch literal 576 zcmZ?wbhEHb6kyn>lu9MiYy@rzeBd6N&HyY%b#pX$YXT`J~& z`1JYD-@k{>Ui|s%*NZnF7H&SgX!C*BZ{EHC{Pq5`*Y7@kX_>M7(TkU-uikk3@$0L% zAI{&nf9}S^`5X2=ef9ds&)+96U;pvr=eHlfj58-Zc>3bkpFbYei#%!o=2@@BZ-l>)$_rkDR~!@$;8I|Ngyt^Zxy( zPwV%d@~dBR|LOBruiyXp^?U1~lNzyh@jnCM z5YC_jvL6&D4D53o!kd~~THD%NI77R8dV4s-S;8hynL33foQc6`+EhOVrf>sG5gDFo z9QIoBcH!PUCKlSxQ}_h}h20Iq)xtO=WyNg6Ow9yERm0T7xhCuSd)Zh!nQJ&s<_c#F zb7L3Rln&5QV&(M=V+?2Gb7c+V_VAVBwvuC4WD7Tz@Nv-(Vqo-Qa9}#pq3y6jBj!ZG V!ftKmWgc@p3LiCSH!?6-0|3dy{xSdn literal 0 HcmV?d00001 diff --git a/styles/prosilver/theme/mchat.css b/styles/prosilver/theme/mchat.css index 1007899..778e74e 100644 --- a/styles/prosilver/theme/mchat.css +++ b/styles/prosilver/theme/mchat.css @@ -274,4 +274,10 @@ div.avatarMessage { z-index:1000; filter:alpha(opacity=70); opacity:0.70; -} \ No newline at end of file +} + +/* Change buttons height +------------ */ +.mChatImage { + margin-top: -4px; +}