summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwjames5 <will@tekimaki.com>2010-02-03 23:24:31 +0000
committerwjames5 <will@tekimaki.com>2010-02-03 23:24:31 +0000
commit9a27ddb3d5c2ef0b3cfc794705350ef49badfe22 (patch)
treecbb1728eceb6555ce797755fb827f667415ef1dd
parent1a2e82d85c9fee3f226fd4fbfc9f039b6499106f (diff)
downloadlanguages-9a27ddb3d5c2ef0b3cfc794705350ef49badfe22.tar.gz
languages-9a27ddb3d5c2ef0b3cfc794705350ef49badfe22.tar.bz2
languages-9a27ddb3d5c2ef0b3cfc794705350ef49badfe22.zip
-rw-r--r--admin/schema_inc.php21
-rw-r--r--bit_setup_inc.php2
2 files changed, 10 insertions, 13 deletions
diff --git a/admin/schema_inc.php b/admin/schema_inc.php
index e29d4e0..8644d45 100644
--- a/admin/schema_inc.php
+++ b/admin/schema_inc.php
@@ -70,6 +70,15 @@ $gBitInstaller->registerPreferences( LANGUAGES_PKG_NAME, array(
array( LANGUAGES_PKG_NAME, 'i18n_record_untranslated','y' ),
) );
+// ### Default UserPermissions
+$gBitInstaller->registerUserPermissions( LANGUAGES_PKG_NAME, array(
+ array('p_languages_create', 'Can create new languages', 'admin', LANGUAGES_PKG_NAME),
+ array('p_languages_edit', 'Can edit translations', 'editors', LANGUAGES_PKG_NAME),
+ array('p_languages_delete', 'Can delete languages', 'admin', LANGUAGES_PKG_NAME),
+ array('p_languages_edit_master', 'Can edit master translation strings', 'admin', LANGUAGES_PKG_NAME),
+ array('p_languages_import', 'Can import and export language files', 'editors', LANGUAGES_PKG_NAME),
+) );
+
$gBitInstaller->registerSchemaDefault( LANGUAGES_PKG_NAME, array(
"INSERT INTO `".BIT_DB_PREFIX."i18n_languages` (`lang_code`,`native_name`,`english_name`,`right_to_left`) VALUES ('ar', 'ﺎﻠﻋﺮﺒﻳﺓ', 'Arabic','y' )",
"INSERT INTO `".BIT_DB_PREFIX."i18n_languages` (`lang_code`,`native_name`,`english_name`) VALUES ('ca', 'Català', 'Catalan')",
@@ -112,16 +121,6 @@ $gBitInstaller->registerSchemaDefault( LANGUAGES_PKG_NAME, array(
"INSERT INTO `".BIT_DB_PREFIX."i18n_languages` (`lang_code`,`native_name`,`english_name`) VALUES ('zh-cn', '简体中文', 'Chinese')",
) );
-/*
-// ### Default UserPermissions
-$gBitInstaller->registerUserPermissions( LANGUAGES_PKG_NAME, array(
- array('p_languages_create', 'Can create new languages', 'admin', LANGUAGES_PKG_NAME),
- array('p_languages_edit', 'Can edit translations', 'editors', LANGUAGES_PKG_NAME),
- array('p_languages_delete', 'Can delete languages', 'admin', LANGUAGES_PKG_NAME),
- array('p_languages_edit_master', 'Can edit master translation strings', 'admin', LANGUAGES_PKG_NAME),
- array('p_languages_import', 'Can import and export language files', 'editors', LANGUAGES_PKG_NAME),
-) );
-
// Package requirements
$gBitInstaller->registerRequirements( LANGUAGES_PKG_NAME, array(
'liberty' => array( 'min' => '2.1.0' ),
@@ -129,4 +128,4 @@ $gBitInstaller->registerRequirements( LANGUAGES_PKG_NAME, array(
'kernel' => array( 'min' => '2.0.0' ),
'themes' => array( 'min' => '2.0.0' ),
));
-*/
+?>
diff --git a/bit_setup_inc.php b/bit_setup_inc.php
index e9d4aae..637020e 100644
--- a/bit_setup_inc.php
+++ b/bit_setup_inc.php
@@ -17,7 +17,6 @@ if ($gBitSystem->isFeatureActive('babelfish_logo') ) {
require_once(LANGUAGES_PKG_PATH . 'Babelfish.php');
$gBitSmarty->assign('babelfish_logo', Babelfish::logo($gBitLanguage->mLanguage));
}
-/*
if( $gBitSystem->isPackageActive( 'languages' ) && $gBitUser->hasPermission( 'p_languages_edit' ) ) {
$menuHash = array(
'package_name' => LANGUAGES_PKG_NAME,
@@ -26,7 +25,6 @@ if( $gBitSystem->isPackageActive( 'languages' ) && $gBitUser->hasPermission( 'p_
);
$gBitSystem->registerAppMenu( $menuHash );
}
-*/
if( $gBitSystem->isFeatureActive( 'users_preferences' ) && $gBitUser->isRegistered() ) {
if( $gBitSystem->isFeatureActive( 'users_change_language' ) ) {